Opened 3 years ago

Closed 3 years ago

#64233 closed defect (fixed)

py39-spyder: runtime failure

Reported by: mf2k (Frank Schima) Owned by: reneeotten (Renee Otten)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: py-spyder

Description

I'm currently not able to run py39-spyder:

$ spyder
Traceback (most recent call last):
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 573, in _build_master
    ws.require(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 891, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 782, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (QDarkStyle 3.0.3 (/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages), Requirement.parse('qdarkstyle==3.0.2'), {'spyder'})

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/opt/local/bin/spyder", line 33, in <module>
    sys.exit(load_entry_point('spyder==5.2.0', 'gui_scripts', 'spyder')())
  File "/opt/local/bin/spyder", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/importlib/metadata.py", line 77, in load
    module = import_module(match.group('module'))
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/spyder/app/start.py", line 50, in <module>
    from spyder.utils.external import lockfile
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/spyder/utils/external/lockfile.py", line 31, in <module>
    from spyder.utils.programs import is_spyder_process
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/spyder/utils/programs.py", line 28, in <module>
    import pkg_resources
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3267, in <module>
    def _initialize_master_working_set():
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3241, in _call_aside
    f(*args, **kwargs)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 3279, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 575, in _build_master
    return cls._build_from_requirements(__requires__)
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 588, in _build_from_requirements
    dists = ws.resolve(reqs, Environment())
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pkg_resources/__init__.py", line 777, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'qdarkstyle==3.0.2' distribution was not found and is required by spyder

Change History (3)

comment:1 Changed 3 years ago by mf2k (Frank Schima)

py39-qdarkstyle is installed but apparently not being recognized due to an unexpected version.

$ port installed py39-qdarkstyle
The following ports are currently installed:
  py39-qdarkstyle @3.0.3_0 (active)
Last edited 3 years ago by mf2k (Frank Schima) (previous) (diff)

comment:2 Changed 3 years ago by reneeotten (Renee Otten)

Status: assignedaccepted

Spyder has the annoying habit to sometimes request a (very) specific version of a dependency. Here the issue is, as is clear from the Traceback, that Spyder wants qdarkstyle==3.0.2, but MacPorts' version is 3.0.3. I'll take a look to remove that dependency restriction, and update py-spyder to recently released version 5.2.1.

Last edited 3 years ago by reneeotten (Renee Otten) (previous) (diff)

comment:3 Changed 3 years ago by reneeotten (Renee Otten)

Resolution: fixed
Status: acceptedclosed

In a06277a68e878139c48ddda5e1821f301fd5d7ae/macports-ports (master):

py-spyder: update to 5.2.1

Closes: #64233

Note: See TracTickets for help on using tickets.