From 9319f4541313589b9531bc53260a254341acf28d Mon Sep 17 00:00:00 2001 From: Toni Nowak Date: Fri, 17 Jul 2026 23:03:35 +0200 Subject: [PATCH] fix(ci): sync npm package versions to release tag + unmask publish failures (2.12.1) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Releases 2.11.0/2.12.0 never reached npm: the pipeline bumps pyproject/__init__ but never the npm manifests, so publish re-tried surrealmemory@2.10.5 and the registry E403 ("cannot publish over previously published") was masked by an `|| echo ::warning` fallback — the job stayed green while nothing shipped. - publish-npm / publish-sdk / publish-vscode now `npm version "${GITHUB_REF_NAME#v}" --no-git-tag-version` after install, before build, so the published version always matches the tag - publish failures fail the job loudly (no more warning masks); graceful skip only for a missing token or an idempotent re-run (exact version already live) - bump 2.12.1 across pyproject, __init__, and the three npm manifests (+locks); npm intentionally skips 2.11.0/2.12.0 and jumps 2.10.5 -> 2.12.1 --- .github/workflows/release.yml | 37 ++++++++++++++----- CHANGELOG.md | 28 ++++++++++++++ .../surreal-memory-client/package-lock.json | 4 +- .../surreal-memory-client/package.json | 2 +- integrations/surrealmemory/package-lock.json | 4 +- integrations/surrealmemory/package.json | 2 +- pyproject.toml | 2 +- src/surreal_memory/__init__.py | 2 +- tests/unit/test_health_fixes.py | 2 +- vscode-extension/package-lock.json | 4 +- vscode-extension/package.json | 2 +- 11 files changed, 68 insertions(+), 21 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ef91488f..235bef15 100755 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -188,10 +188,19 @@ jobs: echo "::notice::NPM_TOKEN not set — skipping npm publish." exit 0 fi + VERSION="${GITHUB_REF_NAME#v}" + # Idempotent re-run guard: skip ONLY if this exact version is already live. + if [ "$(npm view "surrealmemory@$VERSION" version 2>/dev/null)" = "$VERSION" ]; then + echo "::notice::surrealmemory@$VERSION already on npm — nothing to do." + exit 0 + fi npm ci || npm install + # Sync the package version to the release tag (package.json drift was the + # root cause of releases 2.11.0/2.12.0 silently re-publishing 2.10.5). + npm version "$VERSION" --no-git-tag-version --allow-same-version npm run build - npm publish --access public \ - || echo "::warning::npm publish failed (already published or name/permissions) — skipping" + # No fallback mask: a real publish failure must fail the job loudly. + npm publish --access public # ── Publish TypeScript SDK ───────────────────────────────────── publish-sdk: @@ -216,11 +225,19 @@ jobs: echo "::notice::NPM_TOKEN not set — skipping SDK publish." exit 0 fi + VERSION="${GITHUB_REF_NAME#v}" + # Idempotent re-run guard: skip ONLY if this exact version is already live. + if [ "$(npm view "@acidkill/surreal-memory-client@$VERSION" version 2>/dev/null)" = "$VERSION" ]; then + echo "::notice::@acidkill/surreal-memory-client@$VERSION already on npm — nothing to do." + exit 0 + fi npm ci || npm install + # Sync the package version to the release tag (same drift class as publish-npm). + npm version "$VERSION" --no-git-tag-version --allow-same-version npm run typecheck npm run build - npm publish --access public \ - || echo "::warning::SDK publish failed (already published or name/permissions) — skipping" + # No fallback mask: a real publish failure must fail the job loudly. + npm publish --access public # ── Publish to ClawHub ───────────────────────────────────────── publish-clawhub: @@ -267,20 +284,22 @@ jobs: OVSX_PAT: ${{ secrets.OVSX_PAT }} run: | npm ci || npm install + # Sync the extension version to the release tag (same drift class as publish-npm). + VERSION="${GITHUB_REF_NAME#v}" + npm version "$VERSION" --no-git-tag-version --allow-same-version npm run compile 2>/dev/null || npm run build 2>/dev/null || true - # VS Code Marketplace + # VS Code Marketplace — no fallback mask: with a PAT set, a publish + # failure must fail the job loudly instead of reporting green. if [ -n "$VSCE_PAT" ]; then - npx @vscode/vsce publish --pat "$VSCE_PAT" \ - || echo "::warning::VS Code Marketplace publish failed" + npx @vscode/vsce publish --pat "$VSCE_PAT" else echo "::warning::VSCE_PAT not set — skipping VS Code Marketplace" fi # Open VSX Registry if [ -n "$OVSX_PAT" ]; then - npx ovsx publish --pat "$OVSX_PAT" \ - || echo "::warning::Open VSX publish failed" + npx ovsx publish --pat "$OVSX_PAT" else echo "::warning::OVSX_PAT not set — skipping Open VSX" fi diff --git a/CHANGELOG.md b/CHANGELOG.md index 9c678f5e..f862fe8b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,34 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] +## [2.12.1] — Release pipeline: npm packages actually ship again + +Patch release. No runtime changes — it exists to fix the release pipeline and +re-align every published package on one version. npm packages had been silently +stuck at 2.10.5: versions 2.11.0 and 2.12.0 were never published to npm (the +registry rejected the re-upload of 2.10.5 with E403 and the workflow masked the +failure as a warning). Those npm versions are intentionally skipped — npm jumps +2.10.5 → 2.12.1. + +### Fixed + +- **Release workflow syncs npm package versions to the tag** — `publish-npm` + (`surrealmemory`), `publish-sdk` (`@acidkill/surreal-memory-client`) and + `publish-vscode` now run `npm version --no-git-tag-version` before + building, so a release can never re-publish a stale `package.json` version + again (the root cause: the pipeline bumped `pyproject.toml`/`__init__.py` + but never the npm manifests). +- **Publish failures are no longer masked** — the `|| echo "::warning::…"` + fallbacks are gone; with a token set, a failed `npm publish`/`vsce publish` + now fails the job loudly. A graceful skip remains only for a missing token + and for an idempotent re-run (this exact version already live). + +### Changed + +- `integrations/surrealmemory`, `integrations/surreal-memory-client` and + `vscode-extension` manifests bumped to 2.12.1 so the repo matches the + published artifacts. + ## [2.12.0] — Reasoning training: learn how models think An opt-in pipeline that mines a model's `thinking` blocks from `~/.claude` diff --git a/integrations/surreal-memory-client/package-lock.json b/integrations/surreal-memory-client/package-lock.json index 604659aa..23099f9c 100644 --- a/integrations/surreal-memory-client/package-lock.json +++ b/integrations/surreal-memory-client/package-lock.json @@ -1,12 +1,12 @@ { "name": "@acidkill/surreal-memory-client", - "version": "2.10.0", + "version": "2.12.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@acidkill/surreal-memory-client", - "version": "2.10.0", + "version": "2.12.1", "license": "MIT", "devDependencies": { "@types/node": "^20.0.0", diff --git a/integrations/surreal-memory-client/package.json b/integrations/surreal-memory-client/package.json index a1a606dd..0915e61f 100644 --- a/integrations/surreal-memory-client/package.json +++ b/integrations/surreal-memory-client/package.json @@ -1,6 +1,6 @@ { "name": "@acidkill/surreal-memory-client", - "version": "2.10.5", + "version": "2.12.1", "description": "TypeScript client for the Surreal-Memory REST API — typed access to brains, neurons, synapses, fibers, recall, and sync.", "type": "module", "main": "dist/index.cjs", diff --git a/integrations/surrealmemory/package-lock.json b/integrations/surrealmemory/package-lock.json index edd9aecd..1fd32567 100755 --- a/integrations/surrealmemory/package-lock.json +++ b/integrations/surrealmemory/package-lock.json @@ -1,12 +1,12 @@ { "name": "@surrealmemory/openclaw-plugin", - "version": "2.10.0", + "version": "2.12.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@surrealmemory/openclaw-plugin", - "version": "2.10.0", + "version": "2.12.1", "license": "MIT", "devDependencies": { "@types/node": "^25.2.2", diff --git a/integrations/surrealmemory/package.json b/integrations/surrealmemory/package.json index c2166297..60d11f5c 100755 --- a/integrations/surrealmemory/package.json +++ b/integrations/surrealmemory/package.json @@ -1,6 +1,6 @@ { "name": "surrealmemory", - "version": "2.10.5", + "version": "2.12.1", "description": "Surreal-Memory plugin for OpenClaw — graph-based persistent memory for AI agents with SurrealDB backend", "type": "module", "main": "dist/index.js", diff --git a/pyproject.toml b/pyproject.toml index 54ecb99a..312d94cb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "hatchling.build" [project] name = "surreal-memory" -version = "2.12.0" +version = "2.12.1" description = "Reflex-based memory system for AI agents with SurrealDB backend — retrieval through activation, not search" readme = "README.md" license = "MIT" diff --git a/src/surreal_memory/__init__.py b/src/surreal_memory/__init__.py index 52188bb0..d3df53f2 100755 --- a/src/surreal_memory/__init__.py +++ b/src/surreal_memory/__init__.py @@ -16,7 +16,7 @@ from surreal_memory.engine.reflex_activation import CoActivation, ReflexActivation from surreal_memory.engine.retrieval import DepthLevel, ReflexPipeline, RetrievalResult -__version__ = "2.12.0" +__version__ = "2.12.1" __all__ = [ "__version__", diff --git a/tests/unit/test_health_fixes.py b/tests/unit/test_health_fixes.py index 398d95ec..f6a4bd82 100755 --- a/tests/unit/test_health_fixes.py +++ b/tests/unit/test_health_fixes.py @@ -485,7 +485,7 @@ class TestVersionBump: def test_version_is_current(self) -> None: import surreal_memory - assert surreal_memory.__version__ == "2.12.0" + assert surreal_memory.__version__ == "2.12.1" class TestPackageIntegrity: diff --git a/vscode-extension/package-lock.json b/vscode-extension/package-lock.json index c270e9ea..5c82d7e1 100755 --- a/vscode-extension/package-lock.json +++ b/vscode-extension/package-lock.json @@ -1,12 +1,12 @@ { "name": "surrealmemory", - "version": "2.10.0", + "version": "2.12.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "surrealmemory", - "version": "2.10.0", + "version": "2.12.1", "license": "MIT", "dependencies": { "cytoscape": "^3.33.1", diff --git a/vscode-extension/package.json b/vscode-extension/package.json index 7b39a0ce..bcbf30c2 100755 --- a/vscode-extension/package.json +++ b/vscode-extension/package.json @@ -2,7 +2,7 @@ "name": "surrealmemory", "displayName": "Surreal-Memory", "description": "Visual brain explorer, inline recall, and memory management for Surreal-Memory", - "version": "2.10.5", + "version": "2.12.1", "publisher": "ai-flow-nowak", "license": "MIT", "preview": true,