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

[bug] [macos] App is crashing when webview is reloads while async command running #9933

Closed
pashokitsme opened this issue May 31, 2024 · 8 comments
Labels
platform: macOS priority: 1 high status: needs triage This issue needs to triage, applied to new issues type: bug

Comments

@pashokitsme
Copy link
Contributor

Describe the bug

If i call async command (#[tauri::command(async)]) and reload page (window.location.reload()) while command still running, app crashes right after command is done.
Sometimes, when tokio decides to run command in other thread, not whole app crashes but this thread

Also tested on windows and linux where i didn't faced with that issue

Reproduction

Minimal reproducible repo (requires python3 as http server): https://github.com/pashokitsme/async-command-panic

Steps:

  1. Run async command
  2. window.location.reload()

Expected behavior

No response

Full tauri info output

WARNING: no lock files found, defaulting to npm

[✔] Environment
    - OS: Mac OS 13.5.2 X64
    ✔ Xcode Command Line Tools: installed
    ✔ rustc: 1.78.0 (9b00956e5 2024-04-29)
    ✔ cargo: 1.78.0 (54d8815d0 2024-03-26)
    ✔ rustup: 1.27.1 (2024-04-24)
    ✔ Rust toolchain: stable-aarch64-apple-darwin (environment override by RUSTUP_TOOLCHAIN)
    - node: 22.1.0
    - pnpm: 9.1.1
    - yarn: 1.22.22
    - npm: 10.7.0
    - bun: 1.1.8

[-] Packages
    - tauri [RUST]: 2.0.0-beta.22
    - tauri-build [RUST]: 2.0.0-beta.17
    - wry [RUST]: 0.40.0
    - tao [RUST]: 0.28.0
    - tauri-cli [RUST]: 2.0.0-beta.20
    - @tauri-apps/api : not installed!
    - @tauri-apps/cli [NPM]: 2.0.0-beta.20

[-] App
    - build-type: bundle
    - CSP: unset
    - frontendDist: ./frontend
    - devUrl: http:https://localhost:5173/

Stack trace

No response

Additional context

output.mp4
image
@pashokitsme pashokitsme added status: needs triage This issue needs to triage, applied to new issues type: bug labels May 31, 2024
@FabianLars
Copy link
Member

Tracked upstream in tauri-apps/wry#1142 / tauri-apps/wry#1189 (PR exists already)

@tance77
Copy link

tance77 commented Jun 17, 2024

Hey @fabianlar,

Just wondering if this fix is planned for production soon?

@FabianLars
Copy link
Member

I assume we release new versions when Lucas and Amr are back from vacation next week.

@reyamir
Copy link

reyamir commented Jun 26, 2024

Hi, any updates on this issue? this will fix a lot of problems in my app

@tance77
Copy link

tance77 commented Jun 26, 2024

I'm going insane it crashes so often when I reload :(

@reyamir
Copy link

reyamir commented Jul 2, 2024

Hi, is this issue fixed in the latest release?

@tance77
Copy link

tance77 commented Jul 2, 2024

Sorry to keep bothering you @FabianLars

Are there any updates on this?

@tance77
Copy link

tance77 commented Jul 9, 2024

This seems to be fixed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
platform: macOS priority: 1 high status: needs triage This issue needs to triage, applied to new issues type: bug
Projects
None yet
Development

No branches or pull requests

4 participants