Bismuth-Forge / bismuth

KDE Plasma add-on, that tiles your windows automatically and lets you manage them via keyboard, similarly to i3, Sway or dwm.
https://bismuth-forge.github.io/bismuth/
Other
2.41k stars 92 forks source link

[Bug]: Bismuth is incompatible with new kwin version (5.26 beta) #426

Closed HanabishiRecca closed 1 year ago

HanabishiRecca commented 1 year ago

Summary

I just tried out Plasma 5.26 beta and seems like Bismuth is completely broken here. With Bismuth installed KWin just breaks and can't even render windows. We probably want to make it compatible until the release.

Steps to Reproduce

Try to use Plasma 5.26 beta with Bismuth.

Expected behavior

Bismuth should work.

Screenshots

No response

Bismuth version

3.1.3

KDE Plasma version

5.26

The platform KWin is running on

X11

Additional context

No response

gikari commented 1 year ago

can't even render windows.

Can you see the windows in task manager and move them via Right Click > More > Move?

Also, what the output of kwin? You can get it via:

export QT_LOGGING_RULES="org.kde.bismuth.debug=true"
kwin_x11 --replace & disown
HanabishiRecca commented 1 year ago

Can you see the windows in task manager and move them via Right Click > More > Move?

Can't say, windows do not appear at all, there are no borders or anything. Desktop is unusable.

Also, what the output of kwin?

org.kde.bismuth: Initiating Bismuth: Plasma Tiling Window script!
org.kde.bismuth: arrange
org.kde.bismuth: onWindowGeometryChanged,[object Object]
org.kde.bismuth: arrangeScreen/finished,[object Object]
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 1814, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 1815, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 1816, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 1818, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 1941, resource id: 46137436, major code: 18 (ChangeProperty), minor code: 0
QObject::killTimer: Timers cannot be stopped from another thread
QObject::~QObject: Timers cannot be stopped from another thread
qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 2005, resource id: 46137440, major code: 18 (ChangeProperty), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 2084, resource id: 46137447, major code: 18 (ChangeProperty), minor code: 0
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: onWindowGeometryChanged,[object Object]
org.kde.bismuth: arrangeScreen/finished,[object Object]
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: arrangeScreen/finished,[object Object]
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 2217, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 2218, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 2219, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 2221, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: onWindowGeometryChanged,[object Object]
org.kde.bismuth: arrangeScreen/finished,[object Object]
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: arrangeScreen/finished,[object Object]
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 4821, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 4822, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 4823, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
qt.qpa.xcb: QXcbConnection: XCB error: 2 (BadValue), sequence: 4825, resource id: 0, major code: 12 (ConfigureWindow), minor code: 0
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: arrangeScreen/finished,[object Object]
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: arrangeScreen/finished,[object Object]
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: arrangeScreen/finished,[object Object]
org.kde.bismuth: onCurrentSurfaceChanged,[object Object]
org.kde.bismuth: arrange
org.kde.bismuth: arrangeScreen/finished,[object Object]
gikari commented 1 year ago

I can confirm this bug. Bismuth works on kwin 5.25 and does not work on kwin 5.26 or master. I am currently trying to git bisect kwin changes, that broke Bismuth. This might take a long time, especially now, since I am in a process of moving my residence.

I recommend submitting the bug report to KWin upstream. KWin Scripts should not break on KWin upgrade, unless they depend on the implementation.

HanabishiRecca commented 1 year ago

I recommend submitting the bug report to KWin upstream. KWin Scripts should not break on KWin upgrade, unless they depend on the implementation.

Bismuth injects a binary kcm module, which is not really supported thing, and will not be addressed by KDE devs anyway. And I'm not sure about script part breakage.

HanabishiRecca commented 1 year ago

I just tested old Krohnkite script and it works with 5.26. So yeah, this is definitely not a general scripts breakage.

gikari commented 1 year ago

I doubt, that KCM module is the reason of breakage. It has nothing to do with window management, and the code runs only when you have the settings window open. However, just to clarify, KCM is a fully supported thing. There is even a tutorial on how to do it.

I just tested old Krohnkite script and it works with 5.26. So yeah, this is definitely not a general scripts breakage.

It might be, that Bismuth uses some scripting functionality, that Krohnkite does not. I will try to find out what exactly.

HanabishiRecca commented 1 year ago

It might be, that Bismuth uses some scripting functionality, that Krohnkite does not. I will try to find out what exactly.

If so, I can't help you with it unfortunately, because I'm not familiar with kwin scripts.

jkcdarunday commented 1 year ago

Same experience. It looks to me that it's positioning the windows outside the screen. The minimize/maximize animation animates them as if they're positioned to the top left just outside the screen. Floating a window and then using the task bar's Right Click > More > Move functionality allows me to move it into view from the top left.

cavillamizarc commented 1 year ago

Hi!. This same issue happened to me since I upgraded to plasma 5.25. The windows seem to be positioned outside the screen. The way I got to make them appear again was by disabling the option "Prevent window from protruding from its screen". This makes the windows come back to my screen but they still don't tile properly. I am using plasma 5.25.80 on Manjaro. Bismuth 3.1.3

gikari commented 1 year ago

Hi!. This same issue happened to me since I upgraded to plasma 5.25. The windows seem to be positioned outside the screen. The way I got to make them appear again was by disabling the option "Prevent window from protruding from its screen". This makes the windows come back to my screen but they still don't tile properly. I am using plasma 5.25.80 on Manjaro. Bismuth 3.1.3

Thanks, that will be useful. Btw, Plasma 5.25.80 is the same as 5.26. It's a convention in KDE to number betas like that.

cavillamizarc commented 1 year ago

Hi!. This same issue happened to me since I upgraded to plasma 5.25. The windows seem to be positioned outside the screen. The way I got to make them appear again was by disabling the option "Prevent window from protruding from its screen". This makes the windows come back to my screen but they still don't tile properly. I am using plasma 5.25.80 on Manjaro. Bismuth 3.1.3

Thanks, that will be useful. Btw, Plasma 5.25.80 is the same as 5.26. It's a convention in KDE to number betas like that.

Thank you for the clarification! I didn't know that. Still, this happened to me before version 5.25.80. Can't really remember what version I installed. I didn't report it earlier because I thought it was just an issue on my side since I had other scripts runnning. I just disabled Bismuth until I had the time to check what went wrong. Btw, I'm using Wayland, if that's of any help

gikari commented 1 year ago

This commit in KWin breaks Bismuth. I need some more time to know why.

gikari commented 1 year ago

I found the reason of the bug. I was wrong, that Bismuth does not use C++ KWin API Wrappers on master branch. The usages were replaced with the standard JS KWin API to prevent breakages in the future. Everyone is welcome to test the #427 PR.

This is food for thought on how to actually use KWin API from C++, though.