onflapp / gs-desktop

GNUstep Desktop
https://onflapp.github.io/gs-desktop/index.html
MIT License
101 stars 6 forks source link

Preferences/Screen module sometimes does not enable Display when Lid is opened #30

Closed mclarenlabs closed 2 months ago

mclarenlabs commented 7 months ago

(Long description - Root Cause: possible OSEDisplay for-loop retain bug?)

I have installed gs-desktop on Debian 12 on a new laptop and have been using it on a daily basis. I try to use the laptop the same way I use other laptops - opening and closing the lid.

The Preferences app has code that manages the display and watches for "Lid" changes. This code is only activated in the Preferences/Screen module in the awakeFromNib method (so you must have opened the Preferences/Screen pane for it to begin operating).

What I noticed was that if the Preferences/Screen applet had been launched, and the Lid was opened and closed multiple times, sometimes the display would not turn on when opening the Lid. (The only way I could recover from this was either plugging in an external monitor or rebooting.)

I found that prior to the display not being properly managed there was a desktop.log message

    2024-01-09 06:44:48.720 Preferences[11209:11209] Scanner initialised with nil string

I think the root cause is a retain bug. There is a list of resolutions called allResolutions and the method in OSEDisplay called setActive performs an operation like this

    NSDictionary *resolution;
    for (NSDictionary *res in allResolutions) {
      if (condition) {
        resolution = res;
    break;
      }
    }
    return resolution;

It should be the following. The list allResolutions is updated frequently, and the holder of the element returned from the search operation needs to retain it I believe.

    NSDictionary *resolution;
    for (NSDictionary *res in allResolutions) {
      if (condition) {
        resolution = [res retain];
    break;
      }
     }
     return resolution;

This method does not alloc, init or copy "resolution", so I believe it should retain it before returning it. But it would be great to have someone confirm this thought.

This pattern occurs in two places

A Pull-request is being developed for onflapp/nextspace repo.

After implementing this change, I have not seen the "Scanner initialised" message for three days, and the laptop has always successfully awaked from Lid closed.

mclarenlabs commented 7 months ago

Evidence for the "Scanner initialised with nil string" message.

Tracked down to OSEDisplay#resolutionWithWidth:height:rate method. Altered this way

  for (res in allResolutions)
    {
      // BUG: 2024-01-09
#if 0
      resSize = NSSizeFromString([res objectForKey:OSEDisplaySizeKey]);
#else
      NSLog(@"BUG: resolutionWithWidth res:%@", res);
      NSString *sizeStr = [res objectForKey:OSEDisplaySizeKey];
      NSLog(@"BUG: resolutionWithWidth sizeStr:%@", sizeStr);
      resSize = NSSizeFromString(sizeStr);
#endif
      resRate = [[res objectForKey:OSEDisplayRateKey] floatValue];
      if (resSize.width == width && resSize.height == height)
        {

The output it produced was this. Each dict should be a "resolution" with a "Size" key, but one of them does not --- it is a dictionary representing a "layout".

My theory is that in a prior execution of resolutionWithWidth:height:rate: the selected resolution is returned to a caller that uses it and eventually releases it. The "allResolutions" list still has a reference, and the dictionary gets re-allocated to be used to hold a "layout". Thus, a "layout" ends up in the "allResolutions" array.

2024-01-09 06:44:48.719 Preferences[11209:11209] NXSystem: prepare to activate display: eDP-1 with hiddenFrame: {x = 0; y = 0; width = 1920; height = 1080}
2024-01-09 06:44:48.719 Preferences[11209:11209] NXSystem: prepare to activate display: eDP-1 with frame: {x = 0; y = 0; width = 0; height = 0}
2024-01-09 06:44:48.719 Preferences[11209:11209] BUG: before display setActive:YES
2024-01-09 06:44:48.719 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "60.04947"; Size = "{width = 1920; height = 1080}"; }
2024-01-09 06:44:48.719 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1920; height = 1080}
2024-01-09 06:44:48.719 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0155"; Size = "{width = 1920; height = 1080}"; }
2024-01-09 06:44:48.719 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1920; height = 1080}
2024-01-09 06:44:48.719 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.937"; Size = "{width = 1920; height = 1080}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1920; height = 1080}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.96284"; Size = "{width = 1920; height = 1080}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1920; height = 1080}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Active = NO; Frame = "{x = 0; y = 0; width = 0; height = 0}"; FrameHidden = "{x = 0; y = 0; width = 1920; height = 1080}"; FrameRate = 0; Gamma = {Blue = "1.00"; Brightness = "1.00"; Green = "1.00"; Red = "1.00"; }; ID = <00ffffff ffffff00 06af3d68 00000000 001d0104 a51f1178 03b81aa6 544a9b26 0e525500 00000101 01010101 01010101 01010101 01011437 80b87038 24401010 3e0035ae 10000018 0000000f 00000000 00000000 00000000 00200000 00fe0041 554f0a20 20202020 20202020 000000fe 00423134 3048414e 30362e38 200a00c8>; Main = YES; Name = "eDP-1"; PhysicalSize = "{width = 309; height = 174}"; Properties = {"Broadcast RGB" = {Supported = (Automatic, Full, "Limited 16:235"); Value = (Automatic); }; "CONNECTOR_ID" = {Supported = (236); Value = (236); }; CTM = {Value = (0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0); }; Colorspace = {Supported = (Default, "RGB_Wide_Gamut_Fixed_Point", "RGB_Wide_Gamut_Floating_Point", opRGB, "DCI-P3_RGB_D65", "BT2020_RGB", "BT601_YCC", "BT709_YCC", "XVYCC_601", "XVYCC_709", "SYCC_601", "opYCC_601", "BT2020_CYCC", "BT2020_YCC"); Value = (Default); }; EDID = <00ffffff ffffff00 06af3d68 00000000 001d0104 a51f1178 03b81aa6 544a9b26 0e525500 00000101 01010101 01010101 01010101 01011437 80b87038 24401010 3e0035ae 10000018 0000000f 00000000 00000000 00000000 00200000 00fe0041 554f0a20 20202020 20202020 000000fe 00423134 3048414e 30362e38 200a00c8>; "link-status" = {Supported = (Good, Bad); Value = (Good); }; "max bpc" = {Range = "{location=6, length=12}"; Value = (12); }; "non-desktop" = {Range = "{location=0, length=1}"; Value = (0); }; "panel orientation" = {Supported = (Normal, "Upside Down", "Left Side Up", "Right Side Up"); Value = (Normal); }; "scaling mode" = {Supported = (Full, Center, "Full aspect"); Value = ("Full aspect"); }; "vrr_capable" = {Range = "{location=0, length=1}"; Value = (0); }; }; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:(null)
2024-01-09 06:44:48.720 Preferences[11209:11209] Scanner initialised with nil string
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.95425"; Size = "{width = 1680; height = 1050}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1680; height = 1050}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.88325"; Size = "{width = 1680; height = 1050}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1680; height = 1050}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.97562"; Size = "{width = 1400; height = 1050}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1400; height = 1050}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9766"; Size = "{width = 1600; height = 900}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1600; height = 900}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.8833"; Size = "{width = 1600; height = 900}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1600; height = 900}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.94602"; Size = "{width = 1600; height = 900}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1600; height = 900}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.82476"; Size = "{width = 1600; height = 900}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1600; height = 900}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "60.01974"; Size = "{width = 1280; height = 1024}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 1024}
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.96413"; Size = "{width = 1400; height = 900}"; }
2024-01-09 06:44:48.720 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1400; height = 900}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.87983"; Size = "{width = 1400; height = 900}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1400; height = 900}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = 60; Size = "{width = 1280; height = 960}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 960}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.992"; Size = "{width = 1440; height = 810}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1440; height = 810}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9493"; Size = "{width = 1440; height = 810}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1440; height = 810}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.88205"; Size = "{width = 1368; height = 768}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1368; height = 768}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.8532"; Size = "{width = 1368; height = 768}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1368; height = 768}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9732"; Size = "{width = 1280; height = 800}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 800}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9432"; Size = "{width = 1280; height = 800}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 800}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.81033"; Size = "{width = 1280; height = 800}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 800}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.90955"; Size = "{width = 1280; height = 800}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 800}
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0016"; Size = "{width = 1280; height = 720}"; }
2024-01-09 06:44:48.721 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 720}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9821"; Size = "{width = 1280; height = 720}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 720}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.85513"; Size = "{width = 1280; height = 720}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 720}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.74471"; Size = "{width = 1280; height = 720}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1280; height = 720}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0747"; Size = "{width = 1024; height = 768}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1024; height = 768}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "60.00384"; Size = "{width = 1024; height = 768}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1024; height = 768}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = 120; Size = "{width = 960; height = 720}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 720}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.1013"; Size = "{width = 928; height = 696}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 928; height = 696}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0289"; Size = "{width = 896; height = 672}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 896; height = 672}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9067"; Size = "{width = 1024; height = 576}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1024; height = 576}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9187"; Size = "{width = 1024; height = 576}"; }
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1024; height = 576}
2024-01-09 06:44:48.722 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.89922"; Size = "{width = 1024; height = 576}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1024; height = 576}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.81952"; Size = "{width = 1024; height = 576}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 1024; height = 576}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.8655"; Size = "{width = 960; height = 600}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 600}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9975"; Size = "{width = 960; height = 600}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 600}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9257"; Size = "{width = 960; height = 540}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 540}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9757"; Size = "{width = 960; height = 540}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 540}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.62903"; Size = "{width = 960; height = 540}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 540}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.81822"; Size = "{width = 960; height = 540}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 960; height = 540}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = 120; Size = "{width = 800; height = 600}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 800; height = 600}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "60.31654"; Size = "{width = 800; height = 600}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 800; height = 600}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "56.25"; Size = "{width = 800; height = 600}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 800; height = 600}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0187"; Size = "{width = 840; height = 525}"; }
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 840; height = 525}
2024-01-09 06:44:48.723 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.7665"; Size = "{width = 840; height = 525}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 840; height = 525}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.91534"; Size = "{width = 864; height = 486}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 864; height = 486}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.57031"; Size = "{width = 864; height = 486}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 864; height = 486}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9512"; Size = "{width = 700; height = 525}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 700; height = 525}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.892"; Size = "{width = 800; height = 450}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 800; height = 450}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.6495"; Size = "{width = 800; height = 450}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 800; height = 450}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0395"; Size = "{width = 640; height = 512}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 512}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9283"; Size = "{width = 700; height = 450}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 700; height = 450}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.7597"; Size = "{width = 700; height = 450}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 700; height = 450}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = 120; Size = "{width = 640; height = 480}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 480}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.94048"; Size = "{width = 640; height = 480}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 480}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.50618"; Size = "{width = 720; height = 405}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 720; height = 405}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "58.98785"; Size = "{width = 720; height = 405}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 720; height = 405}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.7641"; Size = "{width = 684; height = 384}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 684; height = 384}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.7064"; Size = "{width = 684; height = 384}"; }
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 684; height = 384}
2024-01-09 06:44:48.724 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.7648"; Size = "{width = 640; height = 400}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 400}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9649"; Size = "{width = 640; height = 400}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 400}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.7103"; Size = "{width = 640; height = 360}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 360}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.6509"; Size = "{width = 640; height = 360}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 360}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.84043"; Size = "{width = 640; height = 360}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 360}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "59.32487"; Size = "{width = 640; height = 360}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 640; height = 360}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.0077"; Size = "{width = 512; height = 384}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 512; height = 384}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.9988"; Size = "{width = 512; height = 288}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 512; height = 288}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.8411"; Size = "{width = 512; height = 288}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 512; height = 288}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.2581"; Size = "{width = 480; height = 270}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 480; height = 270}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.6364"; Size = "{width = 480; height = 270}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 480; height = 270}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.6331"; Size = "{width = 400; height = 300}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 400; height = 300}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "112.6803"; Size = "{width = 400; height = 300}"; }
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 400; height = 300}
2024-01-09 06:44:48.725 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.8307"; Size = "{width = 432; height = 243}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 432; height = 243}
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.1406"; Size = "{width = 432; height = 243}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 432; height = 243}
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "120.105"; Size = "{width = 320; height = 240}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 320; height = 240}
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.0124"; Size = "{width = 360; height = 202}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 360; height = 202}
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "118.2579"; Size = "{width = 360; height = 202}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 360; height = 202}
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "119.6809"; Size = "{width = 320; height = 180}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 320; height = 180}
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth res:{Rate = "118.6497"; Size = "{width = 320; height = 180}"; }
2024-01-09 06:44:48.726 Preferences[11209:11209] BUG: resolutionWithWidth sizeStr:{width = 320; height = 180}
onflapp commented 7 months ago

Many thanks for putting all this effort into troubleshooting this. This must be some kind of corner case as I've never experienced this myself and I have used GSDE almost daily for more than one year now - both on Debian (ASUS) and Fedora (Thinkpad) laptops.

I trust your judgement here. Please feel free to create a pull request that fixes it for you and we test it in the wild.

mclarenlabs commented 7 months ago

Created PRs. I'm testing with a builtin 1920x1080 monitor, and external HDMI with 1920x1080 and a USBC with 1920x1200. reliable now.

Last thing is gs-wmaker sometimes not restarting properly after XRANDR update.

onflapp commented 2 months ago

I resolved most of the issues now. Please let me know how it works for you. Thanks!

mclarenlabs commented 1 month ago

I rebuilt everything. It seems much better. Very nice!