Re: [SOLVED] ARandR problem

Re: [SOLVED] ARandR problem

Yes this forced me to find a solution with xrandr and actually I have found a much better one. I used arandr to turn off my laptop screen when it is connected to a TV. In this forum I have found a script for dual monitor setup and after small modifications:

Is this an arch only problem or should this be reported upstream? I can't find any report of this error on arand website or gitorious where the project is hosted. (or is this related with xrandr update?)

Re: [SOLVED] ARandR problem

I don't have any xrandr output and i never used xrandr (directly), i've always used arandr and i get that error when trying to run arandr. It doesn't even show the GUI.(i can follow instructions though =P)

Re: [SOLVED] ARandR problem

What i meant is that i don't know the command that arandr issues to run manually and give you a complete output of xrandr error. Nor do i know how to extract that info.Although it will be hard since the error occurs at startup (not at "apply" time).

Re: [SOLVED] ARandR problem

That's the line which is throwing the curve balls. arandr expects the 3rd "word" to be the resolution and offset. In your case it's the word "primary", it then fails parsing what it thinks is the resolution.

There's a todo note in the code saying this parsing should be replaced with reading the output using --verbose or using a library. It's exactly this undone todo that's biting you.

I think the following will fix your issue. In /usr/lib/python2.7/site-packages/screenlayout/xrandr.py, change line 126 from:

hsplit = headline.split(" ")

to

hsplit = headline.replace("primary ", "").split(" ")

If it does, this fix should be reported upstream and perhaps to the Arch bugtracker.

Hopefully you don't run into more python problems later in the execution of arandr.