I'm trying to build a Debian package that uses dh-python, pybuild, and tox.
debuild -i runs dpkg-buildpackage, which runs debian/rules build, which runs dh build --with python2,python3 --buildsystem=pybuild, which runs dh_auto_test -O--buildsystem=pybuild, which runs tox -c .../tox.ini -e py27, which runs /usr/bin/python3 -m virtualenv --python /usr/bin/python2.7 py27, which fails with a traceback in .../pthurllib3:
Installing setuptools, pkg_resources, pip, wheel...
Complete output from command /home/mg/src/pov-ser...x/py27/bin/python2.7 - setuptools pkg_resources pip wheel:
Collecting setuptools
Exception:
Traceback (most recent call last):
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/commands/install.py", line 353, in run
wb.build(autobuilding=True)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/wheel.py", line 749, in build
self.requirement_set.prepare_files(self.finder)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/req/req_set.py", line 380, in prepare_files
ignore_dependencies=self.ignore_dependencies))
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/req/req_set.py", line 554, in _prepare_file
require_hashes
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/req/req_install.py", line 278, in populate_link
self.link = finder.find_requirement(self, upgrade)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/index.py", line 465, in find_requirement
all_candidates = self.find_all_candidates(req.name)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/index.py", line 423, in find_all_candidates
for page in self._get_pages(url_locations, project_name):
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/index.py", line 568, in _get_pages
page = self._get_page(location)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/index.py", line 683, in _get_page
return HTMLPage.get_page(link, session=self.session)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/index.py", line 792, in get_page
"Cache-Control": "max-age=600",
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/sessions.py", line 501, in get
return self.request('GET', url, **kwargs)
File "/usr/share/python-wheels/pip-9.0.1-py2.py3-none-any.whl/pip/download.py", line 386, in request
return super(PipSession, self).request(method, url, *args, **kwargs)
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/sessions.py", line 488, in request
resp = self.send(prep, **send_kwargs)
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/sessions.py", line 609, in send
r = adapter.send(request, **kwargs)
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/CacheControl-0.11.7-py2.py3-none-any.whl/cachecontrol/adapter.py", line 47, in send
resp = super(CacheControlAdapter, self).send(request, **kw)
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/requests-2.12.4-py2.py3-none-any.whl/requests/adapters.py", line 423, in send
timeout=timeout
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/urllib3-1.19.1-py2.py3-none-any.whl/urllib3/connectionpool.py", line 643, in urlopen
_stacktrace=sys.exc_info()[2])
File "/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/urllib3-1.19.1-py2.py3-none-any.whl/urllib3/util/retry.py", line 315, in increment
total -= 1
TypeError: unsupported operand type(s) for -=: 'Retry' and 'int'
----------------------------------------
...Installing setuptools, pkg_resources, pip, wheel...done.
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/virtualenv.py", line 2375, in <module>
main()
File "/usr/lib/python3/dist-packages/virtualenv.py", line 724, in main
symlink=options.symlink)
File "/usr/lib/python3/dist-packages/virtualenv.py", line 992, in create_environment
download=download,
File "/usr/lib/python3/dist-packages/virtualenv.py", line 922, in install_wheel
call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=SCRIPT)
File "/usr/lib/python3/dist-packages/virtualenv.py", line 817, in call_subprocess
% (cmd_desc, proc.returncode))
OSError: Command /home/mg/src/pov-ser...x/py27/bin/python2.7 - setuptools pkg_resources pip wheel failed with error code 2
Running virtualenv with interpreter /usr/bin/python2.7
ERROR: InvocationError: /usr/bin/python3 -m virtualenv --python /usr/bin/python2.7 py27 (see /home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/log/py27-0.log)
/home/mg/src/pov-server-page/pkgbuild/pov-server-page/.tox/py27/share/python-wheels/urllib3-1.19.1-py2.py3-none-any.whl is identical to /usr/share/python-wheels/urllib3-1.19.1-py2.py3-none-any.whl, and I assume virtualenv copies it from one place to another.
/usr/share/python-wheels/urllib3-1.19.1-py2.py3-none-any.whl comes from python-pip-whl, which is build from the python-pip source package.
ProblemType: Bug
DistroRelease: Ubuntu 17.10
Package: python-pip-whl 9.0.1-2
ProcVersionSignature: Ubuntu 4.13.0-25.29-generic 4.13.13
Uname: Linux 4.13.0-25-generic x86_64
NonfreeKernelModules: zfs zunicode zavl zcommon znvpair
ApportVersion: 2.20.7-0ubuntu3.7
Architecture: amd64
CurrentDesktop: GNOME
Date: Wed Jan 17 23:29:38 2018
InstallationDate: Installed on 2016-09-10 (494 days ago)
InstallationMedia: Ubuntu-GNOME 16.04.1 LTS "Xenial Xerus" - Release amd64 (20160720)
PackageArchitecture: all
SourcePackage: python-pip
UpgradeStatus: Upgraded to artful on 2017-10-19 (90 days ago)
I'm trying to build a Debian package that uses dh-python, pybuild, and tox.
debuild -i runs dpkg-buildpackage, which runs debian/rules build, which runs dh build --with python2,python3 --buildsystem= pybuild, which runs dh_auto_test -O--buildsystem =pybuild, which runs tox -c .../tox.ini -e py27, which runs /usr/bin/python3 -m virtualenv --python /usr/bin/python2.7 py27, which fails with a traceback in .../pthurllib3:
Installing setuptools, pkg_resources, pip, wheel... src/pov- ser...x/ py27/bin/ python2. 7 - setuptools pkg_resources pip wheel: python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ basecommand. py", line 215, in main python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ commands/ install. py", line 353, in run build(autobuild ing=True) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ wheel.py" , line 749, in build requirement_ set.prepare_ files(self. finder) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ req/req_ set.py" , line 380, in prepare_files dependencies= self.ignore_ dependencies) ) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ req/req_ set.py" , line 554, in _prepare_file python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ req/req_ install. py", line 278, in populate_link find_requiremen t(self, upgrade) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ index.py" , line 465, in find_requirement all_candidates( req.name) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ index.py" , line 423, in find_all_candidates pages(url_ locations, project_name): python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ index.py" , line 568, in _get_pages page(location) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ index.py" , line 683, in _get_page get_page( link, session= self.session) python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ index.py" , line 792, in get_page Control" : "max-age=600", mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ requests- 2.12.4- py2.py3- none-any. whl/requests/ sessions. py", line 501, in get python- wheels/ pip-9.0. 1-py2.py3- none-any. whl/pip/ download. py", line 386, in request method, url, *args, **kwargs) mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ requests- 2.12.4- py2.py3- none-any. whl/requests/ sessions. py", line 488, in request mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ requests- 2.12.4- py2.py3- none-any. whl/requests/ sessions. py", line 609, in send send(request, **kwargs) mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ CacheControl- 0.11.7- py2.py3- none-any. whl/cachecontro l/adapter. py", line 47, in send rolAdapter, self).send(request, **kw) mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ requests- 2.12.4- py2.py3- none-any. whl/requests/ adapters. py", line 423, in send mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ urllib3- 1.19.1- py2.py3- none-any. whl/urllib3/ connectionpool. py", line 643, in urlopen =sys.exc_ info()[ 2]) mg/src/ pov-server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ urllib3- 1.19.1- py2.py3- none-any. whl/urllib3/ util/retry. py", line 315, in increment ------- ------- ------- ------- ----- python3/ dist-packages/ virtualenv. py", line 2375, in <module> python3/ dist-packages/ virtualenv. py", line 724, in main options. symlink) python3/ dist-packages/ virtualenv. py", line 992, in create_environment download, python3/ dist-packages/ virtualenv. py", line 922, in install_wheel subprocess( cmd, show_stdout=False, extra_env=env, stdin=SCRIPT) python3/ dist-packages/ virtualenv. py", line 817, in call_subprocess src/pov- ser...x/ py27/bin/ python2. 7 - setuptools pkg_resources pip wheel failed with error code 2
Complete output from command /home/mg/
Collecting setuptools
Exception:
Traceback (most recent call last):
File "/usr/share/
status = self.run(options, args)
File "/usr/share/
wb.
File "/usr/share/
self.
File "/usr/share/
ignore_
File "/usr/share/
require_hashes
File "/usr/share/
self.link = finder.
File "/usr/share/
all_candidates = self.find_
File "/usr/share/
for page in self._get_
File "/usr/share/
page = self._get_
File "/usr/share/
return HTMLPage.
File "/usr/share/
"Cache-
File "/home/
return self.request('GET', url, **kwargs)
File "/usr/share/
return super(PipSession, self).request(
File "/home/
resp = self.send(prep, **send_kwargs)
File "/home/
r = adapter.
File "/home/
resp = super(CacheCont
File "/home/
timeout=timeout
File "/home/
_stacktrace
File "/home/
total -= 1
TypeError: unsupported operand type(s) for -=: 'Retry' and 'int'
-------
...Installing setuptools, pkg_resources, pip, wheel...done.
Traceback (most recent call last):
File "/usr/lib/
main()
File "/usr/lib/
symlink=
File "/usr/lib/
download=
File "/usr/lib/
call_
File "/usr/lib/
% (cmd_desc, proc.returncode))
OSError: Command /home/mg/
Running virtualenv with interpreter /usr/bin/python2.7
ERROR: InvocationError: /usr/bin/python3 -m virtualenv --python /usr/bin/python2.7 py27 (see /home/mg/ src/pov- server- page/pkgbuild/ pov-server- page/.tox/ py27/log/ py27-0. log)
/home/mg/ src/pov- server- page/pkgbuild/ pov-server- page/.tox/ py27/share/ python- wheels/ urllib3- 1.19.1- py2.py3- none-any. whl is identical to /usr/share/ python- wheels/ urllib3- 1.19.1- py2.py3- none-any. whl, and I assume virtualenv copies it from one place to another.
/usr/share/ python- wheels/ urllib3- 1.19.1- py2.py3- none-any. whl comes from python-pip-whl, which is build from the python-pip source package.
ProblemType: Bug ature: Ubuntu 4.13.0- 25.29-generic 4.13.13 dules: zfs zunicode zavl zcommon znvpair ture: all
DistroRelease: Ubuntu 17.10
Package: python-pip-whl 9.0.1-2
ProcVersionSign
Uname: Linux 4.13.0-25-generic x86_64
NonfreeKernelMo
ApportVersion: 2.20.7-0ubuntu3.7
Architecture: amd64
CurrentDesktop: GNOME
Date: Wed Jan 17 23:29:38 2018
InstallationDate: Installed on 2016-09-10 (494 days ago)
InstallationMedia: Ubuntu-GNOME 16.04.1 LTS "Xenial Xerus" - Release amd64 (20160720)
PackageArchitec
SourcePackage: python-pip
UpgradeStatus: Upgraded to artful on 2017-10-19 (90 days ago)