Skip to main content

My short description

Project description

Python sample package with data

How to distribute a Python package with data.

https://stackoverflow.com/questions/3596979/manifest-in-ignored-on-python-setup-py-install-no-data-files-installed/60735402#60735402

Tested on Ubuntu 19.10, Python 3.7.5, wheel==0.32.3, setuptools==41.1.0, twine==3.1.1.

How end users use the package from https://pypi.org/project/python-sample-package-with-data/:

python3 -m pip install --user python-sample-package-with-data
python-sample-package-with-data

Expected output:

hello data

which are the contents of our test data file python_sample_package_with_data/mydata.txt that was distributed with pip.

How maintainers publish it:

# One time setup.
python3 -m pip install --user setuptools wheel twine

# Every time you want to publish.
python setup.py sdist bdist_wheel
twine upload dist/*
rm -rf build dist *.egg-info

Bibliography:

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Built Distribution

File details

Details for the file python-sample-package-with-data-aitirga-0.0.3.tar.gz.

File metadata

  • Download URL: python-sample-package-with-data-aitirga-0.0.3.tar.gz
  • Upload date:
  • Size: 1.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.63.0 CPython/3.8.12

File hashes

Hashes for python-sample-package-with-data-aitirga-0.0.3.tar.gz
Algorithm Hash digest
SHA256 a18945e002dfe8438e912cdeea61ce76323f5802201fc3c3e50d8dd35c15ad8a
MD5 710663f459e967437ac446b3b6e76fea
BLAKE2b-256 a7f5a1675084837d7ca3400f7a2c72b1767b24a7ce5d9c5912c780d92bd58794

See more details on using hashes here.

File details

Details for the file python_sample_package_with_data_aitirga-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for python_sample_package_with_data_aitirga-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 76cfecec23664e1eaf3ceb53bd40af7b3ecf64fe6c2a8bfd9eb6b0f955f256de
MD5 69165768bf9d5315012dff5f0da2c1a5
BLAKE2b-256 708f48fb0df95fddfd18273bf8ba9ed5c7f62521c48c0fc3566005cffaa21c9b

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page