Closed XavierChB closed 1 year ago
Hello, it has been fixed yesterday in waybar's module, try to build waybar from master 👍
I also had this issue and I have been re-installing waybar from master today. Even with the new installation, the updates are only reflected when I manually reload waybar. Has the format I need to configure the module in waybar changed?
The change in waybar depends on the change made in hyprland, which was also done on the same day, so you actually need to compile both from latest code, sorry I forgot to mention it earlier!
Other than that, the default format
of hyprland/workspaces
is {id}
and you need to change it to {name}
, but since you see some names after waybar restart, I suppose you did it...
The change in waybar depends on the change made in hyprland, which was also done on the same day, so you actually need to compile both from latest code, sorry I forgot to mention it earlier!
Other than that, the default
format
ofhyprland/workspaces
is{id}
and you need to change it to{name}
, but since you see some names after waybar restart, I suppose you did it...
Hi I've just compiled both hyprland and waybar with the latest git master version. The good news is that the "renameworkspace"
IPC event is now both correctly generated by hyprland IPC and handled by waybar, so if I run hyprctl dispatch renameworkspace 1 "xxx"
the changes are correctly reflected on waybar. The bad news is, hyprland-autoname-workspaces itself stops working:
$ env RUST_BACKTRACE=full hyprland-autoname-workspaces
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: SerdeError(Error("invalid value: integer `18446744073709551615`, expected i16", line: 12, column: 35))', src/renamer/mod.rs:278:34
stack backtrace:
0: 0x560b6f524c51 - <unknown>
1: 0x560b6f54c8ec - <unknown>
2: 0x560b6f5219ce - <unknown>
3: 0x560b6f524a65 - <unknown>
4: 0x560b6f5261fa - <unknown>
5: 0x560b6f525e93 - <unknown>
6: 0x560b6f5267fb - <unknown>
7: 0x560b6f5266f7 - <unknown>
8: 0x560b6f5250b6 - <unknown>
9: 0x560b6f526442 - <unknown>
10: 0x560b6f334623 - <unknown>
11: 0x560b6f334a83 - <unknown>
12: 0x560b6f3447b4 - <unknown>
13: 0x560b6f3704e2 - <unknown>
14: 0x560b6f367453 - <unknown>
15: 0x560b6f3713f9 - <unknown>
16: 0x560b6f51be0b - <unknown>
17: 0x560b6f370bf5 - <unknown>
18: 0x7f29d6827cd0 - <unknown>
19: 0x7f29d6827d8a - __libc_start_main
20: 0x560b6f334d45 - <unknown>
21: 0x0 - <unknown>
Other than that, the default
format
ofhyprland/workspaces
is{id}
and you need to change it to{name}
@cyrinux I think this should be placed here, just to prevent questions...
Sure, feel free to a quick PR for this or I will do when I can, thanks! edit: done
cyrinux you man are too fast. good job.
btw, i'm having the same issue as XavierChB, just to add to the report, maybe can help:
❯ hyprctl workspaces
workspace ID 2 (<b><span>2<tt> </tt></span></b>) on monitor DVI-D-1:
windows: 1
hasfullscreen: 0
lastwindow: 0x0
lastwindowtitle:
workspace ID 1 (1) on monitor HDMI-A-1:
windows: 4
hasfullscreen: 0
lastwindow: 0x55cf84dd73a0
lastwindowtitle: ~
edit: forgot to add that happens with my config and even the default found on the site.
I will try to check this evening for the error, I have to patch hyprland-rs maybe.
@pbosab @XavierChB a dump of hyprctl clients -j
can help when the crash occurs please.
Hmm I finally reproduce, I think its the type of monitor
field that change.
Window 558853a05b70 -> :
mapped: 0
hidden: 0
at: 0,0
size: 0,0
workspace: -1 ()
floating: 0
monitor: 18446744073709551615
class:
title:
initialClass:
initialTitle:
pid: 0
xwayland: 1
pinned: 0
fullscreen: 0
fullscreenmode: 0
fakefullscreen: 0
grouped: 0
swallowing: 0
I make a fix but I will have to do a release of hyprland-rs
, please be patient.
I will try to check this evening for the error, I have to patch hyprland-rs maybe. @pbosab @XavierChB a dump of
hyprctl clients -j
can help when the crash occurs please.
just got back to the pc but
I make a fix but I will have to do a release of
hyprland-rs
, please be patient.
seems like you already fixed it as always. gj
$ hyprland-autoname-workspaces
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: SerdeError(Error("invalid value: integer `18446744073709551615`, expected i16", line: 12, column: 35))', src/renamer/mod.rs:278:34
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
$ hyprctl clients -j
[{
"address": "0x55f4b0a401c0",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": 18446744073709551615,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55f4b0a41690",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": 18446744073709551615,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55f4b2a577c0",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": 18446744073709551615,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55f4b2a138b0",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": 18446744073709551615,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55f4b2ab7200",
"mapped": true,
"hidden": false,
"at": [1611, 45],
"size": [2538, 1384],
"workspace": {
"id": 1,
"name": "1"
},
"floating": false,
"monitor": 0,
"class": "kitty",
"title": "hyprctl clients -j",
"initialClass": "kitty",
"initialTitle": "zsh",
"pid": 8086,
"xwayland": false,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
}]
@cyrinux There you go. Yeah just as you have pointed out the monitor field is causing the int overflow.
Thanks, same error as I was able to find so, all good, hyprland move fast and there is often breaking like this, its not related to autoname but as a side project its impacted with some breaking change 😄 , fix will be merge and release done then.
I make a fix but I will have to do a release of
hyprland-rs
, please be patient.
PR merged
After changing the hyprland
dependency in Cargo.toml
to the latest git version, I can confirm that hyprland-autoname-workspaces now work as intended. Should I close the issue or should I wait for the cargo dependency list to be updated accordingly?
I just make a release, thanks you guys.
Guys it's me again. This time I've got some workspace with id -1.
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: SerdeError(Error("invalid value: integer `-1`, expected u64", line: 12, column: 17))', src/renamer/mod.rs:278:34
running hyprctl clients -j
gives:
[{
"address": "0x55c8106f75f0",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": -1,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55c8106fc220",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": -1,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55c8106feed0",
"mapped": false,
"hidden": false,
"at": [0, 0],
"size": [0, 0],
"workspace": {
"id": -1,
"name": ""
},
"floating": false,
"monitor": -1,
"class": "",
"title": "",
"initialClass": "",
"initialTitle": "",
"pid": 0,
"xwayland": true,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55c8107003a0",
"mapped": true,
"hidden": false,
"at": [11, 45],
"size": [1578, 944],
"workspace": {
"id": 5,
"name": "5"
},
"floating": false,
"monitor": 0,
"class": "kitty",
"title": "xxx@xxx:~",
"initialClass": "kitty",
"initialTitle": "zsh",
"pid": 50697,
"xwayland": false,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
},{
"address": "0x55c810710ca0",
"mapped": true,
"hidden": false,
"at": [1611, 11],
"size": [2538, 1418],
"workspace": {
"id": 1,
"name": "1 <span foreground='#d64000'></span>"
},
"floating": false,
"monitor": 1,
"class": "firefox",
"title": "[BUG] Changes in workspace names no longer reflected in waybar when using \"hyprland/workspaces\" · Issue #99 · hyprland-community/hyprland-autoname-workspaces — Mozilla Firefox",
"initialClass": "firefox",
"initialTitle": "Mozilla Firefox",
"pid": 49236,
"xwayland": false,
"pinned": false,
"fullscreen": false,
"fullscreenMode": 0,
"fakeFullscreen": false,
"grouped": [],
"swallowing": "0x0"
}]
Would it make sense to change it to i64 instead?
Guys it's me again. This time I've got some workspace with id -1.
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: SerdeError(Error("invalid value: integer `-1`, expected u64", line: 12, column: 17))', src/renamer/mod.rs:278:34
running
hyprctl clients -j
gives:[{ "address": "0x55c8106f75f0", "mapped": false, "hidden": false, "at": [0, 0], "size": [0, 0], "workspace": { "id": -1, "name": "" }, "floating": false, "monitor": -1, "class": "", "title": "", "initialClass": "", "initialTitle": "", "pid": 0, "xwayland": true, "pinned": false, "fullscreen": false, "fullscreenMode": 0, "fakeFullscreen": false, "grouped": [], "swallowing": "0x0" },{ "address": "0x55c8106fc220", "mapped": false, "hidden": false, "at": [0, 0], "size": [0, 0], "workspace": { "id": -1, "name": "" }, "floating": false, "monitor": -1, "class": "", "title": "", "initialClass": "", "initialTitle": "", "pid": 0, "xwayland": true, "pinned": false, "fullscreen": false, "fullscreenMode": 0, "fakeFullscreen": false, "grouped": [], "swallowing": "0x0" },{ "address": "0x55c8106feed0", "mapped": false, "hidden": false, "at": [0, 0], "size": [0, 0], "workspace": { "id": -1, "name": "" }, "floating": false, "monitor": -1, "class": "", "title": "", "initialClass": "", "initialTitle": "", "pid": 0, "xwayland": true, "pinned": false, "fullscreen": false, "fullscreenMode": 0, "fakeFullscreen": false, "grouped": [], "swallowing": "0x0" },{ "address": "0x55c8107003a0", "mapped": true, "hidden": false, "at": [11, 45], "size": [1578, 944], "workspace": { "id": 5, "name": "5" }, "floating": false, "monitor": 0, "class": "kitty", "title": "xxx@xxx:~", "initialClass": "kitty", "initialTitle": "zsh", "pid": 50697, "xwayland": false, "pinned": false, "fullscreen": false, "fullscreenMode": 0, "fakeFullscreen": false, "grouped": [], "swallowing": "0x0" },{ "address": "0x55c810710ca0", "mapped": true, "hidden": false, "at": [1611, 11], "size": [2538, 1418], "workspace": { "id": 1, "name": "1 <span foreground='#d64000'></span>" }, "floating": false, "monitor": 1, "class": "firefox", "title": "[BUG] Changes in workspace names no longer reflected in waybar when using \"hyprland/workspaces\" · Issue #99 · hyprland-community/hyprland-autoname-workspaces — Mozilla Firefox", "initialClass": "firefox", "initialTitle": "Mozilla Firefox", "pid": 49236, "xwayland": false, "pinned": false, "fullscreen": false, "fullscreenMode": 0, "fakeFullscreen": false, "grouped": [], "swallowing": "0x0" }]
Would it make sense to change it to i64 instead?
It already is 😛
Describe the bug Waybar has recently merged the
"hyprland/workspaces"
module into the new release, and as of my experiment with hyprland version 0.29.1, the old"wlr/workspaces"
module no longer works for hyprland on waybar, so I will be forced to switch to the hyprland workspaces module when I eventually upgrade my local hyprland.When using the new hyprland workspaces module, the workspace name is no longer dynamically updated when a new window is opened or closed, even though when I run
waybar --log-level trace
Hyprland IPC is still sending the correct event including the updated workspace names.The updates are only reflected when I manually reload waybar (i.e. pkill waybar && hyprctl dispatch exec waybar).
This could be a bug with the
hyprland/workspaces
module, please let me know how I can raise an issue there, including what specifically needs to be implemented, etc. Many thanks!Program version?
hyprland-autoname-workspaces 1.1.7
Program configuration dump? (ideally)
hyprland-autoname-workspaces --dump
To Reproduce Steps to reproduce the behavior:
Expected behavior Workspace name generated by hyprland-autoname-workspaces correctly reflected on waybar.
Linux Distro (please complete the following information):
OS: Arch Linux x86_64 Kernel: 6.4.12-arch1-1 Hyprland: v0.29.0 Waybar: v0.9.22
edit: fixed typos