From 66a64656fbd759dd597885add8d7ae25cd9e8146 Mon Sep 17 00:00:00 2001 From: AppSolves Date: Mon, 16 Nov 2026 03:32:19 +0100 Subject: [PATCH] chore: prepare 0.1.1 release and close merge gate for cutover --- CHANGELOG.md | 10 ++++++---- package-lock.json | 4 ++-- package.json | 2 +- src/runner/engine.ts | 2 +- src/runner/proxy.ts | 2 +- src/worker/github.ts | 2 +- src/worker/index.ts | 2 +- tests/backend.test.ts | 2 +- wrangler.jsonc | 2 +- 9 files changed, 15 insertions(+), 13 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 8bb3b1a..756e930 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,13 +1,15 @@ # Security and behavior changes -## Unreleased — Responses output schema compatibility +## 0.1.1 — review execution and bounded orchestration + +### Responses output schema compatibility - Project group/continuation/synthesis output schemas onto the documented Responses subset. Keep `uniqueItems` and string-length constraints in unchanged strict host validation, rather than sending them to the provider. - Check every group schema and the actual pinned Codex wire schema against the same contract; duplicate reasons remain invalid locally. Retain only exact `invalid_json_schema` / `text.format.schema` diagnostics from bounded error envelopes. - Track successful tool inspection across the execution instead of demanding a redundant command in every later group/synthesis turn. Every group's input is still independently hash-verified/provided, an execution with no inspection is still rejected, and incomplete group/context/synthesis checks still deny approval. - Restore the first verified native image inputs after Codex compaction drops all image history. Retain their labels, fingerprints and original request/byte limits; partial replacement or substitution remains denied. Native acceptance forces real pinned-Codex compaction across a 93-file/four-distinct-image review. -## Unreleased — bounded review orchestration +### Bounded review orchestration - Harden required visual-input retention against duplicate/substituted images; native multi-turn acceptance now uses four distinct PNGs across groups, continuation and synthesis. - Integrate final whole-PR checks for one-group reviews without raising budgets. Add bounded host-generated coverage/reason status to incomplete COMMENT reports and recheck output size after adding metadata. @@ -16,13 +18,13 @@ - Build immutable host-owned evidence groups, run bounded same-thread continuation and mandatory cross-group synthesis, and independently validate coverage before accepting completeness. All groups share the existing proxy, request/time limits and context lookup budget. - Preserve primary analysis failures when the workflow reports failure. Add deterministic and real pinned Codex/Docker coverage for large PRs, images, continuation, synthesis, evidence integrity and global budget exhaustion. -## Unreleased — final context completion +### Final context completion - Add metadata-only optional existence probes without weakening mandatory file evidence, immutable verification or existing request/API budgets. Verified absent candidates no longer invalidate otherwise complete context; infrastructure/verification errors stay distinct. - Report the exact trusted-host/model completion conditions when analysis cannot be accepted. Preserve findings and fail closed when on-demand essential evidence becomes unavailable. - Record required on-demand failure reasons and close/drain lookups before the final result check, preventing late context mutation after submission. No inference, context-budget or approval-policy relaxation. -## Unreleased — inference diagnostics +### Inference diagnostics - Preserve correlated per-request primary and cleanup errors, bounded HTTP/SSE metadata and allowlisted transport causes. A consumer closing after a completed SSE response is no longer mislabeled as a provider failure; successful retries clear stale failures. - Distinguish fixed engine rejection reasons for incomplete/inconclusive results, invalid schema/head, quarantine and truncation. Incomplete reviews still fail CI and publish only a non-approving fallback. diff --git a/package-lock.json b/package-lock.json index d53086a..266209b 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "codexbot", - "version": "0.1.0", + "version": "0.1.1", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "codexbot", - "version": "0.1.0", + "version": "0.1.1", "license": "Apache-2.0", "dependencies": { "@octokit/rest": "22.0.1", diff --git a/package.json b/package.json index 0c26bb1..cf42183 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "codexbot", - "version": "0.1.0", + "version": "0.1.1", "private": true, "description": "Self-hostable GitHub App for isolated Codex pull request reviews", "license": "Apache-2.0", diff --git a/src/runner/engine.ts b/src/runner/engine.ts index 5ddb182..c9f25fa 100644 --- a/src/runner/engine.ts +++ b/src/runner/engine.ts @@ -47,7 +47,7 @@ export async function runCodex(snapshot: RequestSnapshot, manifest: string, plan let timedOut = false; const timer = setTimeout(() => { timedOut = true; child.kill('SIGKILL'); }, 20 * 60_000); try { - await rpc.request('initialize', { clientInfo: { name: 'CodexBot', title: 'CodexBot', version: '0.1.0' } }); + await rpc.request('initialize', { clientInfo: { name: 'CodexBot', title: 'CodexBot', version: '0.1.1' } }); rpc.notify('initialized'); const models: Record[] = []; let cursor: string | null = null; diff --git a/src/runner/proxy.ts b/src/runner/proxy.ts index a6c062e..93b3d3c 100644 --- a/src/runner/proxy.ts +++ b/src/runner/proxy.ts @@ -124,7 +124,7 @@ export async function inferenceProxy(request: IncomingMessage, response: ServerR stage = 'transport'; deadline = AbortSignal.timeout(20 * 60_000); const upstream = await fetcher('https://api.openai.com/v1/responses', { - method: 'POST', headers: { Authorization: 'Bearer '+token, 'Content-Type': 'application/json', 'User-Agent': 'CodexBot/0.1.0', + method: 'POST', headers: { Authorization: 'Bearer '+token, 'Content-Type': 'application/json', 'User-Agent': 'CodexBot/0.1.1', ...(typeof request.headers['originator'] === 'string' && request.headers['originator'] === 'CodexBot' ? { originator: 'CodexBot' } : {}) }, body: JSON.stringify(body), redirect: 'error', signal: AbortSignal.any([deadline, disconnected.signal]) }); diff --git a/src/worker/github.ts b/src/worker/github.ts index 715097a..17f070e 100644 --- a/src/worker/github.ts +++ b/src/worker/github.ts @@ -18,7 +18,7 @@ export async function appClient(env: GitHubCredentials): Promise { } export function client(token: string): Octokit { // Request errors can contain authorization headers: callers never log raw errors. - return new Octokit({ auth: token, log: { debug() {}, info() {}, warn() {}, error() {} }, request: { timeout: 20_000 }, userAgent: 'CodexBot/0.1.0' }); + return new Octokit({ auth: token, log: { debug() {}, info() {}, warn() {}, error() {} }, request: { timeout: 20_000 }, userAgent: 'CodexBot/0.1.1' }); } export async function installationClient(env: GitHubCredentials, installation: number, repositoryId: number, permissions: { contents?: 'read' | 'write'; pull_requests?: 'read' | 'write'; actions?: 'read' | 'write'; workflows?: 'write'; checks?: 'write'; administration?: 'read' }): Promise<{ github: Octokit; token: string }> { const app = await appClient(env); diff --git a/src/worker/index.ts b/src/worker/index.ts index f4449eb..039c749 100644 --- a/src/worker/index.ts +++ b/src/worker/index.ts @@ -70,7 +70,7 @@ async function route(request: Request, env: Env): Promise { requireCondition(publicPage || url.origin === canonical, 'non_canonical_backend_origin', 421); const origin = request.headers.get('origin'); requireCondition(!origin || origin === canonical, 'cross_origin_request_denied', 403); - if (url.pathname === '/health' && request.method === 'GET') return Response.json({ status: 'ok', version: '0.1.0' }); + if (url.pathname === '/health' && request.method === 'GET') return Response.json({ status: 'ok', version: '0.1.1' }); if (url.pathname === '/' && request.method === 'GET') return onboarding(env); const web = await webRoute(request, env); if (web) return web; if (url.pathname === '/v1/workload/check' && request.method === 'POST') { diff --git a/tests/backend.test.ts b/tests/backend.test.ts index 7e537ec..20ce3cf 100644 --- a/tests/backend.test.ts +++ b/tests/backend.test.ts @@ -11,7 +11,7 @@ await test('hosted config, manifest and generated callers agree on Workers.dev w assert.equal(DEFAULT_BACKEND, 'https://codexbot.appsolves.workers.dev'); const config = JSON.parse(await readFile('wrangler.jsonc', 'utf8')); assert.equal(config.name, 'codexbot'); assert.equal(config.workers_dev, true); assert.equal(config.preview_urls, false); - assert.equal(config.vars.PUBLIC_URL, DEFAULT_BACKEND); assert.equal(config.vars.MERGE_DEPLOYMENT_AUTHORIZED, 'true'); + assert.equal(config.vars.PUBLIC_URL, DEFAULT_BACKEND); assert.equal(config.vars.MERGE_DEPLOYMENT_AUTHORIZED, 'false'); assert.equal(config.vars.TRUSTED_WORKFLOW, 'AppSolves/codexbot/.github/workflows/review.yml@560083b99dddcf9a38a2d042ea6cc4fd1335db7b'); assert.equal(config.vars.WEB_ENABLED,'false');assert.equal(config.vars.OPENAI_HOSTED_INFERENCE_AUTHORIZED,'false'); assert.equal(config.vars.ACCEPTANCE_USER_PER_DAY,'');assert.equal(config.vars.MERGE_ACCEPTANCE_REPOSITORY_ID,'');assert.equal(config.vars.MERGE_ACCEPTANCE_INSTALLATION_ID,''); diff --git a/wrangler.jsonc b/wrangler.jsonc index 9919727..18a376f 100644 --- a/wrangler.jsonc +++ b/wrangler.jsonc @@ -33,7 +33,7 @@ "GITHUB_APP_SLUG": "codexbot-review", "TRUSTED_WORKFLOW": "AppSolves/codexbot/.github/workflows/review.yml@560083b99dddcf9a38a2d042ea6cc4fd1335db7b", "CHATGPT_DEPLOYMENT_AUTHORIZED": "true", - "MERGE_DEPLOYMENT_AUTHORIZED": "true", + "MERGE_DEPLOYMENT_AUTHORIZED": "false", "MERGE_ACCEPTANCE_REPOSITORY_ID": "", "MERGE_ACCEPTANCE_INSTALLATION_ID": "", "ACCEPTANCE_USER_PER_DAY": "",