dado3212 / spaces-renamer

💻 Ability to rename desktop spaces on macOS 10.10+
MIT License
1.03k stars 29 forks source link

Space names keep switching to wrong spaces #100

Open nickgolob opened 1 month ago

nickgolob commented 1 month ago

Describe the bug
After naming all of my spaces, the order gets messed up (I name two spaces, A and B. Later the names switch to B and A). I think this happens most often when unplugging from an external monitor.

Versions

  1. MySIMBL version - MacForge 1.2.2 (3) ?
  2. Spaces Renamer version - 1.10.4
  3. MacOS version - 14.5 (23F79)

Command Outputs
Please paste the output of running these commands in Terminal:

root 1529 0.0 0.0 410676768 3728 ?? Ss Mon10PM 0:00.08 /Library/PrivilegedHelperTools/com.macenhance.MacForge.Injector nickgolob 1526 0.0 0.1 412190416 36352 ?? S Mon10PM 0:04.09 /Applications/MacForge.app/Contents/Library/LoginItems/MacForgeHelper.app/Contents/MacOS/MacForgeHelper

jvthomas90 commented 1 month ago

This may not necessarily be related to Spaces Renamer but rather how macOS is natively handling your Spaces based on the options you've configured in System Settings > Desktop and Dock > Mission Control

Screenshot 2024-07-17 at 19 18 15

The first toggle is the most likely culprit.

The other option you might want to consider experimenting with is the last toggle towards the very bottom, i.e. Displays have separate Spaces

Ergo, no "unexpected" rearrangement will occur due to you disconnecting your display, since they don't share usage stats anymore. It's a more nuanced and subtle approach, requiring you to still be mindful of how often you spend time in Space A and B lest they rearrange themselves (but at least that calculation will only occur on the main display as opposed to seemingly random reshuffling occurring based on the aggregate values of usage times from duplicate Spaces spanning across two different displays).

That said, the most direct and straightforward fix is the first solution I mentioned. Since that first toggle is explicitly designed to automatically sort Spaces, turning this toggle off will cause macOS to drop the "MRU" algorithm and effectively switch to a user-configured manual-sort where your Spaces will safely remain static until you drag them around again.

TL;DR

  1. the top toggle should definitely solve your problem right away, no further thought required, point, blank, period.
  2. Choose the bottom toggle if you ever come to appreciate the ease of access benefit that MRU sort provides (now that you know that that's what it's doing under the hood) and therefore want to keep that top toggle turned on but want to experiment with the sort only occurring per-display (i.e. no more abrupt or inexplicably sudden rearrangements once you disconnect your external display)
nickgolob commented 1 month ago

Thank you!! Appreciate your help!