Hi there, on up to date instances of Arch Linux and Manjaro Linux, I am running GNOME 49 on Wayland with the screen reader Orca enabled. Orca is configured to provide speech as well as braille output.
When switching to the text console on tty2, Orca is supposed to release the braille device, so the text mode screen reader BRLTTY can take over. Unfortunately, that does not happen. Instead, the braille device continues to display the last output from Orca. Up to GNOME 48, I have not experienced this issue. It is worth noting, however, that I used to run GNOME on X rather than Wayland back then, which is no longer supported on current Arch Linux and derived distros. Developers on the Orca list have told me that Orca evaluates the environment variable XDG_VTNR in order to figure out whether it can and should restrict itself to a certain virtual terminal as far as driving the braille device is concerned. Just like most of the other GNOME components, Orca is started as a systemd user service nowadays. So the question is: how can and should XDG_VTNR be set to the correct value in the environment of Orca? Unfortunately, I am not able to check Orca's environment directly, because the following command only produces a bunch of null-characters and nothing between them: $ cat /proc/`pidof orca`/environ However, I did install the Mate desktop environment in addition to GNOME for further investigation. Since Mate still runs on X, I launched a Mate session from the text console by running the command: $ startx This time, Orca behaved as expected, meaning that it claimed the braille device only when the tty running the Mate session was active. Consequently, BRLTTY was able to take over whenever I switched away to a tty in text mode without stopping the Mate session or Orca. Usually, there is no display manager running on my system since I work on the text console a lot and launch the desktop environment whenever I need it from there. The Arch wiki provides suggestions on how to start gnome-session on Wayland manually from the text console: https://wiki.archlinux.org/title/GNOME#Manually Accordingly, I added the configuration file: $ cat /etc/systemd/system/[email protected]/wayland.conf [Service] Environment=XDG_SESSION_TYPE=wayland Additionally, I created the following startup script: $ cat ~/.local/bin/startw #!/bin/bash set -e export XDG_SESSION_TYPE=wayland systemctl --user import-environment XDG_SESSION_TYPE XDG_VTNR dbus-update-activation-environment XDG_SESSION_TYPE XDG_VTNR gnome-session After systemctl daemon-reload (and possibly even a reboot), I was able to launch GNOME from the text console on tty1 by running: $ ~/.local/bin/startw Again, Orca claimed the braille device regardless what tty I switched to indicating that XDG_VTNR is not set in Orca's environment. In the course of investigating the issue above, I installed gdm and verified that the problem occurs when launching the GNOME session from gdm. Next, I disabled gdm again, rebooted, and tried the following steps in sequence: - Logged in on tty1 (in text mode). - Ran ~/.local/bin/startw launching the GNOME desktop and Orca as described above. - Switched to tty2 and observed that Orca still claimed the braille device so I was unable to work on the text console. - Switched back to tty1 and stopped the GNOME session including Orca, returning to text mode on tty1. - BRLTTY had full control over the braille device on tty1 and all other ttys in text mode again. - Ran startx on tty1, thus launching a Mate session with Orca on X. - Switched to tty2 in text mode and was able to interact with it, i.e. BRLTTY was able to take over. - Switched back to tty1 and stopped the Mate session including Orca. - Ran: systemctl --user unset-environment GDK_BACKEND XDG_CURRENT_DESKTOP \ SESSION_MANAGER and: ~/.local/bin/startw on tty1 in order to launch GNOME again. - Switched to tty2 in text mode and observed that BRLTTY was able to take over again. So, for some reason, Orca in the GNOME desktop environment on Wayland only knows what VT it is running on, when I have previously launched and stopped the Mate desktop on X. Unfortunately, this knowledge does not survive a reboot. Do you have any idea what might be wrong and how to fix it? Your help would be much appreciated and I am happy to assist with further information or tests as required. Thank you very much in advance, Elias
