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

nengo-gui not compatible with global inline flags in python 3.11 #1042

Open
lorypiro24 opened this issue Nov 19, 2022 · 1 comment · May be fixed by #1044
Open

nengo-gui not compatible with global inline flags in python 3.11 #1042

lorypiro24 opened this issue Nov 19, 2022 · 1 comment · May be fixed by #1044

Comments

@lorypiro24
Copy link

lorypiro24 commented Nov 19, 2022

Global inline flags have been deprecated since python 3.6.
In python 3.11 they are treated as an error, thus preventing nengo-guy from successfully loading.

Steps to reproduce the behavior:
Install python 3.11 and run nengo-gui (either try to import nengo-gui as a python module or type nengo in the system's shell)

Screenshots
Screenshot from 2022-11-19 15-05-43

Versions

  • Nengo GUI version 0.4.9

Additional context
see here for more detail:
python/cpython#91222

dabeaz/ply#274

copy of the python interpreter's error message:
Traceback (most recent call last):
File "/home/lorenzopirovano/.local/bin/nengo", line 5, in
from nengo_gui import main
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/init.py", line 1, in
from .gui import GUI, InteractiveGUI
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/gui.py", line 21, in
from nengo_gui.guibackend import GuiServer
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/guibackend.py", line 25, in
import nengo_gui.page
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/page.py", line 14, in
import nengo_gui.config
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/config.py", line 4, in
import nengo_gui.components
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/components/init.py", line 10, in
from .sim_control import SimControl
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/components/sim_control.py", line 10, in
from nengo_gui.server import WebSocketFrame
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/server.py", line 31, in
from nengo_gui._vendor.cookies import Cookies
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/_vendor/cookies.py", line 111, in
class Definitions(object):
File "/home/lorenzopirovano/.local/lib/python3.11/site-packages/nengo_gui/_vendor/cookies.py", line 313, in Definitions
ATTR_RE = re.compile(ATTR)
^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/init.py", line 227, in compile
return _compile(pattern, flags)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/init.py", line 294, in _compile
p = _compiler.compile(pattern, flags)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_compiler.py", line 743, in compile
p = _parser.parse(p, flags)
^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 980, in parse
p = _parse_sub(source, state, flags & SRE_FLAG_VERBOSE, 0)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 455, in _parse_sub
itemsappend(_parse(source, state, verbose, nested + 1,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 863, in _parse
p = _parse_sub(source, state, sub_verbose, nested + 1)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 455, in _parse_sub
itemsappend(_parse(source, state, verbose, nested + 1,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 863, in _parse
p = _parse_sub(source, state, sub_verbose, nested + 1)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 455, in _parse_sub
itemsappend(_parse(source, state, verbose, nested + 1,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib64/python3.11/re/_parser.py", line 841, in _parse
raise source.error('global flags not at the start '
re.error: global flags not at the start of the expression at position 399 (line 7, column 33)

@Eekehgnbm
Copy link

I encountered this issue as well. Hopefully someone can provide a fix? Thanks in advance!

@Tartasprint Tartasprint linked a pull request May 24, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants