Bug 464835 - kscreen-console prints nothing under Wayland
Summary: kscreen-console prints nothing under Wayland
Status: RESOLVED WORKSFORME
Alias: None
Product: KScreen
Classification: Plasma
Component: common (show other bugs)
Version: 5.26.5
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: kscreen-bugs-null@kde.org
URL:
Keywords: wayland-only
Depends on:
Blocks:
 
Reported: 2023-01-26 02:04 UTC by skierpage
Modified: 2025-01-10 18:07 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description skierpage 2023-01-26 02:04:37 UTC
SUMMARY
https://community.kde.org/Solid/Projects/ScreenManagement#Debugging_Information suggests running `kscreen-console bug`. But on Wayland it prints nothing.

STEPS TO REPRODUCE
1. Run Plasma on Wayland (check Graphics Platform in System Settings > About this System)
2. In a terminal, enter
   kscreen-console bug

OBSERVED RESULT
    QSocketNotifier: Can only be used with threads started with QThread
    kf.i18n: KLocalizedString: Using an empty domain, fix the code. msgid: "(c) 2012 KScreen Team" msgid_plural: "" msgctxt: ""
    ... [6 more kf.i18n: KLocalizedString warnings]
    ========================xrandr --verbose==========================

    ========================Outputs===================================

    ========================Configurations============================

EXPECTED RESULT
Either a nice warning "This tool does not produce useful output when run on the Wayland graphics platform"
    and/or "xrandr program not found, please install it" (see below)
or make it work under Wayland, which would probably require a special interface to KWin bypassing Wayland's client isolation.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
KDE Plasma Version: 5.26.5
KDE Frameworks Version: 5.102.0
Qt Version: 5.15.8 on Wayland

ADDITIONAL INFORMATION
kscreen-console invokes xrandr, but Fedora 37 KDE spin doesn't even include this X11 program by default. If I install xrandr, I get a lot of output about my XWYAYLAND1 and XWAYLAND2 outputs on Screen 0, so if this output is helpful for debugging maybe kscreen-console could test for xrandr and suggest installing it. Even with xrandr available it still prints nothing under ===Outputs=== and ===Configuration===
Comment 1 Nate Graham 2023-01-27 17:25:54 UTC
On Wayland, I see output under the "xrandr --verbose" header at least.
Comment 2 Zamundaaa 2025-01-10 16:35:04 UTC
kscreen-console doesn't need xrandr and does work for me on Wayland with Plasma 6.2, so I assume this can be closed. If you're still experiencing the issue, please reopen this
Comment 3 Bug Janitor Service 2025-01-10 16:40:38 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kscreen/-/merge_requests/336
Comment 4 Zamundaaa 2025-01-10 18:00:57 UTC
Git commit 888716298a27364cc5b1cdd6fdf5c5b957277772 by Xaver Hugl.
Committed on 10/01/2025 at 16:39.
Pushed by zamundaaa into branch 'master'.

console: make kscreen-console print the correct config on Wayland

Makes it a bit more useful and less misleading

M  +7    -5    console/CMakeLists.txt
M  +25   -18   console/console.cpp

https://invent.kde.org/plasma/kscreen/-/commit/888716298a27364cc5b1cdd6fdf5c5b957277772
Comment 5 Bug Janitor Service 2025-01-10 18:01:30 UTC
A possibly relevant merge request was started @ https://invent.kde.org/plasma/kscreen/-/merge_requests/337
Comment 6 Zamundaaa 2025-01-10 18:07:35 UTC
Git commit 268dc6365848db8eced51c1bfb5753c5cd2b5281 by Xaver Hugl.
Committed on 10/01/2025 at 18:01.
Pushed by zamundaaa into branch 'Plasma/6.3'.

console: make kscreen-console print the correct config on Wayland

Makes it a bit more useful and less misleading
(cherry picked from commit 888716298a27364cc5b1cdd6fdf5c5b957277772)

M  +7    -5    console/CMakeLists.txt
M  +25   -18   console/console.cpp

https://invent.kde.org/plasma/kscreen/-/commit/268dc6365848db8eced51c1bfb5753c5cd2b5281