Opened 2 years ago

Closed 2 years ago

#66210 closed defect (fixed)

py27-py2app @0.28.4: SyntaxError: invalid syntax

Reported by: ryandesign (Ryan Carsten Schmidt) Owned by: jmroot (Joshua Root)
Priority: Normal Milestone:
Component: ports Version: 2.8.0
Keywords: Cc:
Port: py-py2app py-modulegraph

Description

Since September 30, py27-py2app fails to build on all systems:

https://build.macports.org/builders/ports-12_arm64-builder/builds/68201/steps/install-port/logs/stdio

Traceback (most recent call last):
  File "setup.py", line 383, in <module>
    dependency_links=[],  # workaround for setuptools 0.6b4 bug
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/setuptools/__init__.py", line 162, in setup
    return distutils.core.setup(**attrs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 111, in setup
    _setup_distribution = dist = klass(attrs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/setuptools/dist.py", line 448, in __init__
    k: v for k, v in attrs.items()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 287, in __init__
    self.finalize_options()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/setuptools/dist.py", line 739, in finalize_options
    for ep in sorted(eps, key=by_order):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/setuptools/dist.py", line 738, in <lambda>
    eps = map(lambda e: e.load(), pkg_resources.iter_entry_points(group))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2443, in load
    return self.resolve()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2449, in resolve
    module = __import__(self.module_name, fromlist=['__name__'], level=0)
  File "/opt/local/var/macports/build/_opt_bblocal_var_buildworker_ports_build_ports_python_py-py2app/py27-py2app/work/py2app-0.28.4/py2app/build_app.py", line 28, in <module>
    from modulegraph import modulegraph, zipio
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/modulegraph/modulegraph.py", line 26, in <module>
    from . import util, zipio
  File "/opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/modulegraph/util.py", line 108
    cookie_re = re.compile(rb"coding[:=]\s*([-\w.]+)")
                                                    ^
SyntaxError: invalid syntax

According to the changelog, 0.28 "is the last version of py2app with compatibility with Python 2.7. Future versions will require Python 3.6 or later."

Change History (2)

comment:1 Changed 2 years ago by jmroot (Joshua Root)

Port: py-modulegraph added

comment:2 Changed 2 years ago by jmroot (Joshua Root)

Resolution: fixed
Status: assignedclosed

In 84f52bc12ebb11f8c21a093f7c19cac87ba3f41d/macports-ports (master):

py-modulegraph: fix py27 incompatibility

Fixes: #66210

Note: See TracTickets for help on using tickets.