We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
prevent_exit
AppHandle::exit
Children processes are not cleaned up when using Event::ExitRequested's api.prevent_exit(), and invoking AppHandle::exit(0).
Event::ExitRequested
api.prevent_exit()
AppHandle::exit(0)
Steps to reproduce the behavior:
tauri::Builder::default() .system_tray(sys_tray) .on_system_tray_event(|app, event| { match event { SystemTrayEvent::MenuItemClick { id, .. } => match id.as_str() { "quit" => { app.exit(0); } _ => {} }, _ => {} } }) .build(tauri::generate_context!()) .expect("Error building app") .run(|_app_handle, event| { if let Event::ExitRequested { api, .. } = event { api.prevent_exit(); } });
That the sidecar programs are shutdown when the api.exit(0); is executed
api.exit(0);
Operating System - Windows, version 10.0.18363 X64 Webview2 - 92.0.902.73 Node.js environment Node.js - 14.17.3 @tauri-apps/cli - 1.0.0-beta.7 @tauri-apps/api - 1.0.0-beta.6 Global packages npm - 6.14.13 yarn - 1.22.10 Rust environment rustc - 1.54.0 cargo - 1.54.0 App directory structure /.git /.github /node_modules /public /scripts /src /src-tauri /tests App tauri.rs - 1.0.0-beta.6 build-type - bundle CSP - default-src blob: data: filesystem: ws: http: https: 'unsafe-eval' 'unsafe-inline' 'self' img-src: 'self' distDir - Set automatically by Vue CLI plugin devPath - Set automatically by Vue CLI plugin framework - Vue.js (Vue CLI) bundler - Webpack
The text was updated successfully, but these errors were encountered:
fix(core): cleanup app before exit, closes #2464
fc02522
a54bba6
No branches or pull requests
Describe the bug
Children processes are not cleaned up when using
Event::ExitRequested
'sapi.prevent_exit()
, and invokingAppHandle::exit(0)
.To Reproduce
Steps to reproduce the behavior:
Expected behavior
That the sidecar programs are shutdown when the
api.exit(0);
is executedPlatform and Versions (required):
The text was updated successfully, but these errors were encountered: