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

autorandr /usr/bin/autorandr:210: SyntaxWarning: invalid escape sequence '\s' XRANDR_OUTPUT_REGEXP = """(?x) /usr/bin/autorandr:236: SyntaxWarning: invalid escape sequence '\s' """ + XRANDR_PROPERTIES_REGEXP + """ | # Properties to include in the profile /usr/bin/autorandr:248: SyntaxWarning: invalid escape sequence '\S' XRANDR_OUTPUT_MODES_REGEXP = """(?x) /usr/bin/autorandr:592: SyntaxWarning: invalid escape sequence '\s' version = re.search("xrandr program version\s+([0-9\.]+)", version_string).group(1) /usr/bin/autorandr:888: SyntaxWarning: invalid escape sequence '\+' match = re.match("(?P<w>[0-9]+)x(?P<h>[0-9]+)(?:\+(?P<x>[0-9]+))?(?:\+(?P<y>[0-9]+))?.*", output.options["panning"]) #383

Open
Castas115 opened this issue Apr 15, 2024 · 4 comments

Comments

@Castas115
Copy link

On a fresh install of autorandr I'm getting this error:
/usr/bin/autorandr:210: SyntaxWarning: invalid escape sequence '\s'
XRANDR_OUTPUT_REGEXP = """(?x)
/usr/bin/autorandr:236: SyntaxWarning: invalid escape sequence '\s'
""" + XRANDR_PROPERTIES_REGEXP + """ | # Properties to include in the profile
/usr/bin/autorandr:248: SyntaxWarning: invalid escape sequence '\S'
XRANDR_OUTPUT_MODES_REGEXP = """(?x)
/usr/bin/autorandr:592: SyntaxWarning: invalid escape sequence '\s'
version = re.search("xrandr program version\s+([0-9.]+)", version_string).group(1)
/usr/bin/autorandr:888: SyntaxWarning: invalid escape sequence '+'
match = re.match("(?P[0-9]+)x(?P[0-9]+)(?:+(?P[0-9]+))?(?:+(?P[0-9]+))?.*", output.options[panning"])

Python 3.12.2

@hughdavenport
Copy link

For what it is worth, it works for me on python 3.10.12 and python3.11.0rc1. Perhaps you could try an earlier version to see if you get the same issue or not to rule out the python version.

@fowlinbasket
Copy link

I am encountering the exact same warning on a fresh install of autorandr, also on python 3.12.2
autorandr still runs just fine. It just outputs that same chain of SyntaxWarnings every time I run it.

@reneas
Copy link

reneas commented Apr 28, 2024

I have the exact same warning but it only occured after upgrading from ubuntu 22.04 to 24.04 so maybe that is the problem?

@i300220
Copy link

i300220 commented May 3, 2024

Every python code not ported to python 3.12 does that. Therefore autorandr is affected on Fedora 39 and 40. Not a autorandr bug per se.

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

5 participants