fix: __version__ hardcoded to 0.1.0, drifted from pyproject 0.1.1

__init__.py:14 hardcoded "0.1.0" while pyproject.toml, the README
install pin, and the README changelog all said 0.1.1 - a consumer
gating on __version__ read one release behind the actual tag. Derive
__version__ from installed package metadata
(importlib.metadata.version("dpy_cache")) so the hardcoded literal
can no longer drift from the release tag; keep a fallback literal for
the not-installed/editable case, synced to the current pyproject
version.

Bump 0.1.1 -> 0.1.2.

Signed-off-by: disqualifier <dev@disqualifier.me>
This commit is contained in:
2026-07-03 16:15:48 -04:00
parent 248d6ebb6b
commit 5885839f06
3 changed files with 16 additions and 3 deletions
+9 -1
View File
@@ -9,7 +9,7 @@ bites you.
## Install
```
dpy_cache @ git+ssh://git@git.rethinkstudios.io/rethink-public/dpy_cache.git@v0.1.1
dpy_cache @ git+ssh://git@git.rethinkstudios.io/rethink-public/dpy_cache.git@v0.1.2
```
## Usage
@@ -103,6 +103,14 @@ one, a `discord.File` source that can't be safely rebuilt for a repeat send). Un
Tagged `vX.Y.Z`; pin a tag in your install line. Targets `discord.py>=2.0` (not
`discord.py-self`).
### v0.1.2
- `__version__` is now derived from installed package metadata
(`importlib.metadata.version("dpy_cache")`) instead of a hardcoded string, so it can
no longer drift from the `pyproject.toml` version that the release tag is cut from. A
not-installed/editable checkout falls back to a literal that is kept in sync with the
current `pyproject.toml` version at each release.
### v0.1.1
- `cache()` now rejects a duplicate filename in a **list** input with `DPYCacheError`