Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parsing XRandR output failed #25

Closed
zkf opened this issue Apr 14, 2015 · 2 comments
Closed

Parsing XRandR output failed #25

zkf opened this issue Apr 14, 2015 · 2 comments

Comments

@zkf
Copy link

zkf commented Apr 14, 2015

autorandr has stopped working for me with the latest git version (r168.93e5266-1).

Here's some output from a console session:

%autorandr --help

Traceback (most recent call last):
  File "/usr/bin/autorandr", line 624, in main
    profiles.update(load_profiles(profile_path))
  File "/usr/bin/autorandr", line 406, in load_profiles
    config[buffer[0].strip().split()[-1]] = XrandrOutput.from_config_file(edids, "".join(buffer))
  File "/usr/bin/autorandr", line 318, in from_config_file
    raise AutorandrException("Failed to find an EDID for output `%s' in setup file, required as `%s' is not off in config file." % (options["output"], options["output"]))
__main__.AutorandrException: Failed to find an EDID for output `VIRTUAL1' in setup file, required as `VIRTUAL1' is not off in config file. (line 318)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/autorandr", line 712, in <module>
    main(sys.argv)
  File "/usr/bin/autorandr", line 628, in main
    raise AutorandrException("Failed to load profiles", e)
__main__.AutorandrException
During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/autorandr", line 715, in <module>
    print(e, file=sys.stderr)
  File "/usr/bin/autorandr", line 100, in __str__
    retval.append(":\n  " % self.line)
TypeError: not all arguments converted during string formatting

Okay, lets remove the autorandr profiles directory and try again:

% rm -r .autorandr/
% autorandr --help

Parsing XRandR output failed, 6621 bytes left unmatched after regular expression, starting at byte 598 with ..'VIRTUAL1.6'. (line 239)
This appears to be a bug. Please help improving autorandr by reporting it upstream.
Please attach the output of `xrandr --verbose` to your bug report if appropriate.

Hence, this bug report :)

Here's the output asked for:

% xrandr --verbose
Screen 0: minimum 8 x 8, current 3200 x 1080, maximum 32767 x 32767
LVDS1 connected 1920x1080+0+0 (0x47) normal (normal left inverted right x axis y axis) 344mm x 194mm
    Identifier: 0x43
    Timestamp:  84094863
    Subpixel:   horizontal rgb
    Gamma:      1.0:1.0:1.0
    Brightness: 1.0
    Clones:    
    CRTC:       0
    CRTCs:      0 1 2
    Transform:  1.000000 0.000000 0.000000
                0.000000 1.000000 0.000000
                0.000000 0.000000 1.000000
               filter: 
    EDID: 
        00ffffffffffff004ca34c3100000000
        0015010380221378ea2de59d5c4e9a27
        1a505400000001010101010101010101
        010101010101293680a070381f401810
        250058c2100000190000000f00000000
        0000000000285a0a3c00000000fe0053
        414d53554e470a2020202020000000fe
        00313536485430312d3230310a20004e
    BACKLIGHT: 10 
        range: (0, 10)
    Backlight: 10 
        range: (0, 10)
    scaling mode: Full aspect 
        supported: None, Full, Center, Full aspect
  1920x1080 (0x47) 138.650MHz -HSync -VSync *current +preferred
        h: width  1920 start 1944 end 1960 total 2080 skew    0 clock  66.66KHz
        v: height 1080 start 1082 end 1087 total 1111           clock  60.00Hz
  1400x1050 (0xc6) 122.000MHz +HSync +VSync
        h: width  1400 start 1488 end 1640 total 1880 skew    0 clock  64.89KHz
        v: height 1050 start 1052 end 1064 total 1082           clock  59.98Hz
  1280x1024 (0xc7) 108.000MHz +HSync +VSync
        h: width  1280 start 1328 end 1440 total 1688 skew    0 clock  63.98KHz
        v: height 1024 start 1025 end 1028 total 1066           clock  60.02Hz
  1280x960 (0xc8) 108.000MHz +HSync +VSync
        h: width  1280 start 1376 end 1488 total 1800 skew    0 clock  60.00KHz
        v: height  960 start  961 end  964 total 1000           clock  60.00Hz
  1024x768 (0xc9) 65.000MHz -HSync -VSync
        h: width  1024 start 1048 end 1184 total 1344 skew    0 clock  48.36KHz
        v: height  768 start  771 end  777 total  806           clock  60.00Hz
  800x600 (0xca) 40.000MHz +HSync +VSync
        h: width   800 start  840 end  968 total 1056 skew    0 clock  37.88KHz
        v: height  600 start  601 end  605 total  628           clock  60.32Hz
  800x600 (0xcb) 36.000MHz +HSync +VSync
        h: width   800 start  824 end  896 total 1024 skew    0 clock  35.16KHz
        v: height  600 start  601 end  603 total  625           clock  56.25Hz
  640x480 (0xcc) 25.175MHz -HSync -VSync
        h: width   640 start  656 end  752 total  800 skew    0 clock  31.47KHz
        v: height  480 start  490 end  492 total  525           clock  59.94Hz
VGA1 connected 1280x1024+1920+0 (0xc7) normal (normal left inverted right x axis y axis) 376mm x 301mm
    Identifier: 0x44
    Timestamp:  84094863
    Subpixel:   unknown
    Gamma:      1.0:1.0:1.0
    Brightness: 1.0
    Clones:    
    CRTC:       1
    CRTCs:      0 1 2
    Transform:  1.000000 0.000000 0.000000
                0.000000 1.000000 0.000000
                0.000000 0.000000 1.000000
               filter: 
    EDID: 
        00ffffffffffff0010ac25404c334830
        1a1201030e261e78eeee91a3544c9926
        0f5054a54b00714f8180010101010101
        010101010101302a009851002a403070
        1300782d1100001e000000ff00473331
        364838364f3048334c0a000000fc0044
        454c4c203139303846500a20000000fd
        00384c1f530e000a2020202020200061
  1280x1024 (0xc7) 108.000MHz +HSync +VSync *current +preferred
        h: width  1280 start 1328 end 1440 total 1688 skew    0 clock  63.98KHz
        v: height 1024 start 1025 end 1028 total 1066           clock  60.02Hz
  1280x1024 (0x153) 135.000MHz +HSync +VSync
        h: width  1280 start 1296 end 1440 total 1688 skew    0 clock  79.98KHz
        v: height 1024 start 1025 end 1028 total 1066           clock  75.02Hz
  1152x864 (0x154) 108.000MHz +HSync +VSync
        h: width  1152 start 1216 end 1344 total 1600 skew    0 clock  67.50KHz
        v: height  864 start  865 end  868 total  900           clock  75.00Hz
  1024x768 (0x155) 78.800MHz +HSync +VSync
        h: width  1024 start 1040 end 1136 total 1312 skew    0 clock  60.06KHz
        v: height  768 start  769 end  772 total  800           clock  75.08Hz
  1024x768 (0xc9) 65.000MHz -HSync -VSync
        h: width  1024 start 1048 end 1184 total 1344 skew    0 clock  48.36KHz
        v: height  768 start  771 end  777 total  806           clock  60.00Hz
  800x600 (0x156) 49.500MHz +HSync +VSync
        h: width   800 start  816 end  896 total 1056 skew    0 clock  46.88KHz
        v: height  600 start  601 end  604 total  625           clock  75.00Hz
  800x600 (0xca) 40.000MHz +HSync +VSync
        h: width   800 start  840 end  968 total 1056 skew    0 clock  37.88KHz
        v: height  600 start  601 end  605 total  628           clock  60.32Hz
  640x480 (0x157) 31.500MHz -HSync -VSync
        h: width   640 start  656 end  720 total  840 skew    0 clock  37.50KHz
        v: height  480 start  481 end  484 total  500           clock  75.00Hz
  640x480 (0x158) 25.200MHz -HSync -VSync
        h: width   640 start  656 end  752 total  800 skew    0 clock  31.50KHz
        v: height  480 start  490 end  492 total  525           clock  60.00Hz
  720x400 (0x159) 28.320MHz -HSync +VSync
        h: width   720 start  738 end  846 total  900 skew    0 clock  31.47KHz
        v: height  400 start  412 end  414 total  449           clock  70.08Hz
VIRTUAL1 connected (normal left inverted right x axis y axis)
    Identifier: 0x45
    Timestamp:  84094863
    Subpixel:   no subpixels
    Clones:     VIRTUAL2
    CRTCs:      3 4
    Transform:  1.000000 0.000000 0.000000
                0.000000 1.000000 0.000000
                0.000000 0.000000 1.000000
               filter: 
    EDID: 
        00ffffffffffff0009d1db76f7200000
        2e11010380342178ea5ad5a7564b9b24
        135054bdef80714f81908180818ca940
        b30001010101283c80a070b023403020
        360007442100001ed50980a0205e6310
        10605208782d1100001a000000fd0038
        4c1e5311000a202020202020000000fc
        0042656e5120323431570a202020006b
  VIRTUAL1.639-1920x1200 (0xcd) 154.000MHz +HSync +VSync
        h: width  1920 start 1968 end 2000 total 2080 skew    0 clock  74.04KHz
        v: height 1200 start 1203 end 1209 total 1235           clock  59.95Hz
  VIRTUAL1.640-1680x1050 (0xce) 146.250MHz -HSync +VSync
        h: width  1680 start 1784 end 1960 total 2240 skew    0 clock  65.29KHz
        v: height 1050 start 1053 end 1059 total 1089           clock  59.95Hz
  VIRTUAL1.641-1600x1200 (0xcf) 162.000MHz +HSync +VSync
        h: width  1600 start 1664 end 1856 total 2160 skew    0 clock  75.00KHz
        v: height 1200 start 1201 end 1204 total 1250           clock  60.00Hz
  VIRTUAL1.642-1400x1050 (0xd0) 155.800MHz +HSync +VSync
        h: width  1400 start 1464 end 1784 total 1912 skew    0 clock  81.49KHz
        v: height 1050 start 1052 end 1064 total 1090           clock  74.76Hz
  1400x1050 (0xc6) 122.000MHz +HSync +VSync
        h: width  1400 start 1488 end 1640 total 1880 skew    0 clock  64.89KHz
        v: height 1050 start 1052 end 1064 total 1082           clock  59.98Hz
  VIRTUAL1.644-1280x1024 (0xd1) 141.820MHz -HSync +VSync
        h: width  1280 start 1376 end 1512 total 1744 skew    0 clock  81.32KHz
        v: height 1024 start 1025 end 1028 total 1070           clock  76.00Hz
  VIRTUAL1.645-1280x1024 (0xd2) 135.000MHz +HSync +VSync
        h: width  1280 start 1296 end 1440 total 1688 skew    0 clock  79.98KHz
        v: height 1024 start 1025 end 1028 total 1066           clock  75.02Hz
  VIRTUAL1.646-1280x1024 (0xd3) 132.750MHz -HSync +VSync
        h: width  1280 start 1368 end 1504 total 1728 skew    0 clock  76.82KHz
        v: height 1024 start 1025 end 1028 total 1067           clock  72.00Hz
  1280x1024 (0xc7) 108.000MHz +HSync +VSync
        h: width  1280 start 1328 end 1440 total 1688 skew    0 clock  63.98KHz
        v: height 1024 start 1025 end 1028 total 1066           clock  60.02Hz
  1280x960 (0xc8) 108.000MHz +HSync +VSync
        h: width  1280 start 1376 end 1488 total 1800 skew    0 clock  60.00KHz
        v: height  960 start  961 end  964 total 1000           clock  60.00Hz
  VIRTUAL1.649-1152x864 (0xd4) 108.000MHz +HSync +VSync
        h: width  1152 start 1216 end 1344 total 1600 skew    0 clock  67.50KHz
        v: height  864 start  865 end  868 total  900           clock  75.00Hz
  VIRTUAL1.650-1024x768 (0xd5) 78.750MHz +HSync +VSync
        h: width  1024 start 1040 end 1136 total 1312 skew    0 clock  60.02KHz
        v: height  768 start  769 end  772 total  800           clock  75.03Hz
  VIRTUAL1.651-1024x768 (0xd6) 75.000MHz -HSync -VSync
        h: width  1024 start 1048 end 1184 total 1328 skew    0 clock  56.48KHz
        v: height  768 start  771 end  777 total  806           clock  70.07Hz
  1024x768 (0xc9) 65.000MHz -HSync -VSync
        h: width  1024 start 1048 end 1184 total 1344 skew    0 clock  48.36KHz
        v: height  768 start  771 end  777 total  806           clock  60.00Hz
  VIRTUAL1.653-832x624 (0xd7) 57.284MHz -HSync -VSync
        h: width   832 start  864 end  928 total 1152 skew    0 clock  49.73KHz
        v: height  624 start  625 end  628 total  667           clock  74.55Hz
  VIRTUAL1.654-800x600 (0xd8) 49.500MHz +HSync +VSync
        h: width   800 start  816 end  896 total 1056 skew    0 clock  46.88KHz
        v: height  600 start  601 end  604 total  625           clock  75.00Hz
  VIRTUAL1.655-800x600 (0xd9) 50.000MHz +HSync +VSync
        h: width   800 start  856 end  976 total 1040 skew    0 clock  48.08KHz
        v: height  600 start  637 end  643 total  666           clock  72.19Hz
  800x600 (0xca) 40.000MHz +HSync +VSync
        h: width   800 start  840 end  968 total 1056 skew    0 clock  37.88KHz
        v: height  600 start  601 end  605 total  628           clock  60.32Hz
  800x600 (0xcb) 36.000MHz +HSync +VSync
        h: width   800 start  824 end  896 total 1024 skew    0 clock  35.16KHz
        v: height  600 start  601 end  603 total  625           clock  56.25Hz
  VIRTUAL1.658-700x525 (0xda) 77.900MHz +HSync +VSync DoubleScan
        h: width   700 start  732 end  892 total  956 skew    0 clock  81.49KHz
        v: height  525 start  526 end  532 total  545           clock  74.76Hz
  VIRTUAL1.659-700x525 (0xdb) 61.000MHz +HSync +VSync DoubleScan
        h: width   700 start  744 end  820 total  940 skew    0 clock  64.89KHz
        v: height  525 start  526 end  532 total  541           clock  59.98Hz
  VIRTUAL1.660-640x480 (0xdc) 31.500MHz -HSync -VSync
        h: width   640 start  656 end  720 total  840 skew    0 clock  37.50KHz
        v: height  480 start  481 end  484 total  500           clock  75.00Hz
  VIRTUAL1.661-640x480 (0xdd) 31.500MHz -HSync -VSync
        h: width   640 start  664 end  704 total  832 skew    0 clock  37.86KHz
        v: height  480 start  489 end  492 total  520           clock  72.81Hz
  VIRTUAL1.662-640x480 (0xde) 31.500MHz -HSync -VSync
        h: width   640 start  656 end  696 total  832 skew    0 clock  37.86KHz
        v: height  480 start  481 end  484 total  520           clock  72.81Hz
  640x480 (0xcc) 25.175MHz -HSync -VSync
        h: width   640 start  656 end  752 total  800 skew    0 clock  31.47KHz
        v: height  480 start  490 end  492 total  525           clock  59.94Hz
  VIRTUAL1.664-640x350 (0xdf) 25.170MHz +HSync -VSync
        h: width   640 start  656 end  752 total  800 skew    0 clock  31.46KHz
        v: height  350 start  387 end  389 total  449           clock  70.07Hz
  VIRTUAL1.665-512x384 (0xe0) 37.500MHz -HSync -VSync DoubleScan
        h: width   512 start  524 end  592 total  664 skew    0 clock  56.48KHz
        v: height  384 start  385 end  388 total  403           clock  70.07Hz
  VIRTUAL1.666-512x384 (0xe1) 32.500MHz -HSync -VSync DoubleScan
        h: width   512 start  524 end  592 total  672 skew    0 clock  48.36KHz
        v: height  384 start  385 end  388 total  403           clock  60.00Hz
  VIRTUAL1.667-400x300 (0xe2) 25.000MHz +HSync +VSync DoubleScan
        h: width   400 start  428 end  488 total  520 skew    0 clock  48.08KHz
        v: height  300 start  318 end  321 total  333           clock  72.19Hz
  VIRTUAL1.668-320x240 (0xe3) 15.750MHz -HSync -VSync DoubleScan
        h: width   320 start  332 end  352 total  416 skew    0 clock  37.86KHz
        v: height  240 start  244 end  246 total  260           clock  72.81Hz
  VIRTUAL1.669-320x240 (0xe4) 12.587MHz -HSync -VSync DoubleScan
        h: width   320 start  328 end  376 total  400 skew    0 clock  31.47KHz
        v: height  240 start  245 end  246 total  262           clock  60.05Hz
VIRTUAL2 disconnected (normal left inverted right x axis y axis)
    Identifier: 0xc5
    Timestamp:  84094863
    Subpixel:   no subpixels
    Clones:     VIRTUAL1
    CRTCs:      3 4
    Transform:  1.000000 0.000000 0.000000
                0.000000 1.000000 0.000000
                0.000000 0.000000 1.000000
               filter: 

Hope this is helpful.

@phillipberndt
Copy link
Owner

Thanks! Actually, the change did not really break autorandr, but helped uncover this bug that has been there fore some time. Mode detection did never work for your VIRTUAL display in the first place.

The fun part is that literally a few days ago, when I made some changes to another project, FakeXrandR, I noticed that mode names do not need to follow the "<width>x<height>" pattern, but can be arbitrary; but then decided that this was far too esoteric to ever appear in the wild and require a fix in autorandr. Well .. ;-)

I now patched autorandr to differentiate between mode names and resolutions, this should fix this bug.

@zkf
Copy link
Author

zkf commented Apr 14, 2015

👍 Thanks, it works again now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants