koekeishiya / yabai

A tiling window manager for macOS based on binary space partitioning

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Some spaces names are lost after sleep

mickaelperrin opened this issue · comments

This is an issue that I encounter since months and not since the upgrade to v7.

After waking up from sleep, some spaces names are lost and causes rules associated with that space to stop working.

The spaces which the name is lost are generally one the first (default) space of different monitors.

It looks like this is often the same space of a specific monitor that is lost.

I don't know if you can do something and if I can give some more specific details.

The first space is named in my yabairc file using the following commands:

export RIGHT_MONITOR=$(yabai -m query --displays | jq '.[] | select(.uuid|test("5C3C4F45-1D73-4F7A-9FD2-30A6B092251")) | .index')
get_first_space_of_monitor() {
  yabai -m query --spaces --display $1 | jq '.[0].index'
}
name_first_space() {
  local SPACE_ID=$(get_first_space_of_monitor $1)
  debug "Name space ($SPACE_ID): $2"
  yabai -m space "$SPACE_ID"  --label "$2"
}
 name_first_space $RIGHT_MONITOR "Side-Projet 1"

I run a setup with 1 MBP and 3 external monitors and 2 are exactly the same. This is generally one of the two same monitors which causes the issue.

Example of bug:

yabai -m query --spaces | jq '.[].label'
"Projet 1"
"Projet 2"
"Projet 3"
"Projet 4"
"Projet 5"
"dotfiles"
"docker"
"ansible"
"yeoman"
"git"
"Terminal 1"
"Terminal 2"
"Terminal 3"
"Terminal 4"
"Terminal 5"
"Terminal docker"
"Terminal ansible"
"web"
"Todo"
"" <------ BUG HERE
"Side-Projet 2"
"Side-Projet 3"
"Side-Projet 4"
"Side-Projet 5"
"virtualisation"
"Messages