Skip to main content

An example project demonstrating various ways to access data files in Python package

Project description

This project shows how to package data files within a Python distribution, and example code for reading the data files.

To build this distribution, create a venv with setuptools, wheel, and pep517 installed, then execute the latter as a module:

python -m pep517.build .

The distributions (an sdist .tar.gz and a bdist .whl) will be written to ./dist/ subdirectory.

To test it out, install a distribution and run the console script resources-example.

Accessing resources should work on both Python 2 and Python 3, Linux, macOS, Windows.. and all methods except for example1.py should still work when the package myapp has been

Project details


Release history Release notifications

This version

0.1

Download files

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

Files for resources-example, version 0.1
Filename, size File type Python version Upload date Hashes
Filename, size resources_example-0.1-py2.py3-none-any.whl (5.1 kB) File type Wheel Python version py2.py3 Upload date Hashes View
Filename, size resources-example-0.1.tar.gz (3.1 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page