Questions tagged [python-wheel]

​​​​​​​​​​​​​​​​​​​​A wheel is a ZIP-like archive format for Python packages with the .whl extension.

Wheels were introduced to Python with PEP 427 to simplify distribution installation. It replaces the egg format.

Useful Links:

  1. PEP 376 Database of Installed Python Distributions infrastructure Wheels are based on
  2. PEP 427 Introduction of the Wheel format
  3. Wheel package index
883 questions
12
votes
1 answer

Python equivalent of uber-jar

I'm looking for the equivalent of an uber-jar in the python world. I need to distribute a python package to all three major platforms (Windows, Mac, Linux). It must be bundled with all its dependencies, as the target platform may lack internet. It…
Michael Gummelt
  • 702
  • 4
  • 15
11
votes
3 answers

ERROR:Failed building wheel for h5pyFailed to build h5pyERROR:Could not build wheels for h5py,which is required toinstall pyproject.toml-basedprojects

I'm getting this error when I'm running the following command to install tensorflow. python3 -m pip install tensorflow-macos ERROR: Failed building wheel for h5py Failed to build h5py ERROR: Could not build wheels for h5py, which is required to…
Lakshay Rohilla
  • 1,654
  • 6
  • 9
  • 30
11
votes
1 answer

Why can't I exclude `tests` directory from my python wheel using `exclude`?

Consider the following package structure: With the following setup.py contents: from setuptools import setup, find_packages setup( name='dfl_client', packages=find_packages(exclude=['*tests*']), include_package_data=True, …
smarie
  • 4,568
  • 24
  • 39
11
votes
0 answers

Packaging with manylinux + auditwheel pip wheels vs. Conda

Description So I am looking to package a fairly complex python application that requires scientific libraries. This question is somewhat similar to the stackoverflow pip vs conda discussion but it does not go into detail about the differences now…
costrouc
  • 3,045
  • 2
  • 19
  • 23
11
votes
1 answer

Pip install Killed

Every time when I try to install some package, I get: (ecz) root@zakazatdostavku:/opt# pip install django gunicorn Collecting django Downloading Django-1.11-py2.py3-none-any.whl (6.9MB) 99% |████████████████████████████████| 6.9MB 11.6MB/s eta…
Mr.Freeman
  • 563
  • 1
  • 6
  • 15
11
votes
3 answers

Troubles while installing psutil (wheel) as a dependency via pip

I wrote a package with a dependency's dependency to psutil (my-package depends on third-party-package which depends on psutil). Since it's supposed to run on a server without any connectivity and without gcc, I prepared the deployment locally with a…
Anto
  • 6,806
  • 8
  • 43
  • 65
11
votes
2 answers

I try to build a universal wheel, but it rolls away

I run: python3 setup.py bdist_wheel --universal It says it's making all sorts of stuff, but then the resulting directory (build/bdist.macosx-10.10-x86_64) is empty. Where did my wheel roll away to?t Edit I now see that I'm trying to look at the…
bmargulies
  • 97,814
  • 39
  • 186
  • 310
11
votes
3 answers

How to create a Pure-Python wheel

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='', …
seadugo
  • 139
  • 1
  • 1
  • 7
11
votes
1 answer

How do I upload a Universal Python Wheel for Python 2 and 3?

I have a package on PyPi and when preparing a new release I build the source distribution, build the wheel and upload, all with setuptools. However, I've found it only uploads the wheel for the Python version used in the upload command (python and…
ben_nuttall
  • 859
  • 10
  • 20
10
votes
1 answer

Difference between a Python 'egg' and 'wheel'

I was installing pandas on my machine and came across this error: Running setup.py (path:/tmp/pip-build-WzvvgM/pandas/setup.py) egg_info for package pandas Cleaning up... Command python setup.py egg_info failed with error code 1 in…
Sachin Yadav
  • 748
  • 9
  • 28
10
votes
1 answer

include only *.pyc files in python wheel

How can I include only *.pyc files in a python wheel? When creating eggs, it used to be possible to run python setup.py bdist_egg --exclude-source-files Given that eggs have been replaced by wheels, how would I reproduce a similar result?
Zuabi
  • 1,112
  • 1
  • 13
  • 26
10
votes
2 answers

Build a universal wheel from setup.py

How do I build a universal wheel from setup.py? I would prefer not to pass in the --universal option each time or to create a setup.cfg file just for this option. I am aware of the workaround in https://stackoverflow.com/a/35112241/6947337, but is…
rlee827
  • 1,853
  • 2
  • 13
  • 32
10
votes
1 answer

Python: run tests from wheel or sdist

For a package I've authored, I've done python setup.py sdist bdist_wheel, which generates some package artifacts in the dist/ directory. Now I'd like to run the package's unit tests in those artifacts. What's a good way to do it? To be clear: an…
Ken Williams
  • 22,756
  • 10
  • 85
  • 147
10
votes
1 answer

How to use gitlab-ci to manage test/construction of interdependent wheels

I have 3 python packages proj1, proj12 and proj13. Both proj12 and proj13 depend on proj1 (with from proj1.xxx import yyy). The 3 projects are on a private gitlab instance, each one has it's own .gitlab-ci. In proj1…
user3313834
  • 7,327
  • 12
  • 56
  • 99
10
votes
3 answers

Exclude manylinux wheels when downloading from pip

At $company we run an internal pypi server to shield ourselves from public pypi downtime. We also build wheels to avoid installation overhead for binary packages. One common task is to import packages from public pypi which essentially boils down…
anthony sottile
  • 61,815
  • 15
  • 148
  • 207