-
Notifications
You must be signed in to change notification settings - Fork 294
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
[bug] Dialog plugin causing Aborted (core dumped) on Linux when exiting the app #2255
Comments
I get that behavior when making a dialog command function But if I don't make it |
I have to use And I test rfd's file pick dialog, both sync and async one with tokio, they work normally. But rfd with tauri, core dumped. |
I think that's because |
The GTK 3 backend of rfd is relatively problematic (it causes a whole app freeze when the command function isn't async and a SIGABRT on app exit when it is async: tauri-apps/plugins-workspace#2255) so use the better-working xdg-portal backend instead (this will also help with Flatpak compatibility) This also removes the unused tauri-plugin-dialog dependency (which conflicts with our rfd features)
The GTK 3 backend of rfd is relatively problematic (it causes a whole app freeze when the command function isn't async and a SIGABRT on app exit when it is async: tauri-apps/plugins-workspace#2255) so use the better-working xdg-portal backend instead (this will also help with Flatpak compatibility) This also removes the unused tauri-plugin-dialog dependency (which conflicts with our rfd features)
* Freeze Cargo state for release workflow * Allow manual runs for CI workflow This might make debugging CI issues easier * Switch to a maintained Rust toolchain action This removes the set-output warnings too * Add Polish language * Added logging for improved crash analysis * Switch to default xdg-portal for rfd The GTK 3 backend of rfd is relatively problematic (it causes a whole app freeze when the command function isn't async and a SIGABRT on app exit when it is async: tauri-apps/plugins-workspace#2255) so use the better-working xdg-portal backend instead (this will also help with Flatpak compatibility) This also removes the unused tauri-plugin-dialog dependency (which conflicts with our rfd features) * Bring back the Ubuntu CI builds After adding extra dependencies, that build job turns green again This is basically a revert of 5a215c1 * Implemented translation feedback for Ukrainian and Russian * Update ru.json * Remove empty features list from some crates I'm not sure why this was in place * Update ru.json * Switch to ThinLTO for release builds This apparently reduces build time with the same LTO performance gain * Initialize the Tauri shell plugin This fixes the GitHub link in the main window * fixup linux requirements * Add sudo requirement * Add build artifact checks * update to call build from ci-build * Update ci-build.yml * Updated to support Matrix execution and build-artifact v4 * resizable window --------- Co-authored-by: Echo J <[email protected]> Co-authored-by: krvstek. <[email protected]> Co-authored-by: louis-e <[email protected]> Co-authored-by: Louis Erbkamm <[email protected]> Co-authored-by: sh1kcs <[email protected]>
I actually disabled default features in my
And this is what I have tried, they all exits normally. (Even on Wayland session, I will metion at below.)
Well I also tired X11 today and my app exited normally, so this error seems only happen to Wayland. Just asking, are you using Wayland session? |
Your example code is not a good comparison imo. The 2 things that come to mind are that 1) Tauri also spawns a gtk event loop (which rfd does internally as well) and 2) Tauri exits via std::process::exit so rfd's Drop implementation does not run. At first i thought 1) is the issue but after a bit of testing it seems like it's 2) and if rfd could expose a way to shutdown the thread at runtime we could fix this issue here. I can't think of a good approach there though (in my testing i exposed a global static AtomicBool in rfd that i could change from iniside RunEvent::Exit) so maybe it makes more sense to test out the xdg portal implementation. It's file picker should work well enough for us, and imo it's fair to require zenity for the message dialogs. The less we directly depend on gtk the better imo. We're slowly moving away from it in tray-icon and if we end up completely replacing webkitgtk in favor of cef (instead of offering both) we could even get rid of gtk for the whole window. |
I don't think this is a good idea right now though: chromiumembedded/cef#2804 |
I don't think this issue is that relevant for us. Currently the AppImage is our main distribution format and it also has to force x11 to prevent gtk crashes. Also, i'm so tired of complains about webkitgtk that i wouldn't mind just getting rid of all our own windowing and let cef do it itself 😂 |
Describe the bug
As the title implied, using the tauri dialog plugin to open a file system dialog will cause Aborted (core dumped) when exiting the app. This seems to only happen to Linux.
Reproduction
This a code snip from my project, I have a button from frontend to trigger this command and it will open the file select dialog.
If I don't open the dialog and exit the app, it will close normally. But if I open the dialog (even just close the dialog and select nothing), it will give the Aborted (core dumped) error on exiting the app.
Expected behavior
Opening file select dialog should not causing any core dumped error.
Full
tauri info
outputStack trace
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: