The upstream was right :), their build system is completly broken with
setuptools > 60
I need to fix this.
thanks for your help
Fred
Traceback (most recent call last):
File "/<<PKGBUILDDIR>>/setup.py", line 1137, in <module>
setup_package()
File "/<<PKGBUILDDIR>>/setup.py", line 1133, in setup_package
setup(**setup_kwargs)
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line 87, in
setup
return distutils.core.setup(**attrs)
File "/usr/lib/python3/dist-packages/setuptools/_distutils/core.py", line
172, in setup
ok = dist.parse_command_line()
File "/usr/lib/python3/dist-packages/setuptools/_distutils/dist.py", line
474, in parse_command_line
args = self._parse_command_opts(parser, args)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 1107, in
_parse_command_opts
nargs = _Distribution._parse_command_opts(self, parser, args)
File "/usr/lib/python3/dist-packages/setuptools/_distutils/dist.py", line
540, in _parse_command_opts
raise DistutilsClassError(
distutils.errors.DistutilsClassError: command class <class
'__main__.CleanCommand'> must subclass Command
E: pybuild pybuild:379: clean: plugin distutils failed with: exit code=1:
python3.10 setup.py clean
dh_auto_clean: error: pybuild --clean -i python{version} -p 3.10 returned exit
code 13
make: *** [debian/rules:16: clean] Error 25
dpkg-buildpackage: error: fakeroot debian/rules clean subprocess returned exit
status 2
----- Mail d’origine -----
De: PICCA Frederic-Emmanuel
<[email protected]>
À: Scott Kitterman <[email protected]>
Cc: [email protected]
Envoyé: Wed, 02 Nov 2022 09:03:45 +0100 (CET)
Objet: Re: build package xrayutilities - wheel and pip with setuptools
Ok, I understand better what is going on.
in pyproject.toml there is these lines.
[build-system]
requires = [
"wheel",
"setuptools<60.0.0",
"oldest-supported-numpy",
"scipy",
"sphinx",
"nbsphinx",
"silx>=0.10",
"Cython>=0.25"
]
indeed the setuptools < 60, can not be fullfill, So I think that this is why
it try to use pip in order to install the required version of setuptools.
the strack trace seems to config this.
dh clean --buildsystem=pybuild
dh_auto_clean -O--buildsystem=pybuild
install -d
/<<BUILDDIR>>/pyfai-0.21.3\+dfsg1/debian/.debhelper/generated/_source/home
pybuild --clean -i python{version} -p 3.10
I: pybuild base:240: python3.10 setup.py clean
/<<PKGBUILDDIR>>/setup.py:43: DeprecationWarning: The distutils
package is deprecated and slated for removal in Python 3.12. Use setuptools or
check PEP 632 for potential alternatives
from distutils.command.clean import clean as Clean
/usr/lib/python3/dist-packages/_distutils_hack/__init__.py:18: UserWarning:
Distutils was imported before Setuptools, but importing Setuptools also
replaces the `distutils` module in `sys.modules`. This may lead to undesirable
behaviors or errors. To avoid these issues, avoid using distutils directly,
ensure that setuptools is installed in the traditional way (e.g. not an
editable install), and/or make sure that setuptools is always imported before
distutils.
warnings.warn(
/usr/lib/python3/dist-packages/_distutils_hack/__init__.py:33: UserWarning:
Setuptools is replacing distutils.
warnings.warn("Setuptools is replacing distutils.")
INFO: Disabling color, you really want to install colorlog.
INFO:pythran:Disabling color, you really want to install colorlog.
INFO:pyFAI.setup:Use setuptools with cython
INFO:pyFAI.setup:Use setuptools.setup
/usr/lib/python3/dist-packages/setuptools/installer.py:27:
SetuptoolsDeprecationWarning: setuptools.installer is deprecated. Requirements
should be satisfied by a PEP 517 installer.
warnings.warn(
/usr/lib/python3/dist-packages/setuptools/installer.py:60: UserWarning: Unbuilt
egg for pyFAI [unknown version] (/<<PKGBUILDDIR>>)
environment = pkg_resources.Environment()
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None,
status=None)) after connection broken by 'ProxyError('Cannot connect
to proxy.',
NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection
object at 0x7fbbf0c8ae60>: Failed to establish a new connection: [Errno 111]
Connection refused'))': /simple/setuptools/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None,
status=None)) after connection broken by 'ProxyError('Cannot connect
to proxy.',
NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection
object at 0x7fbbf0c8ad40>: Failed to establish a new connection: [Errno 111]
Connection refused'))': /simple/setuptools/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None,
status=None)) after connection broken by 'ProxyError('Cannot connect
to proxy.',
NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection
object at 0x7fbbf0c8baf0>: Failed to establish a new connection: [Errno 111]
Connection refused'))': /simple/setuptools/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None,
status=None)) after connection broken by 'ProxyError('Cannot connect
to proxy.',
NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection
object at 0x7fbbf0c8bcd0>: Failed to establish a new connection: [Errno 111]
Connection refused'))': /simple/setuptools/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None,
status=None)) after connection broken by 'ProxyError('Cannot connect
to proxy.',
NewConnectionError('<pip._vendor.urllib3.connection.HTTPSConnection
object at 0x7fbbf0c8ace0>: Failed to establish a new connection: [Errno 111]
Connection refused'))': /simple/setuptools/
ERROR: Could not find a version that satisfies the requirement
setuptools<60.0.0 (from versions: none)
ERROR: No matching distribution found for setuptools<60.0.0
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/setuptools/installer.py", line
82, in fetch_build_egg
subprocess.check_call(cmd)
File "/usr/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/usr/bin/python3.10',
'-m', 'pip', '--disable-pip-version-check',
'wheel', '--no-deps', '-w',
'/tmp/tmpmx8yh9o_', '--quiet',
'setuptools<60.0.0']' returned non-zero exit status 1.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/<<PKGBUILDDIR>>/setup.py", line 1137, in
<module>
setup_package()
File "/<<PKGBUILDDIR>>/setup.py", line 1133, in
setup_package
setup(**setup_kwargs)
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line
86, in setup
_install_setup_requires(attrs)
File "/usr/lib/python3/dist-packages/setuptools/__init__.py", line
80, in _install_setup_requires
dist.fetch_build_eggs(dist.setup_requires)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 875,
in fetch_build_eggs
resolved_dists = pkg_resources.working_set.resolve(
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py",
line 789, in resolve
dist = best[req.key] = env.best_match(
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py",
line 1075, in best_match
return self.obtain(req, installer)
File "/usr/lib/python3/dist-packages/pkg_resources/__init__.py",
line 1087, in obtain
return installer(requirement)
File "/usr/lib/python3/dist-packages/setuptools/dist.py", line 945,
in fetch_build_egg
return fetch_build_egg(self, req)
File "/usr/lib/python3/dist-packages/setuptools/installer.py", line
84, in fetch_build_egg
raise DistutilsError(str(e)) from e
distutils.errors.DistutilsError: Command
'['/usr/bin/python3.10', '-m', 'pip',
'--disable-pip-version-check', 'wheel',
'--no-deps', '-w', '/tmp/tmpmx8yh9o_',
'--quiet', 'setuptools<60.0.0']' returned non-zero
exit status 1.
E: pybuild pybuild:379: clean: plugin distutils failed with: exit code=1:
python3.10 setup.py clean
dh_auto_clean: error: pybuild --clean -i python{version} -p 3.10 returned exit
code 13
make: *** [debian/rules:16: clean] Error 25
dpkg-buildpackage: error: fakeroot debian/rules clean subprocess returned exit
status 2