pip + how to download the latest version of the .whl files - python

Is it possible to download the latest version of .whl files?
for example, first, we try with pip download some specific version of enum34
pip download enum34-1.1.10-py2-none-any.whl
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
WARNING: Requirement 'enum34-1.1.10-py2-none-any.whl' looks like a filename, but the file does not exist
Processing ./enum34-1.1.10-py2-none-any.whl
ERROR: Exception:
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/pip/_internal/cli/base_command.py", line 188, in _main
status = self.run(options, args)
File "/usr/lib/python2.7/site-packages/pip/_internal/cli/req_command.py", line 185, in wrapper
return func(self, options, args)
File "/usr/lib/python2.7/site-packages/pip/_internal/commands/download.py", line 132, in run
reqs, check_supported_wheels=True
File "/usr/lib/python2.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 179, in resolve
discovered_reqs.extend(self._resolve_one(requirement_set, req))
File "/usr/lib/python2.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 362, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/usr/lib/python2.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 314, in _get_abstract_dist_for
abstract_dist = self.preparer.prepare_linked_requirement(req)
File "/usr/lib/python2.7/site-packages/pip/_internal/operations/prepare.py", line 469, in prepare_linked_requirement
hashes=hashes,
File "/usr/lib/python2.7/site-packages/pip/_internal/operations/prepare.py", line 264, in unpack_url
unpack_file(file.path, location, file.content_type)
File "/usr/lib/python2.7/site-packages/pip/_internal/utils/unpacking.py", line 252, in unpack_file
flatten=not filename.endswith('.whl')
File "/usr/lib/python2.7/site-packages/pip/_internal/utils/unpacking.py", line 112, in unzip_file
zipfp = open(filename, 'rb')
IOError: [Errno 2] No such file or directory: '/var/tmp/enum34-1.1.10-py2-none-any.whl'
then we try to download the latest version of enum34*
pip download enum34*
DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. pip 21.0 will drop support for Python 2.7 in January 2021. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
ERROR: Invalid requirement: 'enum34*'

Try pip download enum34 as there is no package named such as enum34* as shown below in the image. correct syntax

Related

pip._vendor.pep517.wrappers.BackendUnavailable error while installing cryptography

I'm trying to install cryptography to my system, but I get this error:
WARNING: Missing build requirements in pyproject.toml for cryptography from https://files.pythonhosted.org/packages/07/ca/bc827c5e55918ad223d59d299fff92f3563476c3b00d0a9157d9c0217449/cryptography-2.6.1.tar.gz#sha256=26c821cbeb683facb966045e2064303029d572a87ee69ca5a1bf54bf55f93ca6.
WARNING: The project does not specify a build backend, and pip cannot fall back to setuptools without 'setuptools>=40.8.0' and 'wheel'.
Getting requirements to build wheel ... done
ERROR: Exception:
Traceback (most recent call last):
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/cli/base_command.py", line 178, in main
status = self.run(options, args)
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/commands/install.py", line 352, in run
resolver.resolve(requirement_set)
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/resolve.py", line 131, in resolve
self._resolve_one(requirement_set, req)
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/resolve.py", line 294, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/resolve.py", line 242, in _get_abstract_dist_for
self.require_hashes
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/operations/prepare.py", line 368, in prepare_linked_requirement
abstract_dist.prep_for_dist(finder, self.build_isolation)
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/operations/prepare.py", line 175, in prep_for_dist
self.install_backend_dependencies(finder=finder)
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_internal/operations/prepare.py", line 123, in install_backend_dependencies
reqs = req.pep517_backend.get_requires_for_build_wheel()
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_vendor/pep517/wrappers.py", line 71, in get_requires_for_build_wheel
'config_settings': config_settings
File "/data/packages/usr/local/lib/python3.6/site-packages/pip/_vendor/pep517/wrappers.py", line 162, in _call_hook
raise BackendUnavailable
pip._vendor.pep517.wrappers.BackendUnavailable
This is my setup:
Alpine Linux 3.6.2
Python 3.6.3
pip 19.1
wheel 0.33.1
setuptools 41.0.1
Any idea what could be the problem, or how to solve it?
Thanks for the help in advance!
I did not find any uniform solution to this problem. You can try the following troubleshooting steps. one of them should work.
Upgrade the pip version.
Change the library/package version.
If you are installing from source, try a different .whl package or use tar.gz.
Use --no-use-pep517 with your pip install command (didn't work for me though, but I see it worked for some).
I got the same error with a different library and --no-use-pep517 did not help. However this did:
python -m pip install --upgrade pip

Installing pyinstaller error: raise backend unavailable

$ pip install pyinstaller
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
Collecting pyinstaller
Using cached https://files.pythonhosted.org/packages/03/32/0e0de593f129bf1d1e77eed562496d154ef4460fd5cecfd78612ef39a0cc/PyInstaller-3.4.tar.gz
Installing build dependencies ... done
Getting requirements to build wheel ... done
Exception:
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/cli/base_command.py", line 179, in main
status = self.run(options, args)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/commands/install.py", line 315, in run
resolver.resolve(requirement_set)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/resolve.py", line 131, in resolve
self._resolve_one(requirement_set, req)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/resolve.py", line 294, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/resolve.py", line 242, in _get_abstract_dist_for
self.require_hashes
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/operations/prepare.py", line 349, in prepare_linked_requirement
abstract_dist.prep_for_dist(finder, self.build_isolation)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_internal/operations/prepare.py", line 149, in prep_for_dist
reqs = self.req.pep517_backend.get_requires_for_build_wheel()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_vendor/pep517/wrappers.py", line 71, in get_requires_for_build_wheel
'config_settings': config_settings
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/_vendor/pep517/wrappers.py", line 162, in _call_hook
raise BackendUnavailable
BackendUnavailable
This happens when I try installing pyinstaller (on MacOS Mojave) and searching I can't find anything on the error.
Strangely, if I try installing on my personal user account on the Mac (both are admin) it works.
Any suggestions?

Issues installing python package Six (to install Pip)

We recently uninstalled pip to do some cleanup on Mac OS X El Capitan. Now trying to re-install pip.
$ sudo easy_install pip
Traceback (most recent call last):
File "/usr/local/bin/easy_install", line 11, in <module>
sys.exit(main())
File "/Library/Python/2.7/site-packages/setuptools/command/easy_install.py", line 2270, in main
**kw
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 321, in __init__
_Distribution.__init__(self, attrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 389, in finalize_options
ep.require(installer=self.fetch_build_egg)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 2324, in require
items = working_set.resolve(reqs, env, installer, extras=self.extras)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 859, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.VersionConflict: (six 1.4.1 (/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python), Requirement.parse('six>=1.6.0'))
Looks like we need to upgrade Six. So:
$ easy_install --upgrade six
Traceback (most recent call last):
File "/usr/local/bin/easy_install", line 11, in <module>
sys.exit(main())
File "/Library/Python/2.7/site-packages/setuptools/command/easy_install.py", line 2270, in main
**kw
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 321, in __init__
_Distribution.__init__(self, attrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 389, in finalize_options
ep.require(installer=self.fetch_build_egg)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 2324, in require
items = working_set.resolve(reqs, env, installer, extras=self.extras)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 859, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.VersionConflict: (six 1.4.1 (/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python), Requirement.parse('six>=1.6.0'))
Now it looks like we need to upgrade Six in order to upgrade Six??? Maybe it's just a permissions issue:
$sudo easy_install --upgrade six
Traceback (most recent call last):
File "/usr/local/bin/easy_install", line 11, in <module>
sys.exit(main())
File "/Library/Python/2.7/site-packages/setuptools/command/easy_install.py", line 2270, in main
**kw
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 321, in __init__
_Distribution.__init__(self, attrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 389, in finalize_options
ep.require(installer=self.fetch_build_egg)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 2324, in require
items = working_set.resolve(reqs, env, installer, extras=self.extras)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 859, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.VersionConflict: (six 1.4.1 (/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python), Requirement.parse('six>=1.6.0'))
Nope. Same error.
I'm obviously missing something. Can someone shed some light on this?
Tried the first answer:
$ python get-pip.py
Collecting pip
Using cached pip-9.0.1-py2.py3-none-any.whl
Collecting wheel
Using cached wheel-0.29.0-py2.py3-none-any.whl
Installing collected packages: pip, wheel
Exception:
Traceback (most recent call last):
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/commands/install.py", line 342, in run
prefix=options.prefix_path,
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/req/req_set.py", line 784, in install
**kwargs
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/req/req_install.py", line 851, in install
self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/req/req_install.py", line 1064, in move_wheel_files
isolated=self.isolated,
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/wheel.py", line 247, in move_wheel_files
prefix=prefix,
File "/var/folders/23/49gg72xd4wb1qps4z5j9vbz80000gy/T/tmpz5ckOD/pip.zip/pip/locations.py", line 140, in distutils_scheme
d = Distribution(dist_args)
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 321, in __init__
_Distribution.__init__(self, attrs)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/Library/Python/2.7/site-packages/setuptools/dist.py", line 389, in finalize_options
ep.require(installer=self.fetch_build_egg)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 2324, in require
items = working_set.resolve(reqs, env, installer, extras=self.extras)
File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 859, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
VersionConflict: (six 1.4.1 (/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python), Requirement.parse('six>=1.6.0'))
Python 2.7.9+ and 3.4+
Good news! Python 3.4 (released March 2014) and Python 2.7.9 (released December 2014) ship with Pip. This is the best feature of any Python release. It makes the community's wealth of libraries accessible to everyone. Newbies are no longer excluded from using community libraries by the prohibitive difficulty of setup. In shipping with a package manager, Python joins Ruby, Node.js, Haskell, Perl, Go--almost every other contemporary language with a majority open-source community. Thank you Python.
Of course, that doesn't mean Python packaging is problem solved. The experience remains frustrating. I discuss this in Stack Overflow question Does Python have a package/module management system?.
And, alas for everyone using Python 2.7.8 or earlier (a sizable portion of the community). There's no plan to ship Pip to you. Manual instructions follow.
Python 2 ≤ 2.7.8 and Python 3 ≤ 3.3
Flying in the face of its 'batteries included' motto, Python ships without a package manager. To make matters worse, Pip was--until recently--ironically difficult to install.
Official instructions
Per https://pip.pypa.io/en/stable/installing/#do-i-need-to-install-pip:
Download get-pip.py, being careful to save it as a .py file rather than .txt. Then, run it from the command prompt:
python get-pip.py
You possibly need an administrator command prompt to do this. Follow Start a Command Prompt as an Administrator (Microsoft TechNet).
Alternative instructions
The official documentation tells users to install Pip and each of its dependencies from source. That's tedious for the experienced, and prohibitively difficult for newbies.
For our sake, Christoph Gohlke prepares Windows installers (.msi) for popular Python packages. He builds installers for all Python versions, both 32 and 64 bit. You need to
Install setuptools
Install pip
For me, this installed Pip at C:\Python27\Scripts\pip.exe. Find pip.exe on your computer, then add its folder (for example, C:\Python27\Scripts) to your path (Start / Edit environment variables). Now you should be able to run pip from the command line. Try installing a package:
pip install httpie
There you go (hopefully)! Solutions for common problems are given below:
Proxy problems
If you work in an office, you might be behind a HTTP proxy. If so, set the environment variables http_proxy and https_proxy. Most Python applications (and other free software) respect these. Example syntax:
http://proxy_url:port
http://username:password#proxy_url:port
If you're really unlucky, your proxy might be a Microsoft NTLM proxy. Free software can't cope. The only solution is to install a free software friendly proxy that forwards to the nasty proxy. http://cntlm.sourceforge.net/
Unable to find vcvarsall.bat
Python modules can be part written in C or C++. Pip tries to compile from source. If you don't have a C/C++ compiler installed and configured, you'll see this cryptic error message.
Error: Unable to find vcvarsall.bat
You can fix that by installing a C++ compiler such as MinGW or Visual C++. Microsoft actually ship one specifically for use with Python. Or try Microsoft Visual C++ Compiler for Python 2.7.
Often though it's easier to check Christoph's site for your package.

Error in installing setuptools (unorderable types: str() < NoneType())

Python 3.4.2, 32 bit - Win 8.1, 64 bit
First I was trying to upgrade setuptools, but it was not successful. So I decided to uninstall the previous version. Now I can't install setuptools. I have tried the following:
pip install setuptools:
Exception:
Traceback (most recent call last):
File "C:\Python34\lib\site-packages\pip\basecommand.py", line 232, in main
status = self.run(options, args)
File "C:\Python34\lib\site-packages\pip\commands\install.py", line 339, in run
requirement_set.prepare_files(finder)
File "C:\Python34\lib\site-packages\pip\req\req_set.py", line 229, in prepare_
files
req_to_install.check_if_exists()
File "C:\Python34\lib\site-packages\pip\req\req_install.py", line 928, in chec
k_if_exists
self.satisfied_by = pkg_resources.get_distribution(self.req)
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 461, in get_distribution
dist = get_provider(dist)
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 341, in get_provider
return working_set.find(moduleOrReq) or require(str(moduleOrReq))[0]
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 870, in require
needed = self.resolve(parse_requirements(requirements))
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 740, in resolve
env = Environment(self.entries)
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 927, in __init__
self.scan(search_path)
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 957, in scan
self.add(dist)
File "C:\Python34\lib\site-packages\pip\_vendor\pkg_resources\__init__.py", li
ne 977, in add
dists.sort(key=operator.attrgetter('hashcmp'), reverse=True)
TypeError: unorderable types: str() < NoneType()
Running (Invoke-WebRequest https://bootstrap.pypa.io/ez_setup.py).Content | python - in a powershell with admin privileges:
PS C:\Windows\system32> > (Invoke-WebRequest https://bootstrap.pypa.io/ez_setup.py).Content | python -
Invoke-WebRequest : The response content cannot be parsed because the Internet Explorer engine is not available, or
Internet Explorer's first-launch configuration is not complete. Specify the UseBasicParsing parameter and try again.
At line:1 char:4
+ > (Invoke-WebRequest https://bootstrap.pypa.io/ez_setup.py).Content | python -
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotImplemented: (:) [Invoke-WebRequest], NotSupportedException
+ FullyQualifiedErrorId : WebCmdletIEDomNotSupportedException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
(I'm not willing to install Internet Explorer right now, but if you think I have to, then I will.)
Downloaded the ez_setup.py and ran it:
Installing Setuptools
running install
Traceback (most recent call last):
File "setup.py", line 180, in <module>
dist = setuptools.setup(**setup_params)
File "C:\Python34\lib\distutils\core.py", line 148, in setup
dist.run_commands()
File "C:\Python34\lib\distutils\dist.py", line 955, in run_commands
self.run_command(cmd)
File "C:\Python34\lib\distutils\dist.py", line 974, in run_command
cmd_obj.run()
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\setuptools\c
ommand\install.py", line 67, in run
self.do_egg_install()
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\setuptools\c
ommand\install.py", line 103, in do_egg_install
cmd.ensure_finalized() # finalize before bdist_egg munges install cmd
File "C:\Python34\lib\distutils\cmd.py", line 107, in ensure_finalized
self.finalize_options()
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\setuptools\c
ommand\easy_install.py", line 319, in finalize_options
self.index_url, search_path=self.shadow_path, hosts=hosts,
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\setuptools\p
ackage_index.py", line 269, in __init__
Environment.__init__(self,*args,**kw)
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\pkg_resource
s\__init__.py", line 975, in __init__
self.scan(search_path)
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\pkg_resource
s\__init__.py", line 1005, in scan
self.add(dist)
File "C:\Users\a\AppData\Local\Temp\tmpo7o_bqrd\setuptools-11.3.1\pkg_resource
s\__init__.py", line 1025, in add
dists.sort(key=operator.attrgetter('hashcmp'), reverse=True)
TypeError: unorderable types: str() < NoneType()
Something went wrong during the installation.
See the error message above.
Repairing python installation by running python-3.4.2.msi and choosing the repair option. But still no setuptools:
>pip install scipy -U
Collecting scipy from https://pypi.python.org/packages/source/s/scipy/
.0.tar.gz#md5=639112f077f0aeb6d80718dc5019dc7a
Using cached scipy-0.15.0.tar.gz
setuptools must be installed to install from a source distribution
I think uninstalling and reinstalling python would fix the problem, but before trying that I thought maybe you can help me to find the cause of the problem and the right way to fix this. Thanks.
I was able to solve my problem (on Win 8.1 64bit, Python 3.4.2) with the change suggested here:
https://bitbucket.org/pypa/setuptools/pull-request/122/ensure-py_version-and-platform-are-str-in/diff#chg-pkg_resources/init.py
Instead of downloading ez_setup.py, use get-pip.py instead. From the docs, if setuptools is not installed, it will install it first.
Since you're still getting an error, try installing pip and setuptools from Christoph Gohlke's Python Extension Packages for Windows repository. Make sure you download the 32-bit installers for Python 3.4. Once downloaded, run the .exe files and hopefully everything will be back to normal. There are tons of scientific computing packages there, so if you want numpy linked against Intel's MKL, and scipy, which uses the enhanced version of numpy, go right ahead!
Well it seemed to me that my python installation was completely messed up. It could have been related to a temporary installation of python 2 on my system a few weeks ago. Anyway, I thought it would be easier for me to just uninstall and reinstall the whole thing. So I uninstalled python and then reinstalled, but even that was not enough. Finally, I manually deleted C:\Python34 and reinstalled python and now it works fine.

pip install django timeout on MacOSX Lion

On a MBP, following instructions (http://techblog.rosedu.org/python-environment.html), I installed Xcode 4.4.1, brew (brew doctor says all set), and then python. Next, I tried to setup virtualenv:
> $MYPYTHON/bin/python distribute_setup.py
> $MYPYTHON/bin/easy_install pip
> $MYPYTHON/bin/pip install virtualenv
I then created a virtual environment and tried to install django:
> $MYPYTHON/bin/virtualenv $MYENV
> $MYENV/bin/pip install Django
It downloads 98% and then hangs for a while, and finally I get a traceback indicating a timeout:
pcm#pcm-mac[302]% $MYENV/bin/pip install django
Downloading/unpacking django
Downloading Django-1.4.1.tar.gz (7.7Mb): 7.5Mb downloaded
Exception:
Traceback (most recent call last):
File "/Users/pcm/Documents/workspace/virtual/lib/python2.7/site-packages/pip-1.1-py2.7.egg/pip/basecommand.py", line 104, in main
status = self.run(options, args)
File "/Users/pcm/Documents/workspace/virtual/lib/python2.7/site-packages/pip-1.1-py2.7.egg/pip/commands/install.py", line 245, in run
requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)
File "/Users/pcm/Documents/workspace/virtual/lib/python2.7/site-packages/pip-1.1-py2.7.egg/pip/req.py", line 985, in prepare_files
self.unpack_url(url, location, self.is_download)
File "/Users/pcm/Documents/workspace/virtual/lib/python2.7/site-packages/pip-1.1-py2.7.egg/pip/req.py", line 1109, in unpack_url
retval = unpack_http_url(link, location, self.download_cache, self.download_dir)
File "/Users/pcm/Documents/workspace/virtual/lib/python2.7/site-packages/pip-1.1-py2.7.egg/pip/download.py", line 451, in unpack_http_url
download_hash = _download_url(resp, link, temp_location)
File "/Users/pcm/Documents/workspace/virtual/lib/python2.7/site-packages/pip-1.1-py2.7.egg/pip/download.py", line 368, in _download_url
chunk = resp.read(4096)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py", line 380, in read
data = self._sock.recv(left)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/httplib.py", line 553, in read
s = self.fp.read(amt)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py", line 380, in read
data = self._sock.recv(left)
timeout: timed out
I see the same thing, if I just run the version of pip from /usr/local/bin/. I tried other packages (selenium, mock) and they downloaded and installed fine.
I'm at a loss as to what I may be doing wrong, or if there is some issue with django installs via pip. Advice?
Use:
pip --default-timeout=60 install django

Categories