python-wheel

Pip install and platform specific wheels

孤者浪人 提交于 2019-12-23 18:59:15
问题 How does pip install select wheels to install? Say I've built multiple wheels for different platforms, and upload to PyPI does pip install <package> automatically install the correct wheel that matches the platform? What happens if I've built a Linux specific wheel only and upload to PyPI, and someone on Windows/Mac trying to install it by running pip install <package> ? 回答1: PIP follows the PEP 425 Use recommendations; this stipulates how a binary distribution wheel is selected. Specifically

Christoph Gohlke Naming Convention for Unofficial Windows Binaries for Python Extension Packages

笑着哭i 提交于 2019-12-23 10:09:55
问题 What is the naming convention used for the Python wheels at Christoph Gohlke's Unofficial Windows Binaries for Python Extension Packages? For example, for scipy here are two of names of wheels on the page: scipy-0.17.0-cp27-none-win32.whl scipy-0.17.0-cp27-none-win_amd64.whl What does 'none' indicate? What's the difference between win32 and win_amd64? Does it matter if I'm using the x86 or x86-64 version of Python (ref Python 2.7.11)? 回答1: Actually that's the wheel tool "naming convention".

Installing numpy from wheel format: “…is not a supported wheel on this platform”

▼魔方 西西 提交于 2019-12-23 09:55:45
问题 I realize a question that relates to this has already been asked at Cannot install numpy from wheel format , but the solution presented there does not work for me. I have asked on that thread too (by answering!) but I'm not getting any replies, so here goes: I have been trying to install matplotlib, but I first need to install numpy. I downloaded the file numpy-1.8.2+mkl-cp26-none-win_amd64.whl, then tried to install it using pip. The error message I keep getting is: "numpy-1.8.2+mkl-cp26

Distributing python packages to offline machines

久未见 提交于 2019-12-23 05:22:52
问题 Let's say that I have two machines. macOS 10.13 with internet connection macOS 10.12 with no network connection I want to install readline (for example) via a wheel. I can grab the wheel easily enough with: pip wheel -w . readline and what I get is: readline-6.2.4.1-cp36-cp36m-macosx_10_13_x86_64.whl however, when I take this wheel over the the 10.12 machine and try to install it with: pip install --no-index --find-links . readline it will not install because the filename is tagged with 10.13

Exclude single source file from python bdist_egg or bdist_wheel

时间秒杀一切 提交于 2019-12-22 10:07:24
问题 Background: I have one source file which is responsible for security. In there are magic keys and specific algorithms. Is it possible to remove a this single source file from a python egg or wheel package? I already accomplished to ship only binarys with the the egg command. python setup.py bdist_egg --exclude-source-files Edit Project structure: ├── setup.py ├── src | ├── __init__.py | ├── file1.py | ├── file2.py | ├── file_to_exclude.py Thanks for your help! 回答1: Unfortunately, neither

How to create a Pure-Python wheel

雨燕双飞 提交于 2019-12-19 06:52:05
问题 From the following setup.py file, I am trying to create a pure-python wheel from a project that should contain only python 2.7 code. from setuptools import setup setup( name='foo', version='0.0.1', description='', url='', install_requires=[ 'bpython', 'Django==1.8.2', ], ) However, when I run python setup.py bdist_wheel the wheel file that is generated is platform specific foo-0.0.1-cp27-none-macosx_10_9_x86_64.whl wheel file instead of the expected foo-0.0.1-cp27-none-any.whl . When I try to

'pip setup.py bdist_wheel' no longer builds forced non-pure wheels

谁说我不能喝 提交于 2019-12-19 06:28:09
问题 I have a project that compiles with C extensions on Linux, but without them on Windows. When I first generated the wheel files on Windows with python setup.py bdist_wheel , they became universal, and I could not upload them to PyPI as these universal wheels are preferred by pip for installation over the .tar.gz uploads (the result from python setup.py sdist ). The trick around this was to specify in the setup.py : Distribution.is_pure = lambda *args: False or by subclassing Distribution :

Error importing sklearn

丶灬走出姿态 提交于 2019-12-19 04:56:18
问题 Python version : 3.5.2 I getting started with machine learning and things... So I installed sklearn and some other packages form pip. All of them were able to be installed successfully except sklearn so, I downloaded the wheel and installed it from here. It was successfully installed but when i tried to import it in the order to check correct installation, I got tons of error : Traceback (most recent call last): File "C:\MyFiles\Programs\Python\PlayGround.py", line 1, in import sklearn File

Error importing sklearn

百般思念 提交于 2019-12-19 04:56:06
问题 Python version : 3.5.2 I getting started with machine learning and things... So I installed sklearn and some other packages form pip. All of them were able to be installed successfully except sklearn so, I downloaded the wheel and installed it from here. It was successfully installed but when i tried to import it in the order to check correct installation, I got tons of error : Traceback (most recent call last): File "C:\MyFiles\Programs\Python\PlayGround.py", line 1, in import sklearn File

Include run-time dependencies in Python wheels

天大地大妈咪最大 提交于 2019-12-18 14:54:13
问题 I'd like to distribute a whole virtualenv, or a bunch of Python wheels of exact versions with their runtime dependencies, for example: pycurl pycurl.so libcurl.so libz.so libssl.so libcrypto.so libgssapi_krb5.so libkrb5.so libresolv.so I suppose I could rely on the system to have libssl.so installed, but surely not libcurl.so of the correct version and probably not Kerberos. What is the easiest way to package one library in a wheel with all the run-time dependency? Or is that a fool's errand