Skip to content

pgrun setup + pgrun bot verify (recovers #3, which merged into its stack base instead of main) - #5

Merged
alexshapalov merged 10 commits into
mainfrom
feat/create-capacity-retry
Nov 16, 2026
Merged

alexshapalov merged 10 commits into
mainfrom
feat/create-capacity-retry

Conversation

@alexshapalov

Copy link
Copy Markdown
Contributor

#3 was merged into feat/create-capacity-retry after #2 had already landed on main, so its changes never reached main. This PR brings them over unchanged:

  • pgrun setup / pgrun bot: PgBot as a standard component (checksum-verified install)
  • pgrun bot verify: explicit verdict categories, --block-on policy, a skipped review is incomplete, never pass; CI-token naming; the API token never reaches the migration
  • build with go1.27.4 (GO-2026-6859); CI workflow + .golangci.yml

Still pins pgbot 0.9.0 (PinnedVersion, @pgbot/cli ^0.9.0). The 0.10.0 pin (#4) stays on feat/pgbot-integration and gets its own PR once pgbot v0.10.0 is published. Merges cleanly into main.

Merge with Create a merge commit.

🤖 Generated with Claude Code

alexshapalov and others added 10 commits November 14, 2026 10:08
- internal/pgbot: locate (PGRUN_PGBOT > PATH > managed copy), version/capability
  probe in a scrubbed env, pinned checksum-verified install (atomic, no exec before
  the sha256 matches).
- pgrun bot status|install|inspect|lint|schema|explain|run: branch-scoped (URL from
  the API, env only), refuses connection strings, AI layer off unless --allow-ai.
- pgrun bot verify -- <migration>: disposable PostgreSQL branch of the Safe Copy,
  schema snapshot + lint before/after, pgbot schema diff (rewrites, blocking index
  builds, drops, renames), optional --compare-pgx; always cleans up; pgrun-verify/1.0.0.
- pgrun setup: idempotent skill + pgbot + auth report, --agents-md managed block
  only on request; pgrun-setup/1.0.0.
- MCP: pgrun_bot_lint / pgrun_bot_schema / pgrun_bot_explain.
- npm: @pgrun/cli depends on @pgbot/cli; the wrapper hands its binary over via PGRUN_PGBOT.
- Skill: PGX default, PgBot when/how, reading the verify report.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…hed once

A create response can say ready (an idempotent request_id replay, a synchronous provisioner) but
never carries connection_url; branch exec / bot verify then failed with 'ready but no
connection_url'. Found by the PGRun 2.0 end-to-end run on pgxbench.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…run setup)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… on purpose

Measured on pgxbench: pgbot inspect on every PGX branch reported fsync_off and
full_page_writes_off as critical. They are deliberate (branches are recreated, not recovered);
suppressed for pgrun bot inspect, with a note on stderr.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d review is incomplete, never pass

pgrun-verify 1.1.0 adds categories, blocking, policy and summary (fields added, none renamed).
Verdicts: fail > dangerous > unsupported > incomplete > error > warning > pass. --block-on
(default fail,dangerous,incomplete,error) decides blocking; exit 0/1, and 3 when only
infrastructure errors block. Before this, a pgbot without the schema command, a failed lint
or an unrun PGX comparison still produced verdict pass and exit 0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… token out of the migration

A CI token may only create ci-… branches (422 token_scope): verify retries once as
ci-verify-…. The migration child no longer inherits PGRUN_API_TOKEN or an outer
DATABASE_URL. Both found by the ci-action integration.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…branches

Found by the real-API e2e: pgbot keeps suppressed findings in its JSON (suppressed: true).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…golangci-lint, govulncheck

pgrun-cli had no CI. Pinned action SHAs and tool versions (as pgbot). .golangci.yml keeps the
default linters and lists the accepted CLI patterns (terminal writes, best-effort cleanup; test
fixture writes) instead of changing code; 0 issues on this branch.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pgrun setup + pgrun bot verify: PgBot as a standard component, explicit verdicts
@alexshapalov
alexshapalov merged commit beac333 into main Nov 16, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant