Skip to content

Document automatic Wayland/Nvidia workaround in troubleshooting#1033

Open
niksirbi wants to merge 2 commits into
napari:mainfrom
niksirbi:update-troubleshooting-wayland
Open

Document automatic Wayland/Nvidia workaround in troubleshooting#1033
niksirbi wants to merge 2 commits into
napari:mainfrom
niksirbi:update-troubleshooting-wayland

Conversation

@niksirbi
Copy link
Copy Markdown

References and relevant issues

Depends on napari/napari#9009
Related to napari/napari#8808

napari/napari#9009 makes napari automatically apply the Wayland/Nvidia startup workaround (setting QT_QPA_PLATFORM=xcb and PYOPENGL_PLATFORM=glx), and adds an in-app warning for the cases it can't cover. That warning links to the troubleshooting section updated here (#wayland-and-nvidia). See that PR
for the full background.

Description

This PR updates the "Running napari on Wayland with Nvidia cards" troubleshooting section to reflect the new automatic workaround in napari/napari#9009:

  • Explains that recent napari versions set the required environment variables automatically at startup, so most users (launching via the napari command or a Python script) no longer need to do anything.
  • Documents the manual workaround for the case the automatic fix can't cover: when a Qt application is created before import napari (e.g. in IPython or Jupyter when %gui qt runs first), the user must set the variables themselves before starting the session.
  • Notes that user-set values are always respected.
  • Adds a stable (wayland-and-nvidia)= anchor that the in-app warning links to, while keeping the original heading so existing links don't break.

napari now sets QT_QPA_PLATFORM=xcb and PYOPENGL_PLATFORM=glx automatically
at startup, so explain that most users need no action, and document the
manual workaround for the IPython/Jupyter case where a Qt application is
created before napari is imported. Add a stable (wayland-and-nvidia) anchor
that the in-app warning links to, while keeping the original heading.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label May 28, 2026
@niksirbi niksirbi marked this pull request as ready for review May 28, 2026 14:20
Copy link
Copy Markdown
Contributor

@brisvag brisvag left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love it!

@brisvag brisvag added this to the 0.7.1 milestone May 28, 2026
Copy link
Copy Markdown
Contributor

@TimMonko TimMonko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Absolutely lovely! Thank you!!!! 🤩

I left two comments, but you are more then welcome to do with them as you please. :)

Comment thread docs/troubleshooting.md Outdated
Comment thread docs/troubleshooting.md Outdated
Comment thread docs/troubleshooting.md
Co-authored-by: Tim Monko <timmonko@gmail.com>
@niksirbi
Copy link
Copy Markdown
Author

Thanks both! Probably it make sense to wait till we settle on how napari/napari#9009 lands before this one gets merged, right?

@TimMonko
Copy link
Copy Markdown
Contributor

Thanks both! Probably it make sense to wait till we settle on how napari/napari#9009 lands before this one gets merged, right?

Yep! And because you have the "Depends on" in the OP our CI blocks it :)

@niksirbi
Copy link
Copy Markdown
Author

Yep! And because you have the "Depends on" in the OP our CI blocks it :)

Good to know! I should start using that too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants