[bug] Error 0x8007139F after calling `window.close` from javascript
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 111k
- Forks
- 4k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 45
Description
Describe the bug
I received a bug report that is unable to see contents on launch app in extremely rare cases
The error log I received is like below:
2025-04-28T23:45:11.819531+09:00 [ERROR] tauri_runtime_wry: WebView2 error: WindowsError(Error { code: HRESULT(0x8007139F), message: "クラスが登録されていません" })
2025-04-28T23:45:11.820218+09:00 [ERROR] tauri_runtime_wry: WebView2 error: WindowsError(Error { code: HRESULT(0x8007139F), message: "グループまたはリソースは要求した操作の実行に適切な状態ではありません。" })
2025-04-28T23:45:11.820355+09:00 [ERROR] tauri_runtime_wry: WebView2 error: WindowsError(Error { code: HRESULT(0x8007139F), message: "グループまたはリソースは要求した操作の実行に適切な状態ではありません。" })
2025-04-28T23:45:11.820467+09:00 [ERROR] tauri_runtime_wry: WebView2 error: WindowsError(Error { code: HRESULT(0x8007139F), message: "グループまたはリソースは要求した操作の実行に適切な状態ではありません。" })
2025-04-28T23:45:11.820607+09:00 [ERROR] tauri_runtime_wry: WebView2 error: WindowsError(Error { code: HRESULT(0x8007139F), message: "グループまたはリソースは要求した操作の実行に適切な状態ではありません。" })
(and same error message repeating infinitely)
Reproduction
Sorry, I'm unable to create minimum reproducible case since I have never experienced the error.
Original reporter saied that using https://github.com/vrc-get/vrc-get/releases/tag/gui-v1.0.1 and launching as normal by clicking app may cause this status in rare case.
Expected behavior
No errors and launch normally
Full tauri info output
[✔] Environment
- OS: Mac OS 15.3.1 arm64 (X64)
✔ Xcode Command Line Tools: installed
✔ rustc: 1.85.0 (4d91de4e4 2025-02-17)
✔ cargo: 1.85.0 (d73d2caf9 2024-12-31)
✔ rustup: 1.27.1 (54dd3d00f 2024-04-24)
✔ Rust toolchain: stable-aarch64-apple-darwin (default)
- node: 22.6.0
- pnpm: 9.15.5
- npm: 10.8.2
- deno: deno 1.45.5
[-] Packages
- tauri 🦀: git+https://github.com/anatawa12/tauri?branch=restart-wait-for-exit#1c589853fdd82c16e3fe7d241d85612041e06e8e (2.3.1)
- tauri-build 🦀: git+https://github.com/anatawa12/tauri?branch=restart-wait-for-exit#1c589853fdd82c16e3fe7d241d85612041e06e8e (2.0.6)
- wry 🦀: 0.50.5
- tao 🦀: 0.32.8
- tauri-cli 🦀: 2.0.0-rc.3
- @tauri-apps/api : 2.4.0 (outdated, latest: 2.5.0)
- @tauri-apps/cli : 2.3.1 (outdated, latest: 2.5.0)
[-] Plugins
- tauri-plugin-single-instance 🦀: 2.2.2
- @tauri-apps/plugin-single-instance : not installed!
- tauri-plugin-fs 🦀: 2.2.0
- @tauri-apps/plugin-fs : not installed!
- tauri-plugin-updater 🦀: 2.6.1
- @tauri-apps/plugin-updater : not installed!
- tauri-plugin-dialog 🦀: 2.2.0
- @tauri-apps/plugin-dialog : not installed!
[-] App
- build-type: bundle
- CSP: unset
- frontendDist: out
- devUrl: http://localhost:3030/
- framework: React
- bundler: Vite
Stack trace
Additional context
tauri info output is based on my dev environment.
Here's the information on build env
node 18.20.6
tauri 2.2.5
tauri-build 2.0.5
wry 0.48.1
tao 0.31.1
@tauri-apps/api 2.2.0
@tauri-apps/cli 2.2.7
tauri-plugin-single-instance 2.2.1
tauri-plugin-fs 2.2.0
tauri-plugin-updater 2.5.0
tauri-plugin-dialog 2.2.0
What we're special is that we create window in future tauri::async_runtime::spawn-ed in setup
User's environmenrt infromation
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading vrc-get-gui/src/commands/start.rs lines 86-105 and vrc-get-gui/src/main.rs lines 65-66, focusing on the asynchronously created window and the JavaScript window.close call. Reproduce the rare launch failure if possible, then verify that closing the window no longer produces repeating WebView2 errors and that the app launches normally.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, rust
- Domain
- desktop
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100