A tiny module to read environment variables and tranform them.
Project description
envyronment
A tiny module to read environment variables and tranform them.
When load_dotenv is available, this is called at import time.
Features
- ✅ Simple, typed API
- ✅ Loads
.envif installed with extradotenv - ✅ Flexible casting via
astype=... - ✅ Propagates errors raised in the
astypecallable - ✅ Zero dependencies required,
python-dotenvoptionally installed
Requirements
- Python 3.10+ (only 3.13 is tested)
Quick start
-
Install the package
pip install envyronment
or
pip install envyronment[dotenv] # Ensure python-dotenv is also installed
-
Import and use
import envyronment as env ascii_asterisk = env.read("ASCII_ASTERISK", 42, astype=int) # typed as int, 42 by default debug = env.read("DEBUG", astype=bool) # typed as bool, required
License
This project is licensed under the MIT License — see the LICENSE file for details.
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 envyronment-0.2.0.tar.gz.
File metadata
- Download URL: envyronment-0.2.0.tar.gz
- Upload date:
- Size: 6.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ed0bafc790896f77a8ebe93cbb64fb6897923a67d1f424731040084e62bf4498
|
|
| MD5 |
ad5afad22754c88d0a79bdbfbe0b5653
|
|
| BLAKE2b-256 |
75e52408aa55621ca8b7cce8f7d3a474da62cfed49779ed426c3789bb5f4462d
|
Provenance
The following attestation bundles were made for envyronment-0.2.0.tar.gz:
Publisher:
release.yml on shifqu/envyronment
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
envyronment-0.2.0.tar.gz -
Subject digest:
ed0bafc790896f77a8ebe93cbb64fb6897923a67d1f424731040084e62bf4498 - Sigstore transparency entry: 699585148
- Sigstore integration time:
-
Permalink:
shifqu/envyronment@719c590b38b5658527013152cc047d5bc4d44c68 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/shifqu
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@719c590b38b5658527013152cc047d5bc4d44c68 -
Trigger Event:
push
-
Statement type:
File details
Details for the file envyronment-0.2.0-py3-none-any.whl.
File metadata
- Download URL: envyronment-0.2.0-py3-none-any.whl
- Upload date:
- Size: 3.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2997f392bc398808bdc5c5e111aad6e2522573bbe5d0c36fe55e6537ee95b1c8
|
|
| MD5 |
2e5ab421a2243da55156d96789cfecd7
|
|
| BLAKE2b-256 |
b8d6c7ab54014402764ebaaa858941f490e4007408c2ae243668f877e7b53536
|
Provenance
The following attestation bundles were made for envyronment-0.2.0-py3-none-any.whl:
Publisher:
release.yml on shifqu/envyronment
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
envyronment-0.2.0-py3-none-any.whl -
Subject digest:
2997f392bc398808bdc5c5e111aad6e2522573bbe5d0c36fe55e6537ee95b1c8 - Sigstore transparency entry: 699585152
- Sigstore integration time:
-
Permalink:
shifqu/envyronment@719c590b38b5658527013152cc047d5bc4d44c68 -
Branch / Tag:
refs/tags/v0.2.0 - Owner: https://github.com/shifqu
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@719c590b38b5658527013152cc047d5bc4d44c68 -
Trigger Event:
push
-
Statement type: