From a35ca3431985283574158a725e6b9faefad52886 Mon Sep 17 00:00:00 2001 From: Ramazan Elsunkaev Date: Mon, 13 Jul 2026 12:50:53 -0700 Subject: [PATCH] fix(release): classify beta GitHub releases --- .beads/issues.jsonl | 1 + .github/workflows/publish.yml | 13 +++++++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.beads/issues.jsonl b/.beads/issues.jsonl index 77246e63..1b4a8280 100644 --- a/.beads/issues.jsonl +++ b/.beads/issues.jsonl @@ -1,5 +1,6 @@ {"id":"effect-qb-dn3.1","title":"P0 migrate Effect dependencies and schema API surface","description":"Smallest coherent implementation slice. Align workspace/package dependencies to effect@4.0.0-beta.66 and matching v4 packages, remove @effect/experimental where replaced, and perform the mechanical Schema API migration called out in docs/effect-v4-opportunities.md without intentional behavior changes.","acceptance_criteria":"Effect package versions are aligned to the observed v4 beta line; v3 Schema call shapes listed in the opportunity doc are migrated; README/type-test examples are updated as needed; behavior tests covering risky runtime schema/json paths still pass; bun run test:types, bun test, and relevant tsgo checks are run or blockers documented.","notes":"Status: in_progress. Starting with repo inspection and focused regression/type coverage around current Schema API and JSON path inference before the mechanical v4 dependency/API migration.\nBaseline before migration: focused Bun behavior tests passed for runtime-value/json/table/executor; tsgo type-test project passed. Commands: bun --config ./bunfig.test.toml test test/internal/behavior/runtime-value.behavior.test.ts test/public/behavior/json.behavior.test.ts test/internal/behavior/table.test.ts test/public/behavior/executor.behavior.test.ts; bunx tsgo -p tsconfig.type-tests.json.\nImplemented and verified in the first migration slice. Dependencies aligned to effect@4.0.0-beta.66 and matching v4 driver/platform packages; removed @effect/experimental, @effect/sql, @effect/cli, and @effect/platform where v4 unstable exports replaced them; migrated mechanical Schema API changes and README/type examples. Checks passed: bunx tsgo -p tsconfig.type-tests.json; bun --config ./bunfig.test.toml test test/internal/behavior/runtime-value.behavior.test.ts test/public/behavior/json.behavior.test.ts test/internal/behavior/table.test.ts test/public/behavior/executor.behavior.test.ts test/public/behavior/mysql-errors.behavior.test.ts test/public/behavior/postgres-errors.behavior.test.ts; bun run test:types; bun run build; bun run test:pack; bun run test.","status":"closed","priority":0,"issue_type":"task","owner":"relsunkaev@outlook.com","created_at":"2026-05-13T02:18:18Z","created_by":"Ramazan Elsunkaev","updated_at":"2026-05-13T02:41:33Z","started_at":"2026-05-13T02:20:14Z","closed_at":"2026-05-13T02:41:33Z","close_reason":"P0 dependency and mechanical Schema API migration implemented; full type, build, pack, focused behavior, and full Bun tests passed.","labels":["effect-v4","migration","schema"],"dependencies":[{"issue_id":"effect-qb-dn3.1","depends_on_id":"effect-qb-dn3","type":"parent-child","created_at":"2026-05-12T19:18:18Z","created_by":"Ramazan Elsunkaev","metadata":"{}"}],"dependency_count":0,"dependent_count":6,"comment_count":0} {"id":"effect-qb-dn3","title":"Effect v4 migration epic","description":"Parent epic for the Effect v4 migration work described in docs/effect-v4-opportunities.md. Scope includes dependency alignment, mechanical Schema API migration, VariantSchema replacement, v4 SQL core adoption, SqlSchema validation, optional v4 codecs, row decode error improvements, JSON schema inference review, and CLI/platform packaging.","acceptance_criteria":"All child beads map to docs/effect-v4-opportunities.md opportunities; every opportunity is implemented, explicitly deferred, or blocked with a concrete reason; relevant tests/type checks/lint checks pass; coherent increments are committed.","notes":"Source of truth: docs/effect-v4-opportunities.md checked against effect@4.0.0-beta.66. Assumption: this branch is the v4 line, so no Effect 3 compatibility shim is required unless a child bead discovers a concrete compatibility requirement.","status":"open","priority":0,"issue_type":"epic","owner":"relsunkaev@outlook.com","created_at":"2026-05-13T02:18:02Z","created_by":"Ramazan Elsunkaev","updated_at":"2026-05-13T02:18:02Z","labels":["effect-v4","migration"],"dependency_count":0,"dependent_count":0,"comment_count":0} +{"id":"effect-qb-vt7","title":"Classify beta GitHub releases as prereleases","description":"The publish workflow maps prerelease versions to the npm beta dist-tag but unconditionally creates a normal GitHub release, causing beta versions to become Latest. Derive GitHub release classification from the same npm-tag decision and correct v4.0.0-beta.98 metadata.","acceptance_criteria":"Publish workflow passes prerelease=true and latest=false for hyphenated versions, stable versions remain latest releases, actionlint passes, and v4.0.0-beta.98 is shown as a GitHub prerelease rather than Latest.","status":"closed","priority":1,"issue_type":"bug","assignee":"Ramazan Elsunkaev","owner":"relsunkaev@outlook.com","created_at":"2026-07-13T19:47:12Z","created_by":"Ramazan Elsunkaev","updated_at":"2026-07-13T19:50:37Z","started_at":"2026-07-13T19:47:17Z","closed_at":"2026-07-13T19:50:37Z","close_reason":"Publish workflow now classifies npm beta releases as GitHub prereleases and explicitly clears the make_latest pointer; actionlint passes; beta.92 and beta.98 metadata verified as prerelease with v0.17.0 restored as latest.","dependency_count":0,"dependent_count":0,"comment_count":0} {"id":"effect-qb-lbx","title":"Release v4.0.0-beta.98","description":"Upgrade the Effect v4 dependency stack from beta.92 to beta.98, cut matching effect-qb and effect-db beta.98 packages, publish through the repository release workflows, and verify npm plus GitHub release state.","acceptance_criteria":"All Effect packages and peer dependencies resolve to 4.0.0-beta.98; build, unit, type, pack, and integration gates pass; v4.0.0-beta.98 is tagged and published for effect-qb/effect-db under the beta dist-tag; the GitHub release and publish workflow succeed.","status":"closed","priority":1,"issue_type":"task","assignee":"Ramazan Elsunkaev","owner":"relsunkaev@outlook.com","created_at":"2026-07-13T19:35:31Z","created_by":"Ramazan Elsunkaev","updated_at":"2026-07-13T19:45:11Z","started_at":"2026-07-13T19:36:09Z","closed_at":"2026-07-13T19:45:11Z","close_reason":"Published effect-qb and effect-db 4.0.0-beta.98 via tag v4.0.0-beta.98; PR #6 and publish run 29279588367 succeeded; npm beta tags and signed provenance verified.","dependency_count":0,"dependent_count":0,"comment_count":0} {"id":"effect-qb-bpa","title":"Release v4.0.0-beta.92","description":"Cut the requested v4.0.0-beta.92 release from main, including version bump, changelog, tag, publish workflow, and verification of npm/GitHub release state.","notes":"Release prep is complete at v4.0.0-beta.92. Release commit 46adff1 and tag v4.0.0-beta.92 were pushed to main. Local gates passed: bun run build; bun run test; bun run test:types; bun run test:pack; bunx npm pack --dry-run; bun run test:integration; bun run test:integration:datatypes. Plain 'bun test' still fails through known broad-runner/stale-test issue effect-qb-lnu and was not used as release proof. Publish workflow run 28472253061 failed at Publish querybuilder to npm with 404 Not Found for https://registry.npmjs.org/effect-qb; effect-qb@4.0.0-beta.92 and effect-db@4.0.0-beta.92 are not visible on npm, and the GitHub release was skipped.","status":"closed","priority":1,"issue_type":"task","assignee":"Ramazan Elsunkaev","owner":"relsunkaev@outlook.com","created_at":"2026-06-30T19:57:50Z","created_by":"Ramazan Elsunkaev","updated_at":"2026-07-13T18:44:26Z","started_at":"2026-06-30T19:58:19Z","closed_at":"2026-07-13T18:44:26Z","close_reason":"v4.0.0-beta.92 is published on npm for both packages, beta dist-tags point to beta.92, GitHub release exists, and repaired Publish runs 29275561438 and 29275567580 passed.","dependency_count":0,"dependent_count":0,"comment_count":0} {"id":"effect-qb-v0m","title":"Update Effect beta dependencies to beta.92","description":"Update the Effect v4 dependency stack from 4.0.0-beta.66 to 4.0.0-beta.92, ensure published packages expose effect as a peer dependency at the new beta, and verify local gates.","status":"closed","priority":1,"issue_type":"task","assignee":"Ramazan Elsunkaev","owner":"relsunkaev@outlook.com","created_at":"2026-06-30T19:33:31Z","created_by":"Ramazan Elsunkaev","updated_at":"2026-06-30T19:39:13Z","started_at":"2026-06-30T19:34:08Z","closed_at":"2026-06-30T19:39:13Z","close_reason":"Updated Effect packages and peer dependencies to 4.0.0-beta.92; verified build, type tests, unit tests, pack smoke, integration, and datatype matrix.","dependency_count":0,"dependent_count":0,"comment_count":0} diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 3607968c..45983ddb 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -121,8 +121,17 @@ jobs: GH_TOKEN: ${{ github.token }} run: | TAG="${{ steps.tag.outputs.tag }}" + if [[ "${{ steps.npm-tag.outputs.tag }}" == "latest" ]]; then + RELEASE_KIND=(--prerelease=false --latest) + else + RELEASE_KIND=(--prerelease) + fi if gh release view "$TAG" >/dev/null 2>&1; then - gh release edit "$TAG" --notes-file "${{ steps.notes.outputs.notes }}" --title "$TAG" + gh release edit "$TAG" "${RELEASE_KIND[@]}" --notes-file "${{ steps.notes.outputs.notes }}" --title "$TAG" else - gh release create "$TAG" --verify-tag --notes-file "${{ steps.notes.outputs.notes }}" --title "$TAG" + gh release create "$TAG" "${RELEASE_KIND[@]}" --verify-tag --notes-file "${{ steps.notes.outputs.notes }}" --title "$TAG" + fi + if [[ "${{ steps.npm-tag.outputs.tag }}" != "latest" ]]; then + RELEASE_ID="$(gh api "repos/$GITHUB_REPOSITORY/releases/tags/$TAG" --jq .id)" + gh api --method PATCH "repos/$GITHUB_REPOSITORY/releases/$RELEASE_ID" -f make_latest=false >/dev/null fi