Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make a dialog appear when rust app panics #310

Merged
merged 2 commits into from
Nov 26, 2022
Merged

Conversation

ImUrX
Copy link
Member

@ImUrX ImUrX commented Nov 26, 2022

This implements a cross platform crate that shows the actual panic. Pretty helpful when not launching from terminal.
Also implements randomhelpful window titles when one appears.
crash window

Copy link
Contributor

@TheButlah TheButlah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.

@loucass003
Copy link
Member

loucass003 commented Nov 26, 2022

Can we add some more dialogs ?

we need one when java is not detected (make sure it does not trigger in dev mode tho 🤣 )
Also is there no way to detect webview directly and have a dedicated message for it ?

Copy link
Member

@loucass003 loucass003 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

.

@TheButlah
Copy link
Contributor

Just make new PRs for those, let him merge this

@Eirenliel Eirenliel merged commit f7d3448 into SlimeVR:main Nov 26, 2022
@ImUrX
Copy link
Member Author

ImUrX commented Nov 26, 2022

Can we add some more dialogs ?

we need one when java is not detected (make sure it does not trigger in dev mode tho rofl ) Also is there no way to detect webview directly and have a dedicated message for it ?

The Java one is possible and shouldn't be that hard.
I tried making a webview one but it won't even be able to launch because it fails to link with the unexisting webkitgtk shared object. I wouldn't expect people to install it outside using an AppImage or from their package manager, so this shouldn't matter. And the error the linker returns says it didnt find webkit2gtk-4, so I think that's good enough. (only on console tho :/)
The Webview error on Windows is weird, look I got an example here
image
It's a CreateWebview(WebView2Error(WindowsError())), when there is already a WebviewNotFound error. We can detect that and suggest installing WebView2 from Microsoft, don't know if it's the best idea tho.
Here you can see the errors btw https://docs.rs/tauri/latest/tauri/enum.Error.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants