fix: A bug with Wayland display (Error 71) in WSL #4864
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
☕️ Reasoning
Hello Team! This PR has been created after reviewing issue #4039.
After running the command
WAYLAND_DEBUG=1 pnpm run dev:desktop
, I reviewed the logs and noticed the issue occurs when the window tries to maximize and then revert to its original size.It seems that the
tauri_plugin_window_state
plugin conflicts with the maximized state in Wayland while attempting to restore the previously saved window size.In fact, by removing the
tauri_plugin_window_state
plugin ingitbutler-tauri/src/main.rs
, I confirmed that the application works in WSL.Additionally, after removing the plugin, I verified that the application still opens correctly on other OS (Windows, macOS).
Although there would be a temporary loss of window state saving functionality, would it be a good idea to temporarily comment out the plugin as a workaround until the issue is fully resolved?
Before and after commenting out the plugin
Retesting after commenting out
🧢 Changes
tauri_plugin_window_state
plugin ingitbutler-tauri/src/main.rs
to resolve compatibility issues with WSL.🎫 Affected issues
Fixes: #4039