pip3 crashing with "start() missing 1 required positional argument: 'sessionID'" - python

MacOS 11.6, Python 3.9
This behavior is new. I probably used pip successfully a month or two ago. Since that time I have worked with brew, but nothing that should have messed with the installation of Python or pip themselves. Happens in response to any pip3 install command. Any clues?
% python3 -m pip install --upgrade pip
Requirement already satisfied: pip in /Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages (22.2.2)
Collecting pip
Downloading pip-22.3.1-py3-none-any.whl (2.1 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 0.0/2.1 MB ? eta -:--:--ERROR: Exception:
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/cli/base_command.py", line 167, in exc_logging_wrapper
status = run_func(*args)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/cli/req_command.py", line 247, in wrapper
return func(self, options, args)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/commands/install.py", line 369, in run
requirement_set = resolver.resolve(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/resolver.py", line 92, in resolve
result = self._result = resolver.resolve(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/resolvelib/resolvers.py", line 481, in resolve
state = resolution.resolve(requirements, max_rounds=max_rounds)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/resolvelib/resolvers.py", line 348, in resolve
self._add_to_criteria(self.state.criteria, r, parent=None)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/resolvelib/resolvers.py", line 172, in _add_to_criteria
if not criterion.candidates:
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/resolvelib/structs.py", line 151, in __bool__
return bool(self._sequence)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/found_candidates.py", line 155, in __bool__
return any(self)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/found_candidates.py", line 143, in <genexpr>
return (c for c in iterator if id(c) not in self._incompatible_ids)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/found_candidates.py", line 97, in _iter_built_with_inserted
candidate = func()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/factory.py", line 206, in _make_candidate_from_link
self._link_candidate_cache[link] = LinkCandidate(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/candidates.py", line 297, in __init__
super().__init__(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/candidates.py", line 162, in __init__
self.dist = self._prepare()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/candidates.py", line 231, in _prepare
dist = self._prepare_distribution()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/resolution/resolvelib/candidates.py", line 308, in _prepare_distribution
return preparer.prepare_linked_requirement(self._ireq, parallel_builds=True)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/operations/prepare.py", line 438, in prepare_linked_requirement
return self._prepare_linked_requirement(req, parallel_builds)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/operations/prepare.py", line 483, in _prepare_linked_requirement
local_file = unpack_url(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/operations/prepare.py", line 165, in unpack_url
file = get_http_url(
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/operations/prepare.py", line 106, in get_http_url
from_path, content_type = download(link, temp_dir.path)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/network/download.py", line 147, in __call__
for chunk in chunks:
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_internal/cli/progress_bars.py", line 52, in _rich_progress_bar
with progress:
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/rich/progress.py", line 1165, in __enter__
self.start()
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/rich/progress.py", line 1156, in start
self.live.start(refresh=True)
File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/pip/_vendor/rich/live.py", line 132, in start
self._refresh_thread.start()
TypeError: start() missing 1 required positional argument: 'sessionID'
[notice] A new release of pip available: 22.2.2 -> 22.3.1
[notice] To update, run: pip install --upgrade pip

Related

pip 20.3.4 (python 2.7): Command "python setup.py egg_info" failed with error code 1

I'm trying to install library on app built with python 2.7 but getting the same error:
pipenv install newrelic==5.22.1.152
Installing newrelic==5.22.1.152...
Adding newrelic to Pipfile's [packages]...
✔ Installation Succeeded
Pipfile.lock (3fb6a7) out of date, updating to (527437)...
Locking [dev-packages] dependencies...
✘ Locking Failed!
Traceback (most recent call last):
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 126, in <module>
main()
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 119, in main
parsed.requirements_dir, parsed.packages)
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 85, in _main
requirements_dir=requirements_dir,
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 69, in resolve
req_dir=requirements_dir
File "/usr/local/lib/python2.7/site-packages/pipenv/utils.py", line 726, in resolve_deps
req_dir=req_dir,
File "/usr/local/lib/python2.7/site-packages/pipenv/utils.py", line 480, in actually_resolve_deps
resolved_tree = resolver.resolve()
File "/usr/local/lib/python2.7/site-packages/pipenv/utils.py", line 385, in resolve
results = self.resolver.resolve(max_rounds=environments.PIPENV_MAX_ROUNDS)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/resolver.py", line 102, in resolve
has_changed, best_matches = self._resolve_one_round()
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/resolver.py", line 206, in _resolve_one_round
for dep in self._iter_dependencies(best_match):
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/resolver.py", line 301, in _iter_dependencies
dependencies = self.repository.get_dependencies(ireq)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 234, in get_dependencies
legacy_results = self.get_legacy_dependencies(ireq)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 426, in get_legacy_dependencies
results, ireq = self.resolve_reqs(download_dir, ireq, wheel_cache)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 297, in resolve_reqs
results = resolver._resolve_one(reqset, ireq)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/resolve.py", line 260, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/resolve.py", line 213, in _get_abstract_dist_for
self.require_hashes
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/operations/prepare.py", line 294, in prepare_linked_requirement
abstract_dist.prep_for_dist(finder, self.build_isolation)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/operations/prepare.py", line 127, in prep_for_dist
self.req.run_egg_info()
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/req/req_install.py", line 474, in run_egg_info
command_desc='python setup.py egg_info')
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/utils/misc.py", line 705, in call_subprocess
% (command_desc, proc.returncode, cwd))
pipenv.patched.notpip._internal.exceptions.InstallationError: Command "python setup.py egg_info" failed with error code 1 in /tmp/tmpFSJ8cabuild/lazy-object-proxy/
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 126, in <module>
main()
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 119, in main
parsed.requirements_dir, parsed.packages)
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 85, in _main
requirements_dir=requirements_dir,
File "/usr/local/lib/python2.7/site-packages/pipenv/resolver.py", line 69, in resolve
req_dir=requirements_dir
File "/usr/local/lib/python2.7/site-packages/pipenv/utils.py", line 726, in resolve_deps
req_dir=req_dir,
File "/usr/local/lib/python2.7/site-packages/pipenv/utils.py", line 480, in actually_resolve_deps
resolved_tree = resolver.resolve()
File "/usr/local/lib/python2.7/site-packages/pipenv/utils.py", line 385, in resolve
results = self.resolver.resolve(max_rounds=environments.PIPENV_MAX_ROUNDS)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/resolver.py", line 102, in resolve
has_changed, best_matches = self._resolve_one_round()
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/resolver.py", line 206, in _resolve_one_round
for dep in self._iter_dependencies(best_match):
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/resolver.py", line 301, in _iter_dependencies
dependencies = self.repository.get_dependencies(ireq)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 234, in get_dependencies
legacy_results = self.get_legacy_dependencies(ireq)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 426, in get_legacy_dependencies
results, ireq = self.resolve_reqs(download_dir, ireq, wheel_cache)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/piptools/repositories/pypi.py", line 297, in resolve_reqs
results = resolver._resolve_one(reqset, ireq)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/resolve.py", line 260, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/resolve.py", line 213, in _get_abstract_dist_for
self.require_hashes
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/operations/prepare.py", line 294, in prepare_linked_requirement
abstract_dist.prep_for_dist(finder, self.build_isolation)
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/operations/prepare.py", line 127, in prep_for_dist
self.req.run_egg_info()
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/req/req_install.py", line 474, in run_egg_info
command_desc='python setup.py egg_info')
File "/usr/local/lib/python2.7/site-packages/pipenv/patched/notpip/_internal/utils/misc.py", line 705, in call_subprocess
% (command_desc, proc.returncode, cwd))
pipenv.patched.notpip._internal.exceptions.InstallationError: Command "python setup.py egg_info" failed with error code 1 in /tmp/tmpFSJ8cabuild/lazy-object-proxy/
I tried to update libraries:
pip install --upgrade setuptools -> Requirement already up-to-date:(44.1.1)
python -m pip install -U pip -> Requirement already up-to-date:(20.3.4)
pip install ez_setup -> Requirement already satisfied:(0.9)
Does it have something related to the fact, that the app is still using Python 2.7. Or we are still able to install libraries on this version? The last install library was phonenumbers 9 months ago and everything was fine since that time.

How to fix locking failed in pipenv?

I'm using pipenv inside a docker container. I tried installing a package and found that the installation succeeds (gets added to the Pipfile), but the locking keeps failing. Everything was fine until yesterday. Here's the error:
(app) root#7284b7892266:/usr/src/app# pipenv install scrapy-djangoitem
Installing scrapy-djangoitem…
Adding scrapy-djangoitem to Pipfile's [packages]…
✔ Installation Succeeded
Pipfile.lock (6d808e) out of date, updating to (27ac89)…
Locking [dev-packages] dependencies…
Building requirements...
Resolving dependencies...
✘ Locking Failed!
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/pipenv/resolver.py", line 807, in <module>
main()
File "/usr/local/lib/python3.7/site-packages/pipenv/resolver.py", line 803, in main
parsed.requirements_dir, parsed.packages, parse_only=parsed.parse_only)
File "/usr/local/lib/python3.7/site-packages/pipenv/resolver.py", line 785, in _main
resolve_packages(pre, clear, verbose, system, write, requirements_dir, packages)
File "/usr/local/lib/python3.7/site-packages/pipenv/resolver.py", line 758, in resolve_packages
results = clean_results(results, resolver, project)
File "/usr/local/lib/python3.7/site-packages/pipenv/resolver.py", line 634, in clean_results
reverse_deps = project.environment.reverse_dependencies()
File "/usr/local/lib/python3.7/site-packages/pipenv/project.py", line 376, in environment
self._environment = self.get_environment(allow_global=allow_global)
File "/usr/local/lib/python3.7/site-packages/pipenv/project.py", line 366, in get_environment
environment.extend_dists(pipenv_dist)
File "/usr/local/lib/python3.7/site-packages/pipenv/environment.py", line 127, in extend_dists
extras = self.resolve_dist(dist, self.base_working_set)
File "/usr/local/lib/python3.7/site-packages/pipenv/environment.py", line 122, in resolve_dist
deps |= cls.resolve_dist(dist, working_set)
File "/usr/local/lib/python3.7/site-packages/pipenv/environment.py", line 121, in resolve_dist
dist = working_set.find(req)
File "/root/.local/share/virtualenvs/app-lp47FrbD/lib/python3.7/site-packages/pkg_resources/__init__.py", line 642, in find
raise VersionConflict(dist, req)
pkg_resources.VersionConflict: (importlib-metadata 2.0.0 (/root/.local/share/virtualenvs/app-lp47FrbD/lib/python3.7/site-packages), Requirement.parse('importlib-metadata<2,>=0.12; python_version < "3.8"'))
(app) root#7284b7892266:/usr/src/app#
What could be wrong?
EDIT
After removing Pipfile.lock and trying to install a package, I got:
(app) root#ef80787b5c42:/usr/src/app# pipenv install httpx
Installing httpx…
Adding httpx to Pipfile's [packages]…
✔ Installation Succeeded
Pipfile.lock not found, creating…
Locking [dev-packages] dependencies…
Building requirements...
Resolving dependencies...
✔ Success!
Locking [packages] dependencies…
Building requirements...
⠏ Locking...Resolving dependencies...
Traceback (most recent call last):
File "/usr/local/bin/pipenv", line 8, in <module>
sys.exit(cli())
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/core.py", line 829, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/core.py", line 782, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/core.py", line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/decorators.py", line 73, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/click/decorators.py", line 21, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/local/lib/python3.7/site-packages/pipenv/cli/command.py", line 252, in install
site_packages=state.site_packages
File "/usr/local/lib/python3.7/site-packages/pipenv/core.py", line 2202, in do_install
skip_lock=skip_lock,
File "/usr/local/lib/python3.7/site-packages/pipenv/core.py", line 1303, in do_init
pypi_mirror=pypi_mirror,
File "/usr/local/lib/python3.7/site-packages/pipenv/core.py", line 1113, in do_lock
keep_outdated=keep_outdated
File "/usr/local/lib/python3.7/site-packages/pipenv/utils.py", line 1323, in venv_resolve_deps
c = resolve(cmd, sp)
File "/usr/local/lib/python3.7/site-packages/pipenv/utils.py", line 1136, in resolve
result = c.expect(u"\n", timeout=environments.PIPENV_INSTALL_TIMEOUT)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/delegator.py", line 215, in expect
self.subprocess.expect(pattern=pattern, timeout=timeout)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/pexpect/spawnbase.py", line 344, in expect
timeout, searchwindowsize, async_)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/pexpect/spawnbase.py", line 372, in expect_list
return exp.expect_loop(timeout)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/pexpect/expect.py", line 181, in expect_loop
return self.timeout(e)
File "/usr/local/lib/python3.7/site-packages/pipenv/vendor/pexpect/expect.py", line 144, in timeout
raise exc
pexpect.exceptions.TIMEOUT: <pexpect.popen_spawn.PopenSpawn object at 0x7f81e99bec90>
searcher: searcher_re:
0: re.compile('\n')
<pexpect.popen_spawn.PopenSpawn object at 0x7f81e99bec90>
searcher: searcher_re:
0: re.compile('\n')
(app) root#ef80787b5c42:/usr/src/app#
Here are my debugging notes. Still not sure which package is causing the problem, but this does seem to fix it.
The error you get when you first run pipenv install with pipenv version 2020.8.13.
Traceback (most recent call last):
File "/usr/local/bin/pipenv", line 8, in <module>
sys.exit(cli())
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 829, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 782, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/decorators.py", line 73, in new_func
return ctx.invoke(f, obj, *args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/core.py", line 610, in invoke
return callback(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/vendor/click/decorators.py", line 21, in new_func
return f(get_current_context(), *args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/pipenv/cli/command.py", line 252, in install
site_packages=state.site_packages
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 1928, in do_install
site_packages=site_packages,
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 580, in ensure_project
pypi_mirror=pypi_mirror,
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 512, in ensure_virtualenv
python=python, site_packages=site_packages, pypi_mirror=pypi_mirror
File "/usr/local/lib/python3.6/site-packages/pipenv/core.py", line 999, in do_create_virtualenv
project._environment.add_dist("pipenv")
File "/usr/local/lib/python3.6/site-packages/pipenv/environment.py", line 135, in add_dist
self.extend_dists(dist)
File "/usr/local/lib/python3.6/site-packages/pipenv/environment.py", line 127, in extend_dists
extras = self.resolve_dist(dist, self.base_working_set)
File "/usr/local/lib/python3.6/site-packages/pipenv/environment.py", line 122, in resolve_dist
deps |= cls.resolve_dist(dist, working_set)
File "/usr/local/lib/python3.6/site-packages/pipenv/environment.py", line 121, in resolve_dist
dist = working_set.find(req)
File "/usr/local/lib/python3.6/site-packages/pkg_resources/__init__.py", line 642, in find
raise VersionConflict(dist, req)
pkg_resources.VersionConflict: (importlib-metadata 2.0.0 (/usr/local/lib/python3.6/site-packages), Requirement.parse('importlib-metadata<2,>=0.12; python_version < "3.8"'))
If you run pip install -U pipenv it seems to change the importlib-metadata version:
Installing collected packages: importlib-metadata
Attempting uninstall: importlib-metadata
Found existing installation: importlib-metadata 2.0.0
Uninstalling importlib-metadata-2.0.0:
Successfully uninstalled importlib-metadata-2.0.0
Successfully installed importlib-metadata-1.7.0
Now if you run pipenv install -d --skip-lock it will finish. It seems like a library is requiring a version >= importlib-metadata 2.0.
When I pinned the following dependencies it didn't work at first when running pipenv lock, however, if I removed the lock file (rm Pipenv.lock) then it worked when I ran pipenv lock again.
virtualenv = "==20.0.31"
importlib-metadata = "==1.7.0"
Try to remove Pipefile.lock before installing a package
I had the same problem when creating a virtual environment using python 3.7.12. The problem is gone using python 3.8.10. On Ubuntu 20.04.4 LTS.
Here are some steps we followed, while we faced "locking failed"
1.make env
2.source /etc/pyenv
3.pipenv install
4.pipenv graph
5. Shoot the respective testcase execution (it may vary based on requirements)
Hope it works!!!:)
Just delete the Pipfile.lock then rerun pipenv lock.

Fail to install virtualenvwrapper on MacOX Sierra with (sudo pip install virtualenvwrapper)

How can I resolve the error caused by installing by command: sudo pip install virtualenvwrapper?
Collecting virtualenvwrapper
Downloading virtualenvwrapper-4.7.2.tar.gz (90kB)
100% |████████████████████████████████| 92kB 18kB/s
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/tmp/pip-build-Rhop8M/virtualenvwrapper/setup.py", line 7, in <module>
pbr=True,
File "/Applications/Canopy.app/appdata/canopy-1.6.2.3262.macosx-x86_64/Canopy.app/Contents/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/dist.py", line 268, in __init__
self.fetch_build_eggs(attrs['setup_requires'])
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/dist.py", line 312, in fetch_build_eggs
replace_conflicting=True,
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/pkg_resources/__init__.py", line 846, in resolve
dist = best[req.key] = env.best_match(req, ws, installer)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/pkg_resources/__init__.py", line 1091, in best_match
return self.obtain(req, installer)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/pkg_resources/__init__.py", line 1103, in obtain
return installer(requirement)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/dist.py", line 379, in fetch_build_egg
return cmd.easy_install(req)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/command/easy_install.py", line 627, in easy_install
not self.always_copy, self.local_index
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 601, in fetch_distribution
self.find_packages(requirement)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 438, in find_packages
self.scan_url(self.index_url + requirement.unsafe_name+'/')
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 772, in scan_url
self.process_url(url, True)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 305, in process_url
f = self.open_url(url, "Download error on %s: %%s -- Some packages may not be found!" % url)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 711, in open_url
return open_with_auth(url, self.opener)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 905, in _socket_timeout
return func(*args, **kwargs)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 1003, in open_with_auth
cred = PyPIConfig().find_credential(url)
File "/Users/Extremeways/Library/Enthought/Canopy_64bit/User/lib/python2.7/site-packages/setuptools/package_index.py", line 959, in __init__
self.read(rc)
File "/Applications/Canopy.app/appdata/canopy-1.6.2.3262.macosx-x86_64/Canopy.app/Contents/lib/python2.7/ConfigParser.py", line 305, in read
self._read(fp, filename)
File "/Applications/Canopy.app/appdata/canopy-1.6.2.3262.macosx-x86_64/Canopy.app/Contents/lib/python2.7/ConfigParser.py", line 512, in _read
raise MissingSectionHeaderError(fpname, lineno, line)
ConfigParser.MissingSectionHeaderError: File contains no section headers.
file: /Users/Extremeways/.pypirc, line: 1
'index-servers=\n'
----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /private/tmp/pip-build-Rhop8M/virtualenvwrapper/

cryptography AssertionError: sorry, but this version only supports 100 named groups

I'm installing several python packages via pip install on travis,
language: python
python:
- '2.7'
install:
- pip install -r requirements/env.txt
Everything worked fine, but today I started getting following error:
Running setup.py install for cryptography
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-build-hKwMR3/cryptography/setup.py", line 334, in <module>
**keywords_with_side_effects(sys.argv)
File "/opt/python/2.7.9/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/setuptools/dist.py", line 269, in __init__
_Distribution.__init__(self,attrs)
File "/opt/python/2.7.9/lib/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/setuptools/dist.py", line 325, in finalize_options
ep.load()(self, ep.name, value)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/setuptools_ext.py", line 181, in cffi_modules
add_cffi_module(dist, cffi_module)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/setuptools_ext.py", line 48, in add_cffi_module
execfile(build_file_name, mod_vars)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/setuptools_ext.py", line 24, in execfile
exec(code, glob, glob)
File "src/_cffi_src/build_openssl.py", line 81, in <module>
extra_link_args=extra_link_args(compiler_type()),
File "/tmp/pip-build-hKwMR3/cryptography/src/_cffi_src/utils.py", line 61, in build_ffi_for_binding
extra_link_args=extra_link_args,
File "/tmp/pip-build-hKwMR3/cryptography/src/_cffi_src/utils.py", line 70, in build_ffi
ffi.cdef(cdef_source)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/api.py", line 105, in cdef
self._cdef(csource, override=override, packed=packed)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/api.py", line 119, in _cdef
self._parser.parse(csource, override=override, **options)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/cparser.py", line 299, in parse
self._internal_parse(csource)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/cparser.py", line 304, in _internal_parse
ast, macros, csource = self._parse(csource)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/cparser.py", line 260, in _parse
ast = _get_parser().parse(csource)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/cffi/cparser.py", line 40, in _get_parser
_parser_cache = pycparser.CParser()
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/pycparser/c_parser.py", line 87, in __init__
outputdir=taboutputdir)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/pycparser/c_lexer.py", line 66, in build
self.lexer = lex.lex(object=self, **kwargs)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/pycparser/ply/lex.py", line 911, in lex
lexobj.readtab(lextab, ldict)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/pycparser/ply/lex.py", line 233, in readtab
titem.append((re.compile(pat, lextab._lexreflags | re.VERBOSE), _names_to_funcs(func_name, fdict)))
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/re.py", line 194, in compile
return _compile(pattern, flags)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/re.py", line 249, in _compile
p = sre_compile.compile(pattern, flags)
File "/home/travis/virtualenv/python2.7.9/lib/python2.7/sre_compile.py", line 583, in compile
"sorry, but this version only supports 100 named groups"
AssertionError: sorry, but this version only supports 100 named groups
Solutions?
There is a bug with PyCParser - See https://github.com/pyca/cryptography/issues/3187
The work around is to use another version or to not use the binary distribution.
pip install git+https://github.com/eliben/pycparser#release_v2.14
or
pip install --no-binary pycparser

Windows 8 pip install mitmproxy error

I am trying to install mitmproxy on Windows 8
pip install mitmproxy
I have installed Python version 2.7.9 and pip version 7.1.2
but I keep getting this error:
Collecting mitmproxy
Exception:
Traceback (most recent call last):
File "c:\python27\lib\site-packages\pip\basecommand.py", line 211, in main
status = self.run(options, args)
File "c:\python27\lib\site-packages\pip\commands\install.py", line 305, in run
wb.build(autobuilding=True)
File "c:\python27\lib\site-packages\pip\wheel.py", line 705, in build
self.requirement_set.prepare_files(self.finder)
File "c:\python27\lib\site-packages\pip\req\req_set.py", line 334, in prepare_files
functools.partial(self._prepare_file, finder))
File "c:\python27\lib\site-packages\pip\req\req_set.py", line 321, in _walk_req_to_install
more_reqs = handler(req_to_install)
File "c:\python27\lib\site-packages\pip\req\req_set.py", line 461, in _prepare_file
req_to_install.populate_link(finder, self.upgrade)
File "c:\python27\lib\site-packages\pip\req\req_install.py", line 250, in populate_link
self.link = finder.find_requirement(self, upgrade)
File "c:\python27\lib\site-packages\pip\req\req_install.py", line 262, in link
self._link = self._wheel_cache.cached_wheel(link, self.name)
File "c:\python27\lib\site-packages\pip\wheel.py", line 63, in cached_wheel
self._cache_dir, link, self._format_control, package_name)
File "c:\python27\lib\site-packages\pip\wheel.py", line 143, in cached_wheel
return pip.index.Link(path_to_url(path), trusted=True)
File "c:\python27\lib\site-packages\pip\download.py", line 456, in path_to_url
url = urllib_parse.urljoin('file:', urllib_request.pathname2url(path))
File "c:\python27\lib\nturl2path.py", line 65, in pathname2url
path = path + '/' + urllib.quote(comp)
File "c:\python27\lib\urllib.py", line 1294, in quote
return ''.join(map(quoter, s))
KeyError: u'\xe1'

Categories

Resources