Skip to content

Commit 992e91a

Browse files
committed
fix: prevent ruff auto-format from rewriting version.py placeholders
uv-dynamic-versioning rewrites version.py on every `uv run`, so the ruff auto-format job was inadvertently committing dev version strings. Restore version.py files after formatting and revert the ones already changed on this branch.
1 parent 1e8e5d2 commit 992e91a

3 files changed

Lines changed: 4 additions & 2 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,6 +199,8 @@ jobs:
199199
run: |
200200
uv run ruff check --fix . || true
201201
uv run ruff format .
202+
# uv-dynamic-versioning rewrites version.py on every `uv run` — discard those changes
203+
git checkout HEAD -- codeflash/version.py codeflash-benchmark/codeflash_benchmark/version.py 2>/dev/null || true
202204
203205
- name: Commit and push fixes
204206
run: |
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# These version placeholders will be replaced by uv-dynamic-versioning during build.
2-
__version__ = "0.20.5.post187.dev0+a8c00416"
2+
__version__ = "0.20.5.post151.dev0+95b62113"

codeflash/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# These version placeholders will be replaced by uv-dynamic-versioning during build.
2-
__version__ = "0.20.5.post187.dev0+a8c00416"
2+
__version__ = "0.20.5.post151.dev0+95b62113"

0 commit comments

Comments
 (0)