Small helpers common in most Python applications for OpenTTD
Project description
openttd-helpers
A repository full of small bits of Python code, commonly used in other projects developed for OpenTTD.
To increase maintainability and to decrease code duplication, this repository was created.
Usage
pip install openttd-helpers
See examples/ folder for example use, or look into OpenTTD repositories containing Python code.
Modules
asyncio_helper
Helpers to make the user of ayncio easier.
- task:
enable_strong_referenced_tasks()makes returned tasks fromayncio.create_taskstrong, so they are not garbage collected unexpectedly.
click_helper
Helpers to make the use of click easier.
- command: by default, add
-hto the allowed parameters. - extend: allow extending a
click.command()in other functions. - import_module: used in combination with
Choice, to auto-load modules based on the choice.
logging_helper
Setup a default logger via a click.extend() function.
sentry_helper
Setup Sentry via a click.extend() function.
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file openttd-helpers-2.0.0.tar.gz.
File metadata
- Download URL: openttd-helpers-2.0.0.tar.gz
- Upload date:
- Size: 15.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
4ec741d3722d3fa68753f41f2481ca9ac58ece4d65c1da5f0753458bece30de7
|
|
| MD5 |
67e173ecf1e0390f3adea411206e5312
|
|
| BLAKE2b-256 |
ad56cb90bea31890d0656610cd08f8de15b1163f0c6066bdd4367484ae81d1e4
|
File details
Details for the file openttd_helpers-2.0.0-py3-none-any.whl.
File metadata
- Download URL: openttd_helpers-2.0.0-py3-none-any.whl
- Upload date:
- Size: 15.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9f3a159899c27b1d9e891ebdda46c87967930c112ef2a6213a560aa3247a01b8
|
|
| MD5 |
ba6ca004d8f1db9aff2a0d0fc65faa19
|
|
| BLAKE2b-256 |
3d6f3e86a60f3d5f9a8c72a8154e5a12456ea5387fcf02a1c690b3f23144b3d0
|