Menu β–Ύ β–΄

#38 Fix Linux Wayland WebKit DMABUF rendering

closed
nobody
None
2026-07-01
2026-07-01
Anonymous
No

Originally created by: kristofferR

Summary

  • set WEBKIT_DISABLE_DMABUF_RENDERER=1 before Tauri/WebKit startup on Linux Wayland
  • preserve explicit user overrides for WEBKIT_DISABLE_DMABUF_RENDERER
  • add unit coverage for the Wayland/override predicate

Why

Carrier's Linux build uses WebKitGTK, which is still exposed to DMABUF renderer failures that can produce blank, black, or garbled webviews on affected Wayland systems.

Ref [#31]

Validation

  • cargo fmt --check
  • cargo clippy --all-targets -- -D warnings
  • cargo test --lib
  • node --check inject/messenger.js

Summary by CodeRabbit

  • Bug Fixes
  • Improved app startup on Linux desktops using Wayland, helping the app render more reliably in affected environments.
  • Respects existing user settings, so manual environment overrides continue to work as expected.

Related

Tickets: #31

Discussion

  • Anonymous

    Anonymous - 2026-07-01

    Originally posted by: kristofferR

    @coderabbitai review

     
  • Anonymous

    Anonymous - 2026-07-01

    Originally posted by: coderabbitai[bot]

    βœ… Action performed Review finished. > Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.
     
  • Anonymous

    Anonymous - 2026-07-01

    Originally posted by: coderabbitai[bot]

    Review Change Stack

    No actionable comments were generated in the recent review. πŸŽ‰

    ℹ️ Recent review info
    βš™οΈ Run configuration **Configuration used**: Path: .coderabbit.yaml **Review profile**: ASSERTIVE **Plan**: Pro **Run ID**: `9e4a20f5-e79b-4413-857b-71f0e62a5032`
    πŸ“₯ Commits Reviewing files that changed from the base of the PR and between [d7bd1b] and bfafff8f3bd0058075b553d4acbd473deefdc2aa.
    πŸ“’ Files selected for processing (1) * `src-tauri/src/lib.rs`

    πŸ“ Walkthrough ## Walkthrough Adds Linux-only logic in `src-tauri/src/lib.rs` to disable the WebKit DMABUF renderer when running under Wayland without a user override. Introduces a predicate function and a configuration function invoked during app startup, plus a unit test covering the predicate's behavior. ### Changes **WebKit DMABUF renderer fix** |Layer / File(s)|Summary| |---|---| |**Predicate, configuration, and startup wiring**
    `src-tauri/src/lib.rs`|Adds `should_disable_webkit_dmabuf_renderer` predicate and `configure_linux_webkit_renderer` function that reads `WAYLAND_DISPLAY`/`WEBKIT_DISABLE_DMABUF_RENDERER` env vars and sets the override; called in `run()` before early settings load and Tauri builder construction.| |**Predicate unit test**
    `src-tauri/src/lib.rs`|Adds a unit test verifying the predicate's truth table across Wayland presence and override combinations.| **Estimated code review effort:** 1 (Trivial) | ~5 minutes **Possibly related issues** - [kristofferR/Carrier#31](https://github.com/kristofferR/Carrier/issues/31): Implements the same Linux/Wayland `WEBKIT_DISABLE_DMABUF_RENDERER` startup workaround described in this issue.
    πŸš₯ Pre-merge checks | βœ… 5
    βœ… Passed checks (5 passed) | Check name | Status | Explanation | | :------------------------: | :------- | :--------------------------------------------------------------------------------------------------------- | | Description Check | βœ… Passed | Check skipped - CodeRabbit’s high-level summary is enabled. | | Title check | βœ… Passed | The title clearly summarizes the main Linux Wayland WebKit DMABUF rendering fix. | | Docstring Coverage | βœ… Passed | No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. | | Linked Issues check | βœ… Passed | Check skipped because no linked issues were found for this pull request. | | Out of Scope Changes check | βœ… Passed | Check skipped because no linked issues were found for this pull request. |
    ✨ Finishing Touches
    πŸ“ Generate docstrings - [ ] Create stacked PR - [ ] Commit on current branch
    πŸ§ͺ Generate unit tests (beta) - [ ] Create PR with unit tests - [ ] Commit unit tests in branch `codex/fix-31-wayland-dmabuf`

    Comment @coderabbitai help to get the list of available commands.

     
  • Anonymous

    Anonymous - 2026-07-01

    Ticket changed by: kristofferR

    • status: open --> closed
     

Log in to post a comment.