Skip to content

Commit 9358dc5

Browse files
committed
fix: _save_version regex must include -lpb in version pattern
- Pattern was ^0\.0\.\d+(-dev)?$ which missed -lpb suffix - Correct: ^0\.0\.\d+-lpb(-dev)?$ - This ensures 0.0.12-lpb-dev is correctly persisted and resolved - Fixes "dev" tag resolving to 0.0.0-lpb-dev instead of actual version
1 parent a3bd7d0 commit 9358dc5

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

4 Bytes
Binary file not shown.

scripts/lpb.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,8 @@ def _load_last_version() -> str:
152152

153153
def _save_version(version: str) -> None:
154154
"""Persist the version tag for reconnection/update (only valid versioned tags)."""
155-
# Only persist tags that match the version pattern (0.0.x[-dev]), not legacy :cli/:web
156-
if not re.match(r'^0\.0\.\d+(-dev)?$', version):
155+
# Only persist tags that match the version pattern (0.0.x-lpb[-dev]), not legacy :cli/:web
156+
if not re.match(r'^0\.0\.\d+-lpb(-dev)?$', version):
157157
return
158158
LAST_VERSION_FILE.parent.mkdir(parents=True, exist_ok=True)
159159
with open(LAST_VERSION_FILE, "w") as f:

0 commit comments

Comments
 (0)