ckan / ckanext-dcat

CKAN ♥ DCAT
164 stars 142 forks source link

error in rdflib-jsonld setup command: use_2to3 is invalid. #205

Closed weeix closed 2 years ago

weeix commented 2 years ago

Hi, I'm trying to install ckanext-dcat in my Dockerfile. However, while installing the requirements, rdflib-jsonld 0.4.0 failed to install:

[extbuild 5/9] RUN pip wheel --wheel-dir=/wheels -r https://raw.githubusercontent.com/ckan/ckanext-dcat/v1.1.3/requirements.txt:

8 1.905 Collecting rdflib==4.2.1

8 2.110 Downloading rdflib-4.2.1.tar.gz (889 kB)

8 31.44 Collecting rdflib-jsonld==0.4.0

8 31.48 Downloading rdflib-jsonld-0.4.0.tar.gz (53 kB)

8 33.27 ERROR: Command errored out with exit status 1:

8 33.27 command: /usr/bin/python -c 'import io, os, sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-wheel-syjuscl3/rdflib-jsonld_7bd4471f587a4faea0e6115451d7d5e1/setup.py'"'"'; file='"'"'/tmp/pip-wheel-syjuscl3/rdflib-jsonld_7bd4471f587a4faea0e6115451d7d5e1/setup.py'"'"';f = getattr(tokenize, '"'"'open'"'"', open)(file) if os.path.exists(file) else io.StringIO('"'"'from setuptools import setup; setup()'"'"');code = f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, file, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-96_mnoev

8 33.27 cwd: /tmp/pip-wheel-syjuscl3/rdflib-jsonld_7bd4471f587a4faea0e6115451d7d5e1/

8 33.27 Complete output (1 lines):

8 33.27 error in rdflib-jsonld setup command: use_2to3 is invalid.

8 33.27 ----------------------------------------

8 33.27 WARNING: Discarding https://files.pythonhosted.org/packages/ba/48/edaad22fc9de34500699f0c7fc9124385dd425fd18857244f126a6f7df66/rdflib-jsonld-0.4.0.tar.gz#sha256=144774786a2fc7de09b24a9309cbcccc78bc48b152536d2ea1c1df2ad715bc2d (from https://pypi.org/simple/rdflib-jsonld/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

8 33.27 ERROR: Could not find a version that satisfies the requirement rdflib-jsonld==0.4.0 (from versions: 0.2, 0.3, 0.4.0, 0.5.0, 0.6.0, 0.6.1, 0.6.2)

8 33.27 ERROR: No matching distribution found for rdflib-jsonld==0.4.0

Python 3.8.10 pip 21.2.4

weeix commented 2 years ago

https://setuptools.pypa.io/en/latest/history.html#v58-0-0

v58.0.0 04 Sep 2021

Breaking Changes

2086: Removed support for 2to3 during builds. Projects should port to a unified codebase or pin to an older version of Setuptools using PEP 518 build-requires.

Workaround: downgrade setuptools to v57.5.0 before installing the requirements

RUN pip install --force-reinstall 'setuptools<58.0.0'

rdflib-json already dropped use_2to3 since v0.6.1, is it possible to upgrade rdflib-json to a newer version?

seitenbau-govdata commented 2 years ago

Should be fixed with https://github.com/ckan/ckanext-dcat/pull/213

seitenbau-govdata commented 2 years ago

@weeix Fixed with https://github.com/ckan/ckanext-dcat/pull/213. And this was released in version 1.2.0. If not, please reopen the issue.