@wardby/cli 0.5.3 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env.example +33 -0
- package/README.md +25 -14
- package/deploy/local/docker-compose.quickstart-coding.yml +13 -0
- package/dist/claude-coding-worker/context.d.ts +22 -0
- package/dist/claude-coding-worker/context.js +92 -0
- package/dist/claude-coding-worker/driver.d.ts +27 -3
- package/dist/claude-coding-worker/driver.js +161 -20
- package/dist/claude-coding-worker/main.js +34 -6
- package/dist/claude-coding-worker/sdk.js +25 -5
- package/dist/claude-coding-worker/tool-socket.d.ts +27 -0
- package/dist/claude-coding-worker/tool-socket.js +111 -0
- package/dist/claude-coding-worker/transcript.d.ts +18 -0
- package/dist/claude-coding-worker/transcript.js +77 -0
- package/dist/cli-help.d.ts +1 -1
- package/dist/cli-help.js +6 -2
- package/dist/cli-native-mode.d.ts +9 -0
- package/dist/cli-native-mode.js +20 -0
- package/dist/cli.d.ts +3 -1
- package/dist/cli.js +161 -11
- package/dist/coding/claude-context.d.ts +45 -0
- package/dist/coding/claude-context.js +434 -0
- package/dist/coding/continuation-wording.d.ts +35 -0
- package/dist/coding/continuation-wording.js +73 -0
- package/dist/coding/linked-issue-note.d.ts +23 -0
- package/dist/coding/linked-issue-note.js +47 -0
- package/dist/coding/merge-wording.d.ts +28 -0
- package/dist/coding/merge-wording.js +78 -0
- package/dist/coding/pr-description-note.d.ts +9 -0
- package/dist/coding/pr-description-note.js +32 -0
- package/dist/coding/profile.d.ts +50 -118
- package/dist/coding/profile.js +51 -4
- package/dist/coding/protected-path-wording.d.ts +8 -0
- package/dist/coding/protected-path-wording.js +1 -1
- package/dist/coding/protocol.d.ts +292 -270
- package/dist/coding/protocol.js +322 -15
- package/dist/coding/redact.d.ts +3 -0
- package/dist/coding/redact.js +12 -0
- package/dist/coding/registry/allowlist.d.ts +12 -0
- package/dist/coding/registry/allowlist.js +14 -1
- package/dist/coding/registry/audit-mode.d.ts +153 -0
- package/dist/coding/registry/audit-mode.js +304 -0
- package/dist/coding/registry/lockfile-shared.d.ts +36 -0
- package/dist/coding/registry/lockfile-shared.js +128 -0
- package/dist/coding/registry/lockfiles.js +1 -1
- package/dist/coding/registry/npm-lockfile-formats.d.ts +11 -0
- package/dist/coding/registry/npm-lockfile-formats.js +41 -0
- package/dist/coding/registry/npm-lockfile.d.ts +8 -4
- package/dist/coding/registry/npm-lockfile.js +4 -6
- package/dist/coding/registry/npm.js +78 -8
- package/dist/coding/registry/pnpm-lockfile.d.ts +17 -0
- package/dist/coding/registry/pnpm-lockfile.js +189 -0
- package/dist/coding/registry/pypi-plan.d.ts +50 -0
- package/dist/coding/registry/pypi-plan.js +406 -0
- package/dist/coding/registry/pypi-requirements.d.ts +58 -0
- package/dist/coding/registry/pypi-requirements.js +155 -0
- package/dist/coding/registry/pypi.d.ts +3 -27
- package/dist/coding/registry/pypi.js +40 -154
- package/dist/coding/registry/refusal-hints.d.ts +20 -0
- package/dist/coding/registry/refusal-hints.js +61 -0
- package/dist/coding/registry/refusal-wording.d.ts +11 -0
- package/dist/coding/registry/refusal-wording.js +56 -0
- package/dist/coding/registry/report.d.ts +70 -8
- package/dist/coding/registry/report.js +112 -5
- package/dist/coding/registry/types.d.ts +58 -8
- package/dist/coding/registry/yarn-lockfile.d.ts +30 -0
- package/dist/coding/registry/yarn-lockfile.js +367 -0
- package/dist/coding/services/catalog.d.ts +37 -351
- package/dist/coding/transcript/claude-code.d.ts +13 -0
- package/dist/coding/transcript/claude-code.js +273 -0
- package/dist/coding/transcript/download-protocol.d.ts +30 -0
- package/dist/coding/transcript/download-protocol.js +18 -0
- package/dist/coding/transcript/format.d.ts +20 -0
- package/dist/coding/transcript/format.js +32 -0
- package/dist/coding/transcript/recorder.d.ts +51 -0
- package/dist/coding/transcript/recorder.js +225 -0
- package/dist/coding/transcript/resume/checkout.d.ts +31 -0
- package/dist/coding/transcript/resume/checkout.js +203 -0
- package/dist/coding/transcript/resume/command.d.ts +17 -0
- package/dist/coding/transcript/resume/command.js +176 -0
- package/dist/coding/transcript/resume/download.d.ts +20 -0
- package/dist/coding/transcript/resume/download.js +153 -0
- package/dist/coding/transcript/resume/launch.d.ts +38 -0
- package/dist/coding/transcript/resume/launch.js +128 -0
- package/dist/coding/transcript/resume/session-file.d.ts +13 -0
- package/dist/coding/transcript/resume/session-file.js +79 -0
- package/dist/coding/transcript/resume/stand-in.d.ts +11 -0
- package/dist/coding/transcript/resume/stand-in.js +49 -0
- package/dist/coding-worker/artifact.d.ts +16 -3
- package/dist/coding-worker/artifact.js +5 -3
- package/dist/coding-worker/debug-trace.d.ts +6 -5
- package/dist/coding-worker/debug-trace.js +13 -18
- package/dist/coding-worker/dependency-cache.d.mts +229 -0
- package/dist/coding-worker/dependency-cache.mjs +2123 -0
- package/dist/coding-worker/driver.d.ts +4 -3
- package/dist/coding-worker/driver.js +118 -38
- package/dist/coding-worker/errors.d.ts +1 -0
- package/dist/coding-worker/errors.js +32 -0
- package/dist/coding-worker/sdk.d.ts +6 -0
- package/dist/coding-worker/sdk.js +1 -0
- package/dist/coding-worker/skills.d.ts +23 -0
- package/dist/coding-worker/skills.js +117 -0
- package/dist/coding-worker/task-note.d.ts +11 -0
- package/dist/coding-worker/task-note.js +13 -0
- package/dist/coding-worker/types.d.ts +13 -0
- package/dist/config/dependency-cache.d.ts +23 -0
- package/dist/config/dependency-cache.js +32 -0
- package/dist/config/github-allowed-accounts.d.ts +15 -0
- package/dist/config/github-allowed-accounts.js +36 -0
- package/dist/config/low-power.d.ts +12 -0
- package/dist/config/low-power.js +18 -0
- package/dist/config/mobile.d.ts +12 -0
- package/dist/config/mobile.js +18 -0
- package/dist/config/providers.d.ts +65 -3
- package/dist/config/providers.js +147 -11
- package/dist/config/test-simulators.d.ts +82 -0
- package/dist/config/test-simulators.js +305 -0
- package/dist/core/async-context.d.ts +2 -0
- package/dist/core/async-context.js +12 -0
- package/dist/core/budget-events.d.ts +108 -0
- package/dist/core/budget-events.js +346 -0
- package/dist/core/budget-groups.d.ts +50 -1
- package/dist/core/budget-groups.js +236 -27
- package/dist/core/budget-stopped-head.d.ts +46 -0
- package/dist/core/budget-stopped-head.js +81 -0
- package/dist/core/budget-topup.d.ts +51 -0
- package/dist/core/budget-topup.js +156 -0
- package/dist/core/budget-wording.d.ts +16 -2
- package/dist/core/budget-wording.js +40 -2
- package/dist/core/coding-queue.d.ts +2 -1
- package/dist/core/coding-queue.js +7 -0
- package/dist/core/cron.d.ts +19 -1
- package/dist/core/cron.js +17 -0
- package/dist/core/datastores.js +1 -1
- package/dist/core/db.d.ts +16 -6
- package/dist/core/db.js +12 -10
- package/dist/core/deferred-coding.d.ts +14 -0
- package/dist/core/deferred-coding.js +62 -0
- package/dist/core/delegation-child.d.ts +25 -0
- package/dist/core/delegation-child.js +37 -0
- package/dist/core/dispatch.d.ts +53 -0
- package/dist/core/dispatch.js +167 -57
- package/dist/core/engine-native.js +10 -6
- package/dist/core/error-code.d.ts +38 -0
- package/dist/core/error-code.js +168 -0
- package/dist/core/grants.d.ts +19 -6
- package/dist/core/grants.js +55 -6
- package/dist/core/host-events.d.ts +67 -5
- package/dist/core/host-events.js +571 -37
- package/dist/core/host-status.d.ts +85 -3
- package/dist/core/host-status.js +298 -20
- package/dist/core/issue-bridge.d.ts +50 -6
- package/dist/core/issue-bridge.js +151 -20
- package/dist/core/issue-events.d.ts +1 -1
- package/dist/core/issue-events.js +16 -11
- package/dist/core/issue-status.d.ts +1 -1
- package/dist/core/issue-status.js +68 -29
- package/dist/core/logger.d.ts +5 -0
- package/dist/core/logger.js +14 -1
- package/dist/core/lost-run-children.d.ts +6 -0
- package/dist/core/lost-run-children.js +32 -0
- package/dist/core/mark-ready.d.ts +34 -0
- package/dist/core/mark-ready.js +152 -0
- package/dist/core/markdown-code.d.ts +8 -0
- package/dist/core/markdown-code.js +107 -0
- package/dist/core/memory-tools.js +7 -0
- package/dist/core/merge-order-check.d.ts +130 -0
- package/dist/core/merge-order-check.js +343 -0
- package/dist/core/notification-dispatcher.d.ts +70 -0
- package/dist/core/notification-dispatcher.js +368 -0
- package/dist/core/notification-templates.d.ts +19 -0
- package/dist/core/notification-templates.js +139 -0
- package/dist/core/notifications.d.ts +10 -0
- package/dist/core/notifications.js +38 -0
- package/dist/core/pg-auth.d.ts +22 -0
- package/dist/core/pg-auth.js +152 -0
- package/dist/core/power-composition.d.ts +16 -0
- package/dist/core/power-composition.js +37 -0
- package/dist/core/power-idle.d.ts +14 -0
- package/dist/core/power-idle.js +30 -0
- package/dist/core/power.d.ts +71 -0
- package/dist/core/power.js +202 -0
- package/dist/core/pull-request-state-sync.js +2 -2
- package/dist/core/reconciler.d.ts +8 -5
- package/dist/core/reconciler.js +37 -6
- package/dist/core/related-pull-requests.d.ts +59 -7
- package/dist/core/related-pull-requests.js +140 -25
- package/dist/core/reply-parts.d.ts +21 -0
- package/dist/core/reply-parts.js +73 -0
- package/dist/core/repo-access.d.ts +15 -0
- package/dist/core/repo-access.js +66 -0
- package/dist/core/review-fix.d.ts +38 -1
- package/dist/core/review-fix.js +209 -7
- package/dist/core/review-host-checks.d.ts +1 -1
- package/dist/core/review-host-tools.d.ts +23 -0
- package/dist/core/review-host-tools.js +156 -14
- package/dist/core/review-reads.d.ts +55 -0
- package/dist/core/review-reads.js +233 -0
- package/dist/core/run-status.d.ts +12 -0
- package/dist/core/run-status.js +12 -0
- package/dist/core/runner.d.ts +384 -5
- package/dist/core/runner.js +1244 -372
- package/dist/core/schedule-start.d.ts +12 -0
- package/dist/core/schedule-start.js +14 -0
- package/dist/core/secret-broker-config.d.ts +39 -0
- package/dist/core/secret-broker-config.js +112 -0
- package/dist/core/secret-guard.d.ts +46 -0
- package/dist/core/secret-guard.js +104 -0
- package/dist/core/secret-guarded-stores.d.ts +12 -0
- package/dist/core/secret-guarded-stores.js +41 -0
- package/dist/core/secret-spans.d.ts +50 -0
- package/dist/core/secret-spans.js +94 -0
- package/dist/core/secrets.d.ts +39 -4
- package/dist/core/secrets.js +148 -40
- package/dist/core/stop-run.d.ts +46 -0
- package/dist/core/stop-run.js +61 -0
- package/dist/core/workflow-event-recorder.d.ts +14 -0
- package/dist/core/workflow-event-recorder.js +120 -0
- package/dist/core/workflow-events.d.ts +94 -0
- package/dist/core/workflow-events.js +48 -0
- package/dist/core/workflow-run-events.d.ts +18 -0
- package/dist/core/workflow-run-events.js +75 -0
- package/dist/core/zod-json-schema.d.ts +4 -0
- package/dist/core/zod-json-schema.js +39 -0
- package/dist/core/zod3-window.d.ts +35 -0
- package/dist/core/zod3-window.js +124 -0
- package/dist/generated/prisma/browser.d.ts +92 -3
- package/dist/generated/prisma/client.d.ts +92 -3
- package/dist/generated/prisma/commonInputTypes.d.ts +364 -54
- package/dist/generated/prisma/enums.d.ts +37 -0
- package/dist/generated/prisma/enums.js +31 -0
- package/dist/generated/prisma/internal/class.d.ts +132 -0
- package/dist/generated/prisma/internal/class.js +4 -4
- package/dist/generated/prisma/internal/prismaNamespace.d.ts +1332 -142
- package/dist/generated/prisma/internal/prismaNamespace.js +227 -5
- package/dist/generated/prisma/internal/prismaNamespaceBrowser.d.ts +234 -0
- package/dist/generated/prisma/internal/prismaNamespaceBrowser.js +227 -5
- package/dist/generated/prisma/models/Agent.d.ts +464 -7
- package/dist/generated/prisma/models/AgentRepository.d.ts +42 -1
- package/dist/generated/prisma/models/CodingAgentProfile.d.ts +301 -1
- package/dist/generated/prisma/models/CodingProxyRequest.d.ts +207 -3
- package/dist/generated/prisma/models/CodingProxySession.d.ts +114 -1
- package/dist/generated/prisma/models/CodingRun.d.ts +1841 -1
- package/dist/generated/prisma/models/DeferredReview.d.ts +78 -1
- package/dist/generated/prisma/models/DependencySnapshot.d.ts +1668 -0
- package/dist/generated/prisma/models/DependencySnapshot.js +1 -0
- package/dist/generated/prisma/models/IssuePullRequest.d.ts +6 -2
- package/dist/generated/prisma/models/LocalReview.d.ts +40 -1
- package/dist/generated/prisma/models/NativeGatewayCall.d.ts +1713 -0
- package/dist/generated/prisma/models/NativeGatewayCall.js +1 -0
- package/dist/generated/prisma/models/NativeGatewaySession.d.ts +1551 -0
- package/dist/generated/prisma/models/NativeGatewaySession.js +1 -0
- package/dist/generated/prisma/models/NativeWarmWorker.d.ts +1296 -0
- package/dist/generated/prisma/models/NativeWarmWorker.js +1 -0
- package/dist/generated/prisma/models/NotificationChannel.d.ts +1543 -0
- package/dist/generated/prisma/models/NotificationChannel.js +1 -0
- package/dist/generated/prisma/models/NotificationDelivery.d.ts +1502 -0
- package/dist/generated/prisma/models/NotificationDelivery.js +1 -0
- package/dist/generated/prisma/models/NotificationThread.d.ts +1090 -0
- package/dist/generated/prisma/models/NotificationThread.js +1 -0
- package/dist/generated/prisma/models/RegistryAllowance.d.ts +41 -1
- package/dist/generated/prisma/models/RegistryApprovedVersion.d.ts +75 -1
- package/dist/generated/prisma/models/RegistryAuditRecord.d.ts +1364 -0
- package/dist/generated/prisma/models/RegistryAuditRecord.js +1 -0
- package/dist/generated/prisma/models/Run.d.ts +1619 -58
- package/dist/generated/prisma/models/RunBudgetEvent.d.ts +1211 -0
- package/dist/generated/prisma/models/RunBudgetEvent.js +1 -0
- package/dist/generated/prisma/models/RunHostCheck.d.ts +36 -1
- package/dist/generated/prisma/models/RunTranscript.d.ts +1339 -0
- package/dist/generated/prisma/models/RunTranscript.js +1 -0
- package/dist/generated/prisma/models/Secret.d.ts +37 -1
- package/dist/generated/prisma/models/SecretBrokerChange.d.ts +1101 -0
- package/dist/generated/prisma/models/SecretBrokerChange.js +1 -0
- package/dist/generated/prisma/models/WorkflowEvent.d.ts +1422 -0
- package/dist/generated/prisma/models/WorkflowEvent.js +1 -0
- package/dist/generated/prisma/models.d.ts +12 -0
- package/dist/help/build.js +4 -2
- package/dist/help/catalog.d.ts +1 -1
- package/dist/help/catalog.js +31 -6
- package/dist/help-index.json +2584 -146
- package/dist/import/create.js +49 -3
- package/dist/import/neutral-schema.d.ts +50 -277
- package/dist/import/neutral-schema.js +7 -4
- package/dist/knowledge/check.d.ts +1 -1
- package/dist/knowledge/cli.d.ts +11 -1
- package/dist/knowledge/cli.js +37 -4
- package/dist/knowledge/concept.d.ts +3 -19
- package/dist/knowledge/location.d.ts +31 -0
- package/dist/knowledge/location.js +78 -0
- package/dist/mcp/auth/access.d.ts +11 -2
- package/dist/mcp/auth/access.js +15 -1
- package/dist/mcp/auth/ownership.d.ts +7 -7
- package/dist/mcp/auth/repo-authorization.js +14 -0
- package/dist/mcp/auth/resource-server.d.ts +2 -1
- package/dist/mcp/auth/resource-server.js +7 -2
- package/dist/mcp/auth/self-hosted/browser.d.ts +1 -1
- package/dist/mcp/auth/self-hosted/browser.js +19 -6
- package/dist/mcp/auth/self-hosted/credentials.d.ts +3 -3
- package/dist/mcp/auth/self-hosted/session.d.ts +2 -2
- package/dist/mcp/context.d.ts +6 -0
- package/dist/mcp/host-events/github-ingress.d.ts +25 -1
- package/dist/mcp/host-events/github-ingress.js +70 -1
- package/dist/mcp/index.d.ts +19 -0
- package/dist/mcp/index.js +117 -20
- package/dist/mcp/server.d.ts +13 -0
- package/dist/mcp/server.js +33 -14
- package/dist/mcp/tools/agents.d.ts +4 -0
- package/dist/mcp/tools/agents.js +277 -24
- package/dist/mcp/tools/datastore.js +17 -8
- package/dist/mcp/tools/grants.js +9 -3
- package/dist/mcp/tools/memory.js +11 -1
- package/dist/mcp/tools/notification-channels.d.ts +2 -0
- package/dist/mcp/tools/notification-channels.js +293 -0
- package/dist/mcp/tools/packages.d.ts +2 -0
- package/dist/mcp/tools/packages.js +195 -0
- package/dist/mcp/tools/power.d.ts +2 -0
- package/dist/mcp/tools/power.js +77 -0
- package/dist/mcp/tools/repositories.js +18 -5
- package/dist/mcp/tools/run-access.d.ts +16 -0
- package/dist/mcp/tools/run-access.js +25 -0
- package/dist/mcp/tools/run-transcript-download.d.ts +30 -0
- package/dist/mcp/tools/run-transcript-download.js +129 -0
- package/dist/mcp/tools/run-transcript.d.ts +19 -0
- package/dist/mcp/tools/run-transcript.js +70 -0
- package/dist/mcp/tools/runs.d.ts +0 -6
- package/dist/mcp/tools/runs.js +41 -14
- package/dist/mcp/tools/scheduling.js +3 -1
- package/dist/mcp/tools/secret-broker-compat.d.ts +12 -0
- package/dist/mcp/tools/secret-broker-compat.js +23 -0
- package/dist/mcp/tools/secret-elicitation-form.d.ts +22 -2
- package/dist/mcp/tools/secret-elicitation-form.js +205 -10
- package/dist/mcp/tools/secret-elicitation-server.d.ts +6 -0
- package/dist/mcp/tools/secret-elicitation-server.js +10 -54
- package/dist/mcp/tools/secret-elicitation.d.ts +38 -3
- package/dist/mcp/tools/secret-elicitation.js +110 -12
- package/dist/mcp/tools/secrets.js +186 -9
- package/dist/mcp/tools/stop-run.d.ts +2 -0
- package/dist/mcp/tools/stop-run.js +82 -0
- package/dist/mcp/tools/subagents.js +2 -2
- package/dist/mcp/tools/tools.d.ts +2 -2
- package/dist/mcp/tools/tools.js +47 -11
- package/dist/mcp/transport/stdio-link-host.d.ts +20 -0
- package/dist/mcp/transport/stdio-link-host.js +67 -0
- package/dist/mcp/transport/streamable-http.d.ts +13 -0
- package/dist/mcp/transport/streamable-http.js +41 -1
- package/dist/native-worker/composition.d.ts +23 -0
- package/dist/native-worker/composition.js +77 -0
- package/dist/native-worker/docker-isolation.d.ts +65 -0
- package/dist/native-worker/docker-isolation.js +183 -0
- package/dist/native-worker/docker-launcher.d.ts +110 -0
- package/dist/native-worker/docker-launcher.js +297 -0
- package/dist/native-worker/gateway-server.d.ts +77 -0
- package/dist/native-worker/gateway-server.js +412 -0
- package/dist/native-worker/gateway.d.ts +70 -0
- package/dist/native-worker/gateway.js +263 -0
- package/dist/native-worker/http-server.d.ts +24 -0
- package/dist/native-worker/http-server.js +113 -0
- package/dist/native-worker/http-transport.d.ts +17 -0
- package/dist/native-worker/http-transport.js +88 -0
- package/dist/native-worker/kubernetes-isolation.d.ts +90 -0
- package/dist/native-worker/kubernetes-isolation.js +218 -0
- package/dist/native-worker/kubernetes-launcher.d.ts +106 -0
- package/dist/native-worker/kubernetes-launcher.js +375 -0
- package/dist/native-worker/launch.d.ts +62 -0
- package/dist/native-worker/launch.js +49 -0
- package/dist/native-worker/ledger.d.ts +125 -0
- package/dist/native-worker/ledger.js +245 -0
- package/dist/native-worker/loopback.d.ts +12 -0
- package/dist/native-worker/loopback.js +44 -0
- package/dist/native-worker/main.d.ts +8 -0
- package/dist/native-worker/main.js +85 -0
- package/dist/native-worker/protocol.d.ts +296 -0
- package/dist/native-worker/protocol.js +246 -0
- package/dist/native-worker/sandbox-executor.d.ts +83 -0
- package/dist/native-worker/sandbox-executor.js +284 -0
- package/dist/native-worker/stderr-redaction.d.ts +77 -0
- package/dist/native-worker/stderr-redaction.js +237 -0
- package/dist/native-worker/stdio.d.ts +29 -0
- package/dist/native-worker/stdio.js +189 -0
- package/dist/native-worker/warm-delivery.d.ts +16 -0
- package/dist/native-worker/warm-delivery.js +33 -0
- package/dist/native-worker/warm-pool-ledger.d.ts +39 -0
- package/dist/native-worker/warm-pool-ledger.js +73 -0
- package/dist/native-worker/warm-pool.d.ts +107 -0
- package/dist/native-worker/warm-pool.js +283 -0
- package/dist/native-worker/worker.d.ts +17 -0
- package/dist/native-worker/worker.js +141 -0
- package/dist/observability/metrics.js +6 -1
- package/dist/providers/auth/authorization-server.d.ts +3 -0
- package/dist/providers/auth/index.js +2 -0
- package/dist/providers/auth/self-hosted.d.ts +14 -2
- package/dist/providers/auth/self-hosted.js +54 -4
- package/dist/providers/chat/fake.d.ts +46 -0
- package/dist/providers/chat/fake.js +39 -0
- package/dist/providers/chat/index.d.ts +4 -0
- package/dist/providers/chat/index.js +8 -0
- package/dist/providers/chat/slack.d.ts +37 -0
- package/dist/providers/chat/slack.js +105 -0
- package/dist/providers/chat/types.d.ts +42 -0
- package/dist/providers/chat/types.js +19 -0
- package/dist/providers/coding-proxy/dependency-cache/eviction.d.ts +29 -0
- package/dist/providers/coding-proxy/dependency-cache/eviction.js +87 -0
- package/dist/providers/coding-proxy/dependency-cache/key.d.ts +33 -0
- package/dist/providers/coding-proxy/dependency-cache/key.js +86 -0
- package/dist/providers/coding-proxy/dependency-cache/model-request-seal.d.ts +18 -0
- package/dist/providers/coding-proxy/dependency-cache/model-request-seal.js +40 -0
- package/dist/providers/coding-proxy/dependency-cache/prisma-store.d.ts +25 -0
- package/dist/providers/coding-proxy/dependency-cache/prisma-store.js +131 -0
- package/dist/providers/coding-proxy/dependency-cache/service.d.ts +70 -0
- package/dist/providers/coding-proxy/dependency-cache/service.js +409 -0
- package/dist/providers/coding-proxy/dependency-cache/store.d.ts +85 -0
- package/dist/providers/coding-proxy/dependency-cache/store.js +95 -0
- package/dist/providers/coding-proxy/hold.d.ts +32 -0
- package/dist/providers/coding-proxy/hold.js +86 -0
- package/dist/providers/coding-proxy/interrupted.d.ts +70 -0
- package/dist/providers/coding-proxy/interrupted.js +104 -0
- package/dist/providers/coding-proxy/memory-ledger.d.ts +15 -2
- package/dist/providers/coding-proxy/memory-ledger.js +84 -8
- package/dist/providers/coding-proxy/metering.d.ts +16 -0
- package/dist/providers/coding-proxy/metering.js +27 -4
- package/dist/providers/coding-proxy/prisma-ledger.d.ts +15 -2
- package/dist/providers/coding-proxy/prisma-ledger.js +179 -67
- package/dist/providers/coding-proxy/proxy.d.ts +14 -1
- package/dist/providers/coding-proxy/proxy.js +166 -14
- package/dist/providers/coding-proxy/registry/audit.d.ts +53 -10
- package/dist/providers/coding-proxy/registry/audit.js +94 -17
- package/dist/providers/coding-proxy/registry/lockfile-parse-worker.d.ts +36 -0
- package/dist/providers/coding-proxy/registry/lockfile-parse-worker.js +67 -0
- package/dist/providers/coding-proxy/registry/lockfile-parse.d.ts +16 -0
- package/dist/providers/coding-proxy/registry/lockfile-parse.js +110 -0
- package/dist/providers/coding-proxy/registry/plan.d.ts +9 -0
- package/dist/providers/coding-proxy/registry/plan.js +201 -48
- package/dist/providers/coding-proxy/registry/prisma-store.d.ts +11 -5
- package/dist/providers/coding-proxy/registry/prisma-store.js +120 -17
- package/dist/providers/coding-proxy/registry/service.d.ts +97 -16
- package/dist/providers/coding-proxy/registry/service.js +579 -112
- package/dist/providers/coding-proxy/registry/store.d.ts +84 -9
- package/dist/providers/coding-proxy/registry/store.js +54 -1
- package/dist/providers/coding-proxy/runtime.d.ts +4 -0
- package/dist/providers/coding-proxy/runtime.js +78 -16
- package/dist/providers/coding-proxy/server.d.ts +6 -1
- package/dist/providers/coding-proxy/server.js +45 -1
- package/dist/providers/coding-proxy/types.d.ts +65 -1
- package/dist/providers/datastore/types.d.ts +5 -0
- package/dist/providers/engine/types.d.ts +36 -2
- package/dist/providers/engine/types.js +39 -0
- package/dist/providers/executor/composition.d.ts +31 -1
- package/dist/providers/executor/composition.js +81 -8
- package/dist/providers/executor/container.d.ts +385 -9
- package/dist/providers/executor/container.js +1234 -99
- package/dist/providers/executor/dbos-status.d.ts +31 -0
- package/dist/providers/executor/dbos-status.js +64 -0
- package/dist/providers/executor/dbos.d.ts +91 -0
- package/dist/providers/executor/dbos.js +319 -26
- package/dist/providers/executor/deferred.d.ts +44 -0
- package/dist/providers/executor/deferred.js +100 -0
- package/dist/providers/executor/in-process.d.ts +9 -1
- package/dist/providers/executor/in-process.js +14 -4
- package/dist/providers/executor/linked-issue-reader.d.ts +16 -0
- package/dist/providers/executor/linked-issue-reader.js +30 -0
- package/dist/providers/executor/routing.d.ts +39 -10
- package/dist/providers/executor/routing.js +77 -32
- package/dist/providers/executor/types.d.ts +25 -0
- package/dist/providers/index.d.ts +2 -1
- package/dist/providers/issue-tracker/types.d.ts +17 -0
- package/dist/providers/issue-tracker/types.js +39 -1
- package/dist/providers/jobs/claude-tool-setup.d.ts +4 -0
- package/dist/providers/jobs/claude-tool-setup.js +5 -2
- package/dist/providers/jobs/docker-isolation.d.ts +8 -0
- package/dist/providers/jobs/docker-isolation.js +17 -0
- package/dist/providers/jobs/docker.d.ts +1 -0
- package/dist/providers/jobs/docker.js +29 -4
- package/dist/providers/jobs/fake-kubernetes-api.d.ts +23 -2
- package/dist/providers/jobs/fake-kubernetes-api.js +45 -1
- package/dist/providers/jobs/kubernetes-api.d.ts +25 -1
- package/dist/providers/jobs/kubernetes-api.js +17 -0
- package/dist/providers/jobs/kubernetes-client.d.ts +10 -1
- package/dist/providers/jobs/kubernetes-client.js +61 -3
- package/dist/providers/jobs/kubernetes-dry-run-fixture.d.ts +6 -1
- package/dist/providers/jobs/kubernetes-dry-run-fixture.js +6 -3
- package/dist/providers/jobs/kubernetes-isolation.d.ts +5 -1
- package/dist/providers/jobs/kubernetes-isolation.js +23 -1
- package/dist/providers/jobs/kubernetes-platform.d.ts +4 -1
- package/dist/providers/jobs/kubernetes-platform.js +38 -1
- package/dist/providers/jobs/kubernetes-preflight.d.ts +2 -1
- package/dist/providers/jobs/kubernetes-preflight.js +4 -2
- package/dist/providers/jobs/kubernetes.d.ts +42 -2
- package/dist/providers/jobs/kubernetes.js +178 -19
- package/dist/providers/jobs/metadata-probes.d.ts +11 -0
- package/dist/providers/jobs/metadata-probes.js +13 -0
- package/dist/providers/jobs/types.d.ts +42 -0
- package/dist/providers/jobs/types.js +13 -1
- package/dist/providers/llm/anthropic.js +5 -1
- package/dist/providers/llm/bedrock.d.ts +0 -12
- package/dist/providers/llm/bedrock.js +4 -0
- package/dist/providers/llm/claude-messages.d.ts +3 -1
- package/dist/providers/llm/claude-messages.js +4 -1
- package/dist/providers/llm/claude-provider.d.ts +2 -2
- package/dist/providers/llm/claude-provider.js +2 -2
- package/dist/providers/llm/openai.d.ts +2 -2
- package/dist/providers/llm/openai.js +6 -2
- package/dist/providers/llm/routing.d.ts +2 -2
- package/dist/providers/llm/routing.js +2 -2
- package/dist/providers/llm/types.d.ts +12 -2
- package/dist/providers/review-host/github-events.d.ts +9 -1
- package/dist/providers/review-host/github-events.js +34 -12
- package/dist/providers/review-host/github.d.ts +39 -2
- package/dist/providers/review-host/github.js +274 -29
- package/dist/providers/review-host/local.d.ts +8 -4
- package/dist/providers/review-host/local.js +49 -31
- package/dist/providers/review-host/patch-pages.d.ts +41 -0
- package/dist/providers/review-host/patch-pages.js +176 -0
- package/dist/providers/review-host/review-format.d.ts +19 -1
- package/dist/providers/review-host/review-format.js +38 -7
- package/dist/providers/review-host/types.d.ts +157 -2
- package/dist/providers/review-host/types.js +8 -0
- package/dist/providers/storage/gcs.d.ts +63 -0
- package/dist/providers/storage/gcs.js +69 -0
- package/dist/providers/storage/index.d.ts +15 -0
- package/dist/providers/storage/index.js +14 -0
- package/dist/providers/storage/local.d.ts +24 -0
- package/dist/providers/storage/local.js +92 -0
- package/dist/providers/storage/meter.d.ts +14 -0
- package/dist/providers/storage/meter.js +34 -0
- package/dist/providers/storage/s3.d.ts +41 -0
- package/dist/providers/storage/s3.js +107 -0
- package/dist/providers/storage/types.d.ts +37 -3
- package/dist/providers/storage/types.js +21 -4
- package/dist/providers/vcs/git.d.ts +33 -2
- package/dist/providers/vcs/git.js +324 -22
- package/dist/providers/vcs/github-remote.d.ts +26 -3
- package/dist/providers/vcs/github-remote.js +124 -14
- package/dist/providers/vcs/github.d.ts +246 -12
- package/dist/providers/vcs/github.js +521 -61
- package/dist/providers/vcs/index.js +8 -1
- package/dist/providers/vcs/pr-description.d.ts +127 -0
- package/dist/providers/vcs/pr-description.js +270 -0
- package/dist/providers/vcs/remote.d.ts +33 -1
- package/dist/providers/vcs/routing.d.ts +4 -2
- package/dist/providers/vcs/routing.js +6 -0
- package/dist/providers/vcs/types.d.ts +80 -3
- package/dist/quickstart/coding-seed.d.ts +21 -3
- package/dist/quickstart/coding-seed.js +283 -3
- package/dist/quickstart/images.d.ts +2 -0
- package/dist/quickstart/images.js +7 -1
- package/dist/quickstart/reviewer-prompt.d.ts +1 -1
- package/dist/quickstart/reviewer-prompt.js +6 -6
- package/dist/quickstart-images.json +1 -1
- package/dist/sandbox/brokered-fetch.d.ts +23 -0
- package/dist/sandbox/brokered-fetch.js +37 -0
- package/dist/sandbox/generated/zod.bundle.js +62 -1
- package/dist/sandbox/generated/zod3.bundle.js +5 -0
- package/dist/sandbox/host-functions.d.ts +35 -0
- package/dist/sandbox/host-functions.js +150 -91
- package/dist/sandbox/prelude.js +7 -1
- package/dist/sandbox/run-in-sandbox.d.ts +19 -0
- package/dist/sandbox/run-in-sandbox.js +28 -10
- package/dist/sandbox/safe-fetch.d.ts +2 -0
- package/dist/sandbox/safe-fetch.js +3 -1
- package/dist/sandbox/secret-broker-sigv4.d.ts +2 -0
- package/dist/sandbox/secret-broker-sigv4.js +49 -0
- package/dist/sandbox/secret-broker.d.ts +34 -0
- package/dist/sandbox/secret-broker.js +161 -0
- package/dist/sandbox/tool-capabilities.d.ts +10 -30
- package/dist/sandbox/user-tool.d.ts +14 -0
- package/dist/sandbox/user-tool.js +32 -0
- package/dist/sandbox/zod-params.d.ts +37 -5
- package/dist/sandbox/zod-params.js +181 -26
- package/dist/serve.js +25 -0
- package/dist/viewer/api-schema.d.ts +372 -2454
- package/dist/viewer/api-schema.js +29 -0
- package/dist/viewer/build-schemas.js +10 -3
- package/dist/viewer/event-bus.d.ts +6 -0
- package/dist/viewer/event-bus.js +16 -7
- package/dist/viewer/graph.d.ts +5 -2
- package/dist/viewer/graph.js +7 -2
- package/dist/viewer/http.d.ts +0 -1
- package/dist/viewer/http.js +2 -2
- package/dist/viewer/infra.js +25 -2
- package/dist/viewer/limits.d.ts +4 -0
- package/dist/viewer/limits.js +4 -0
- package/dist/viewer/openapi.d.ts +15 -0
- package/dist/viewer/openapi.js +170 -0
- package/dist/wardby-bin.js +10 -0
- package/docs/README.md +7 -0
- package/docs/agent-recipes.md +114 -27
- package/docs/architecture-runtime.md +16 -1
- package/docs/code-review-agents.md +689 -45
- package/docs/coding-agent-setup.md +602 -12
- package/docs/coding-packages.md +1037 -92
- package/docs/coding-services.md +30 -13
- package/docs/coding-worker-byo-images.md +218 -6
- package/docs/coding-worker-isolation.md +173 -44
- package/docs/getting-started-gke.md +332 -129
- package/docs/getting-started-identity-provider.md +31 -11
- package/docs/getting-started.md +14 -4
- package/docs/jira-agents.md +22 -9
- package/docs/knowledge/blob-not-found-semantics.md +41 -0
- package/docs/knowledge/bounded-file-descriptor.md +52 -0
- package/docs/knowledge/delegation-admission-slots.md +52 -0
- package/docs/knowledge/http-dispatcher-bootstrap.md +61 -0
- package/docs/knowledge/import-rename-target.md +52 -0
- package/docs/knowledge/index.md +57 -0
- package/docs/knowledge/log.md +9 -0
- package/docs/knowledge/mcp-cancelled-task-precedence.md +41 -0
- package/docs/knowledge/mcp-http-prompt-discovery.md +41 -0
- package/docs/knowledge/mcp-schema-module-boundary.md +41 -0
- package/docs/knowledge/nullable-tool-uniqueness.md +52 -0
- package/docs/knowledge/overview-cli.md +74 -0
- package/docs/knowledge/overview-coding-proxy.md +72 -0
- package/docs/knowledge/overview-coding.md +72 -0
- package/docs/knowledge/overview-config.md +60 -0
- package/docs/knowledge/overview-core.md +72 -0
- package/docs/knowledge/overview-deploy.md +83 -0
- package/docs/knowledge/overview-mcp.md +61 -0
- package/docs/knowledge/overview-prisma.md +72 -0
- package/docs/knowledge/overview-providers.md +89 -0
- package/docs/knowledge/overview-sandbox.md +83 -0
- package/docs/knowledge/overview-surfaces.md +83 -0
- package/docs/knowledge/private-datastore-shared-boundary.md +54 -0
- package/docs/knowledge/proxy-settlement-projections.md +41 -0
- package/docs/knowledge/run-pricing-first-writer.md +43 -0
- package/docs/knowledge/schedule-claim-transaction.md +41 -0
- package/docs/knowledge/secret-entry-replica-contract.md +52 -0
- package/docs/knowledge/terminal-run-first-writer.md +41 -0
- package/docs/knowledge/transactional-agent-authorization.md +52 -0
- package/docs/knowledge/viewer-notify-write-isolation.md +30 -0
- package/docs/knowledge/warm-input-publication.md +30 -0
- package/docs/knowledge/workspace-staging-failure.md +54 -0
- package/docs/knowledge.md +54 -14
- package/docs/native-sandbox.md +731 -0
- package/docs/observability.md +4 -0
- package/docs/release-verification.md +9 -0
- package/docs/security-deployment.md +146 -14
- package/docs/slack-notifications.md +268 -0
- package/docs/tool-secrets.md +284 -0
- package/docs/viewer-api.md +46 -5
- package/docs/viewer-api.openapi.yml +1404 -0
- package/help/admin-viewer.md +29 -3
- package/help/agent-recipes.md +27 -0
- package/help/architecture-agent.md +11 -6
- package/help/brokered-secrets.md +79 -0
- package/help/build-claude-code-image.md +131 -0
- package/help/build-worker-image.md +6 -7
- package/help/builder-agent.md +19 -6
- package/help/code-review-agents.md +243 -10
- package/help/coding-packages.md +156 -6
- package/help/cost-attribution.md +9 -5
- package/help/creating-agents.md +14 -1
- package/help/dependency-cache.md +143 -0
- package/help/deploy-gke.md +23 -9
- package/help/deployment-targets.md +25 -14
- package/help/errors/budget-exhausted.md +187 -0
- package/help/errors/budget-group-exhausted.md +5 -1
- package/help/errors/coding-provider-not-configured.md +2 -2
- package/help/errors/coding-stream-quota-exceeded.md +33 -0
- package/help/errors/coding-workspace-disk-exceeds-limit.md +39 -0
- package/help/errors/continuation-closed.md +9 -12
- package/help/errors/database-auth-invalid.md +28 -0
- package/help/errors/delegation-conflict.md +24 -0
- package/help/errors/file-list-truncated.md +45 -0
- package/help/errors/full-read-required.md +49 -0
- package/help/errors/github-account-not-allowed.md +29 -0
- package/help/errors/graph-incomplete.md +43 -0
- package/help/errors/graph-limit.md +43 -0
- package/help/errors/low-power-disabled.md +29 -0
- package/help/errors/low-power-scale-forbidden.md +35 -0
- package/help/errors/low-power-wake-timeout.md +30 -0
- package/help/errors/merge-conflict.md +49 -0
- package/help/errors/mobile-disabled.md +31 -0
- package/help/errors/native-sandbox-capacity.md +22 -0
- package/help/errors/native-sandbox-deadline-exceeded.md +19 -0
- package/help/errors/native-sandbox-docker-failed.md +20 -0
- package/help/errors/native-sandbox-gateway-error.md +20 -0
- package/help/errors/native-sandbox-gateway-unavailable.md +21 -0
- package/help/errors/native-sandbox-image-not-pinned.md +19 -0
- package/help/errors/native-sandbox-isolation-mismatch.md +20 -0
- package/help/errors/native-sandbox-launch-abandoned.md +21 -0
- package/help/errors/native-sandbox-network-unenforced.md +22 -0
- package/help/errors/native-sandbox-requires-catalog.md +31 -0
- package/help/errors/native-sandbox-unavailable.md +19 -0
- package/help/errors/native-sandbox-warm-delivery-failed.md +21 -0
- package/help/errors/native-sandbox-worker-exited.md +21 -0
- package/help/errors/native-sandbox-worker-lost.md +20 -0
- package/help/errors/native-sandbox-worker-unready.md +22 -0
- package/help/errors/package-not-allowed-pending.md +52 -0
- package/help/errors/package-not-allowed.md +51 -0
- package/help/errors/package-refusals.md +43 -0
- package/help/errors/patch-cursor-malformed.md +31 -0
- package/help/errors/run-lost.md +39 -0
- package/help/errors/run-transcript-download.md +44 -0
- package/help/errors/secret-broker-body-invalid.md +26 -0
- package/help/errors/secret-broker-changed.md +20 -0
- package/help/errors/secret-broker-config-invalid.md +30 -0
- package/help/errors/secret-broker-conflict.md +27 -0
- package/help/errors/secret-broker-destination-denied.md +28 -0
- package/help/errors/secret-broker-value-invalid.md +28 -0
- package/help/errors/secret-brokered.md +24 -0
- package/help/errors/secret-in-value.md +69 -0
- package/help/errors/secret-not-brokered.md +25 -0
- package/help/errors/slack-auth-failed.md +48 -0
- package/help/errors/slack-channel-unreachable.md +39 -0
- package/help/errors/slack-not-configured.md +33 -0
- package/help/errors/target-merge.md +40 -0
- package/help/fix-merge-conflicts.md +73 -0
- package/help/getting-started.md +4 -5
- package/help/github-app-setup.md +132 -0
- package/help/github.md +40 -1
- package/help/identity-and-access.md +7 -1
- package/help/jira.md +23 -6
- package/help/knowledge.md +16 -7
- package/help/local-repositories.md +3 -4
- package/help/low-power-mode.md +131 -0
- package/help/merge-order-check.md +122 -0
- package/help/mobile-app.md +54 -0
- package/help/native-capabilities.md +29 -1
- package/help/native-sandbox.md +150 -0
- package/help/observability.md +8 -0
- package/help/operating-agents.md +5 -0
- package/help/package-audit-mode.md +91 -0
- package/help/related-pull-requests.md +80 -16
- package/help/repo-instructions-and-skills.md +91 -0
- package/help/resume-runs-locally.md +131 -0
- package/help/review-fix-rounds.md +43 -1
- package/help/sharing-agents.md +59 -0
- package/help/slack-notifications.md +76 -0
- package/help/status-comments.md +31 -0
- package/help/stop-run.md +58 -0
- package/help/troubleshooting/budgets.md +28 -0
- package/help/troubleshooting/coding-workers.md +99 -7
- package/package.json +27 -13
- package/prisma/migrations/20261009000003_native_execution_mode/migration.sql +12 -0
- package/prisma/migrations/20261009000004_native_gateway_ledger/migration.sql +65 -0
- package/prisma/migrations/20261009000005_native_gateway_call_child_agent/migration.sql +5 -0
- package/prisma/migrations/20261009000006_run_deferred_start_stop/migration.sql +14 -0
- package/prisma/migrations/20261009000007_native_gateway_network_ready/migration.sql +5 -0
- package/prisma/migrations/20261010000001_workflow_notifications/migration.sql +99 -0
- package/prisma/migrations/20261011000001_native_gateway_session_status_index/migration.sql +2 -0
- package/prisma/migrations/20261012000001_native_warm_worker/migration.sql +32 -0
- package/prisma/migrations/20261013000001_coding_run_merge_order/migration.sql +2 -0
- package/prisma/migrations/20261013000001_secret_broker/migration.sql +17 -0
- package/prisma/migrations/20261013000002_deferred_review_request/migration.sql +4 -0
- package/prisma/migrations/20261014000000_repo_skills/migration.sql +15 -0
- package/prisma/migrations/20261015000001_coding_run_merge_order_index/migration.sql +2 -0
- package/prisma/migrations/20261015000002_no_change_rereview/migration.sql +2 -0
- package/prisma/migrations/20261016000000_registry_approved_accepted_advisories/migration.sql +3 -0
- package/prisma/migrations/20261016000001_mark_ready_when_passing/migration.sql +3 -0
- package/prisma/migrations/20261017000000_debug_trace_max_mb/migration.sql +4 -0
- package/prisma/migrations/20261018000000_dependency_cache/migration.sql +53 -0
- package/prisma/migrations/20261019000000_claude_max_output_tokens/migration.sql +5 -0
- package/prisma/migrations/20261021000000_pr_description_hash/migration.sql +4 -0
- package/prisma/migrations/20261022000000_dependency_snapshot_validation_metadata/migration.sql +4 -0
- package/prisma/migrations/20261023000000_package_audit_mode/migration.sql +27 -0
- package/prisma/migrations/20261024000000_budget_events/migration.sql +26 -0
- package/prisma/migrations/20261025000000_cache_aware_holds/migration.sql +9 -0
- package/prisma/migrations/20261026000000_budget_overrun/migration.sql +4 -0
- package/prisma/migrations/20261027000000_coding_run_request/migration.sql +1 -0
- package/prisma/migrations/20261028000000_native_gateway_review_reads/migration.sql +6 -0
- package/prisma/migrations/20261029000000_lead_survives_deploy/migration.sql +6 -0
- package/prisma/migrations/20261030000000_local_review_covered_sha/migration.sql +2 -0
- package/prisma/migrations/20261031000000_coding_run_budget_limit/migration.sql +9 -0
- package/prisma/migrations/20261101000000_run_transcripts/migration.sql +22 -0
- package/prisma/schema.prisma +631 -146
- package/dist/sandbox/generated/zod-to-json-schema.bundle.js +0 -5
|
@@ -31,6 +31,15 @@ Once an agent is linked to a repository with the `pull_request` trigger:
|
|
|
31
31
|
runs. When the cause is budget, the check says so ("Review could not run:
|
|
32
32
|
out of budget") and names the budget that was used up; use **Re-run** after
|
|
33
33
|
raising the budget or once it resets.
|
|
34
|
+
- A pull request that is still a **draft**, whose latest commit was pushed by a
|
|
35
|
+
coding run that stopped at its budget, is not reviewed automatically: the
|
|
36
|
+
check completes as `neutral` with the title "Skipped: stopped at its
|
|
37
|
+
budget". This is deliberate and is not the dispatch failure above: a draft
|
|
38
|
+
is not merged, and the review would only repeat findings the continuation
|
|
39
|
+
addresses. Marking the pull request ready for review or pushing a new
|
|
40
|
+
commit starts a normal review, and so does re-running the check or a
|
|
41
|
+
review mention. See
|
|
42
|
+
[Stopped for budget](coding-agent-setup.md#stopped-for-budget-the-work-so-far-is-kept).
|
|
34
43
|
- On a later review, the agent sees its own unresolved inline threads and
|
|
35
44
|
can **resolve the ones the new head fixes**, so fixed findings collapse on
|
|
36
45
|
the PR page. Only threads that agent started are resolved; people's
|
|
@@ -61,9 +70,30 @@ thread) right after the reaction. When the run ends, the App edits that
|
|
|
61
70
|
comment with the outcome:
|
|
62
71
|
|
|
63
72
|
- the pull requests the run's coding sub-runs opened or pushed to;
|
|
73
|
+
- ⛔ **Blocked by the package registry: no changes were made.** when coding
|
|
74
|
+
sub-runs recorded package refusals and no pull request or pushed changes
|
|
75
|
+
resulted. The comment lists up to ten distinct refusals, with reasons,
|
|
76
|
+
registry codes and fixes; use `get_run` for the full list. An approver updates
|
|
77
|
+
`codingProfile.packageAllowlist` or `codingProfile.packagePolicy` with
|
|
78
|
+
`update_agent` (needs `packages:approve` or `agents:admin`), then the
|
|
79
|
+
requester mentions `@wardby` again. See [Package policy](coding-packages.md)
|
|
80
|
+
and [Status comments help](../help/status-comments.md). Jira status comments
|
|
81
|
+
and Slack notifications use the same blocked guidance;
|
|
82
|
+
- a ⚠️ dependency install warning listing refusals when changes were pushed,
|
|
83
|
+
while keeping the pull request link. Without refusals, the usual ✅ / ❌
|
|
84
|
+
wording remains;
|
|
64
85
|
- the agent's final reply, quoted, when no pull request came out (for
|
|
65
86
|
example, a question back to the requester). `@`-mentions in the reply are
|
|
66
87
|
defused so nobody is pinged;
|
|
88
|
+
- when that reply is longer than about 2,000 characters, the comment says
|
|
89
|
+
"✅ Finished without opening a pull request. The full reply follows in the
|
|
90
|
+
next comment(s)." (in a review thread: "...follows in this pull request's
|
|
91
|
+
conversation."), and the reply follows in up to four numbered comments
|
|
92
|
+
("Reply, part i of n") of about 60,000 characters each, split at headings,
|
|
93
|
+
paragraphs or lines. Anything beyond four parts is cut with a note that the
|
|
94
|
+
full text is on the run (`get_run`, `finalText`); each part is posted once,
|
|
95
|
+
and if one cannot be posted the rest are skipped. Runs that opened a pull
|
|
96
|
+
request or had a failed sub-run keep the quoted excerpt;
|
|
67
97
|
- a failure when a coding sub-run it started did not succeed, even though
|
|
68
98
|
the mention agent itself finished (with the agent's reply quoted);
|
|
69
99
|
- that the request was **interrupted** and should be repeated, when the run
|
|
@@ -90,10 +120,78 @@ repository can trigger a run. wardby asks GitHub for the author's real
|
|
|
90
120
|
permission on the repository (by their numeric user id) before either path
|
|
91
121
|
runs; `read` and `triage` are not enough, because a mention drives an agent
|
|
92
122
|
that holds its owner's tools, secrets, and write access. GitHub's
|
|
93
|
-
`author_association`
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
123
|
+
`author_association` is only a first filter: it drops first-time authors
|
|
124
|
+
(`FIRST_TIME_CONTRIBUTOR`, `FIRST_TIMER`) and mannequins, and lets every
|
|
125
|
+
other association through to the permission check. That includes
|
|
126
|
+
`CONTRIBUTOR` and `NONE`, which GitHub reports for an organization member
|
|
127
|
+
whose membership is private. Mentions by bots, and mentions from anyone
|
|
128
|
+
without access to the repository, are ignored silently (no run, no reaction).
|
|
129
|
+
The server logs an info line for each one, naming the event, repository and
|
|
130
|
+
association, never the text.
|
|
131
|
+
|
|
132
|
+
Someone who holds a role on the repository but lacks write access can see it
|
|
133
|
+
but cannot start a run. Their mention gets a 😕 reaction and a one-line reply
|
|
134
|
+
saying a mention needs write access, so they know to ask someone who has it.
|
|
135
|
+
No run starts. That applies to anyone with `triage` access, and to anyone with
|
|
136
|
+
`read` access on a private repository, or whose `author_association` is
|
|
137
|
+
`OWNER`, `MEMBER` or `COLLABORATOR`. GitHub reports `read` for every account
|
|
138
|
+
on a public repository, so a stranger there (association `NONE`,
|
|
139
|
+
`CONTRIBUTOR` or unknown) is refused silently and learns nothing about the App.
|
|
140
|
+
|
|
141
|
+
A mention inside Markdown code is not a request. Text in an inline code span
|
|
142
|
+
(`` `@<app-slug>` ``), a fenced code block, or an indented code block is
|
|
143
|
+
skipped, so you can document the App's commands in an issue, pull request or
|
|
144
|
+
comment without starting a run. This applies to `@<app-slug> review` too.
|
|
145
|
+
|
|
146
|
+
When someone with write access mentions the App and nothing starts, the App
|
|
147
|
+
replies on the issue or pull request (in the review thread, if the mention was
|
|
148
|
+
in one) instead of leaving the mention unanswered. It says which of these applies, with no 👀
|
|
149
|
+
reaction:
|
|
150
|
+
|
|
151
|
+
- **No agent answers mentions on the repository** — no agent is linked with
|
|
152
|
+
the `mention` trigger. Link one (see [Linking an
|
|
153
|
+
agent](#linking-an-agent-to-a-repository)).
|
|
154
|
+
- **No reviewer is linked** — `@<app-slug> review` was used, but no agent is
|
|
155
|
+
linked with the `pull_request` trigger and a `checkName`.
|
|
156
|
+
- **The linked agent can no longer use the repository** — the agent owner's
|
|
157
|
+
GitHub account lost access, or its authorization lapsed. The owner
|
|
158
|
+
re-authorizes or re-links the agent.
|
|
159
|
+
- **The pull request is closed or comes from a fork** — wardby reviews only
|
|
160
|
+
open pull requests from branches of the repository.
|
|
161
|
+
|
|
162
|
+
The reply never names the App, so it cannot be read as a mention of itself.
|
|
163
|
+
|
|
164
|
+
The reply is a comment that anyone who can see the repository reads, so on a
|
|
165
|
+
public repository it shows what is (or isn't) linked there. To keep that to
|
|
166
|
+
yourself, set `WARDBY_MENTION_EXPLANATIONS=false` on the server: a mention that
|
|
167
|
+
starts nothing then gets no reply at all. The default is `true`.
|
|
168
|
+
|
|
169
|
+
If a mention from someone with write access gets no reaction or reply, check
|
|
170
|
+
the server log for `mention ignored` or `mention declined`. Older versions dropped `CONTRIBUTOR` and
|
|
171
|
+
`NONE` authors before the permission check. On those versions, make the
|
|
172
|
+
organization membership public or post the mention as a comment.
|
|
173
|
+
|
|
174
|
+
### Follow-ups on an issue
|
|
175
|
+
|
|
176
|
+
If a mention lands on a GitHub **issue** that already has an open pull request
|
|
177
|
+
wardby opened, the run message includes that pull request and the exact run id
|
|
178
|
+
to pass as `continuePriorRun`, so the agent pushes to the same branch instead
|
|
179
|
+
of opening a second pull request. This is the same behaviour, and the same
|
|
180
|
+
sentence, as [follow-ups on a Jira issue](jira-agents.md): GitHub and Jira
|
|
181
|
+
issues record the pull requests opened for them alike. The message lists up to
|
|
182
|
+
ten open pull requests recorded for the issue, each with its own run id. A
|
|
183
|
+
stopped-for-budget draft is continued this way too (see
|
|
184
|
+
[Stopped for budget](coding-agent-setup.md#stopped-for-budget-the-work-so-far-is-kept)).
|
|
185
|
+
A pull request opened from a mention on a GitHub issue starts its description
|
|
186
|
+
with `From issue #N` for that issue when the issue is in the same repository,
|
|
187
|
+
the same place a Jira issue's pull request has its `Resolves Jira issue …`
|
|
188
|
+
line; follow-ups keep the line. The line only links the issue: whether merging
|
|
189
|
+
closes it is up to the agent. Have the delivery or builder prompt end the
|
|
190
|
+
summary with `Resolves #N` to close the issue on merge, or `Refs #N` to leave
|
|
191
|
+
it open (for a plan, or one ticket of an epic). A follow-up keeps whichever
|
|
192
|
+
line the previous description had. The help article
|
|
193
|
+
[Run GitHub code-review agents](../help/code-review-agents.md#follow-ups-on-an-issue)
|
|
194
|
+
says the same in short.
|
|
97
195
|
|
|
98
196
|
### What the mention agent receives
|
|
99
197
|
|
|
@@ -188,6 +286,52 @@ PR description:
|
|
|
188
286
|
agent can reach only the tools and access you would give that outsider's
|
|
189
287
|
text.
|
|
190
288
|
|
|
289
|
+
## Follow-ups bring the pull request up to date
|
|
290
|
+
|
|
291
|
+
Every follow-up run on a pull request a wardby coding run opened (a mention on
|
|
292
|
+
the pull request, a delegated `continuePriorRun`, a review fix round) first
|
|
293
|
+
merges the branch the pull request **currently** targets into its branch:
|
|
294
|
+
|
|
295
|
+
- **The target is read from GitHub when the run starts**, so a pull request
|
|
296
|
+
retargeted since it opened (a stacked pull request whose parent merged, a
|
|
297
|
+
release branch) merges its new base. Retargeting does not make wardby treat
|
|
298
|
+
the pull request as closed.
|
|
299
|
+
- **The merge happens before the agent starts**, in trusted wardby code. The
|
|
300
|
+
target branch is fetched from the same repository with the App's access;
|
|
301
|
+
a fork is never fetched. A branch that already contains its target is left
|
|
302
|
+
exactly as it was, and the run behaves as it always has.
|
|
303
|
+
- **Conflicts are the agent's to resolve.** The conflicted files keep standard
|
|
304
|
+
conflict markers, and the agent's task lists them, says which side is the
|
|
305
|
+
pull request and which is the target, and asks it to resolve every conflict
|
|
306
|
+
keeping both sides' intent, fix the tests the combination broke, and run the
|
|
307
|
+
repository's checks. A conflicted file that still holds markers when the run
|
|
308
|
+
ends stops the push: the run fails with category `merge_conflict`
|
|
309
|
+
([help](../help/errors/merge-conflict.md)) and nothing is pushed. A
|
|
310
|
+
conflicted file with no markers (a binary file, or one deleted on one side
|
|
311
|
+
and changed on the other) holds one side's version, or the changed version,
|
|
312
|
+
and the agent is asked to check it.
|
|
313
|
+
- **The push is one merge commit authored by Wardby**, whose parents are the
|
|
314
|
+
head the run started from and the target. It is pushed even when the agent
|
|
315
|
+
changed nothing else, so "please update this PR" or "please fix the merge
|
|
316
|
+
conflicts" in a mention is enough. The run's status comment says what was
|
|
317
|
+
merged ("Merged `main` @ `1a2b3c4` into this branch; resolved conflicts in 2
|
|
318
|
+
files.").
|
|
319
|
+
- **Checks apply to the agent's own changes**, measured against the automatic
|
|
320
|
+
merge: the target branch's changes, including to protected paths, merge as
|
|
321
|
+
they are, while an agent edit to a protected path (resolving a conflict in
|
|
322
|
+
one, or reverting the target's change to one) is refused as usual, so a
|
|
323
|
+
conflict in a protected path has to be resolved by hand. The
|
|
324
|
+
changed-file and diff-size limits count only the agent's changes, so merging
|
|
325
|
+
a busy target branch does not exhaust them.
|
|
326
|
+
- **The push stays a fast-forward** of the head the run started from: a push
|
|
327
|
+
by anyone else in the meantime fails the run, with nothing pushed, as before.
|
|
328
|
+
- A target branch that cannot be fetched or shares no history with the pull
|
|
329
|
+
request fails the run before the agent starts, with category `target_merge`
|
|
330
|
+
([help](../help/errors/target-merge.md)).
|
|
331
|
+
|
|
332
|
+
The clone is shallow, so wardby deepens its history step by step until the
|
|
333
|
+
branch and its target share a commit, up to about 5,000 commits back.
|
|
334
|
+
|
|
191
335
|
## Automatic review fix rounds
|
|
192
336
|
|
|
193
337
|
Linking an agent with the `review_fix` trigger (`access: "write"`, at most
|
|
@@ -196,6 +340,10 @@ without waiting for a human to ask. `reviewFixMaxRounds` (an integer from 1
|
|
|
196
340
|
to 10, default 2) caps how many rounds a single pull request gets before
|
|
197
341
|
wardby stops; re-linking without it resets the cap back to the default.
|
|
198
342
|
|
|
343
|
+
No round follows a review that was skipped because the draft stopped at its
|
|
344
|
+
budget (neutral, "Skipped: stopped at its budget"); a round needs a
|
|
345
|
+
`CHANGES_REQUESTED` review.
|
|
346
|
+
|
|
199
347
|
A round starts when wardby's own review check on a pull request finishes as
|
|
200
348
|
`CHANGES_REQUESTED`, and all of the following still hold:
|
|
201
349
|
|
|
@@ -262,6 +410,126 @@ it starts a fresh review, and if that review requests changes, it starts a
|
|
|
262
410
|
fix round the same way any other review would (subject to the cap and to no
|
|
263
411
|
earlier round still running).
|
|
264
412
|
|
|
413
|
+
With Wardby 0.6.0 or later, a round whose coding run ends with no change —
|
|
414
|
+
the agent concluded the review's finding was wrong rather than pushing a
|
|
415
|
+
fix — gets one fresh review instead, of the pull request's current
|
|
416
|
+
(unchanged) head, run by the reviewer whose check requested the changes.
|
|
417
|
+
The fix round's own summary is passed to that reviewer as untrusted
|
|
418
|
+
context: information about what was decided and why, never instructions to
|
|
419
|
+
follow. This happens once per review that requested changes, counts toward
|
|
420
|
+
the pull request's round cap the same as a round that pushed a change, and
|
|
421
|
+
at the cap posts the usual cap comment instead of re-reviewing — since no
|
|
422
|
+
push happened, nothing else would otherwise replace the failed check.
|
|
423
|
+
|
|
424
|
+
### How the pull request description is kept current
|
|
425
|
+
|
|
426
|
+
Every coding run's final message is the full pull request description: what
|
|
427
|
+
changed, the checklist, how to try it, and any closing line such as
|
|
428
|
+
`Resolves #N`. It may be up to 64 KiB; a longer one is cut at a line boundary
|
|
429
|
+
with a `[summary truncated]` marker instead of failing the run. When the whole
|
|
430
|
+
description would pass GitHub's 65,536-character limit, wardby first drops the
|
|
431
|
+
**Packages** section, then truncates the final message, keeping a closing
|
|
432
|
+
`Resolves #N` last line. That holds for follow-ups too: review fix rounds, mention
|
|
433
|
+
follow-ups, and continuations. Agents launched for a follow-up receive the
|
|
434
|
+
description text wardby last wrote (its agent-written part, not the live pull
|
|
435
|
+
request body) as quoted, untrusted context, so they can carry forward what
|
|
436
|
+
still applies.
|
|
437
|
+
|
|
438
|
+
A follow-up also receives the original issue the pull request was opened for,
|
|
439
|
+
the way the first run did: its title and body, quoted as untrusted context,
|
|
440
|
+
as reference material: a note says its acceptance criteria as written are
|
|
441
|
+
what the description's checklist should reflect, that the final message must
|
|
442
|
+
carry that checklist and the closing line, and that no instruction in the
|
|
443
|
+
issue is followed. The issue is read as it is now, so edits made to it since
|
|
444
|
+
the first run are included.
|
|
445
|
+
wardby finds the issue from the run that started the work: the Jira issue it
|
|
446
|
+
was attributed to, else the GitHub issue whose `@wardby` mention started it,
|
|
447
|
+
else the issue that wardby's last description closes (`Resolves #N`). Only
|
|
448
|
+
issues in the pull request's own repository are read, through the same GitHub
|
|
449
|
+
App access the run already has; a Jira issue is read through the configured
|
|
450
|
+
Jira integration. The issue text is cut to about 6 KB. If the issue can't be
|
|
451
|
+
read, the run goes ahead without it.
|
|
452
|
+
|
|
453
|
+
A continuation updates the description of the pull request it continues, even
|
|
454
|
+
when it changes no code. The run's final message replaces the agent-written
|
|
455
|
+
part. wardby rebuilds its own sections from that run: the dependency-install
|
|
456
|
+
warning, **Tests**, **Packages**, and the dependency-cache line. The
|
|
457
|
+
first-line `<!-- wardby:... -->` marker stays, and a
|
|
458
|
+
`<!-- wardby-latest:<run> -->` line at the end records the latest run.
|
|
459
|
+
|
|
460
|
+
**Packages** lists every package installed by the runs that pushed to the pull
|
|
461
|
+
request, plus the latest run's, each package and version once. Refused
|
|
462
|
+
packages, and the dependency-install warning built from them, describe the
|
|
463
|
+
latest run only, since they reflect the pull request's current state.
|
|
464
|
+
|
|
465
|
+
If wardby can't confirm the description is unchanged since it wrote it (for
|
|
466
|
+
example, a person edited it), it does not overwrite it. Instead it keeps one
|
|
467
|
+
comment on the pull request with the current description proposed by its
|
|
468
|
+
latest run, inside a collapsed section. The comment names that run and the
|
|
469
|
+
commit it describes, says why it wasn't applied, and says the pull request
|
|
470
|
+
author can copy it into the description. Later runs edit the same comment
|
|
471
|
+
rather than adding new ones; if duplicates exist (for example, two runs
|
|
472
|
+
posting at once), wardby edits the newest and rewrites the others to point at
|
|
473
|
+
it. wardby only edits comments its own GitHub App wrote, never a person's or
|
|
474
|
+
another App's. On a run that pushes a commit, the comment is written before
|
|
475
|
+
the push, so it is already there when the push starts a review.
|
|
476
|
+
|
|
477
|
+
If the author copies the proposal into the description unchanged, the next
|
|
478
|
+
run sees that the description matches wardby's latest proposal, takes the
|
|
479
|
+
description back, writes it directly from then on, and updates the comment to
|
|
480
|
+
say no proposal is pending. The same happens when a later run can write the
|
|
481
|
+
description directly for any other reason.
|
|
482
|
+
|
|
483
|
+
The comment's first line records the head commit the proposal describes. A
|
|
484
|
+
review reads it when the reviewer reads the pull request (`repo_pr_read`'s
|
|
485
|
+
`descriptionProposal`), not when the review starts, and only uses it when it
|
|
486
|
+
was written for the head being reviewed. Then a description requirement
|
|
487
|
+
(closing line, acceptance checklist, how to try it, test results) is met if
|
|
488
|
+
either the live description or the proposal meets it. If the latest proposal
|
|
489
|
+
is for another commit, the reviewer is told no proposal for this head exists
|
|
490
|
+
yet and reviews the live description. The proposal reaches the reviewer as
|
|
491
|
+
untrusted data, cut to 16 KB.
|
|
492
|
+
|
|
493
|
+
Pull requests opened by an earlier wardby version have no record of what
|
|
494
|
+
wardby wrote. For those, wardby rebuilds the description its first run would
|
|
495
|
+
have written, from that run's stored final message, tests, packages,
|
|
496
|
+
dependency-cache line and issue link, and compares it with the live
|
|
497
|
+
description (ignoring the **Related pull requests** section, line endings and
|
|
498
|
+
blank lines). If they match, nobody edited it: wardby replaces it and records
|
|
499
|
+
it from then on. If anything differs, including any text a person added, or
|
|
500
|
+
the stored records can't rebuild it, the description counts as edited and gets
|
|
501
|
+
the comment.
|
|
502
|
+
|
|
503
|
+
If the final message is empty, very short (fewer than 80 non-whitespace
|
|
504
|
+
characters), or drops a
|
|
505
|
+
closing keyword (such as `Resolves #N`) that the previous description had,
|
|
506
|
+
wardby keeps the previous agent text and refreshes only its own sections.
|
|
507
|
+
|
|
508
|
+
A description update does not start a separate review: it stays one review per
|
|
509
|
+
pushed commit.
|
|
510
|
+
|
|
511
|
+
`get_run` shows the result as `prDescriptionOutcome`:
|
|
512
|
+
|
|
513
|
+
- `written`: the first description of a new pull request.
|
|
514
|
+
- `replaced`: a continuation replaced the agent-written part.
|
|
515
|
+
- `refreshed:<reason>`: the final message was invalid, so the previous agent
|
|
516
|
+
text was kept and only wardby's sections were refreshed. The reason is
|
|
517
|
+
`empty`, `too_short` (fewer than 80 non-whitespace characters), or
|
|
518
|
+
`missing_closing_keyword`.
|
|
519
|
+
- `unchanged`: nothing needed to change.
|
|
520
|
+
- `edited_by_hand`: wardby couldn't confirm the description is its own: a
|
|
521
|
+
person edited it, it no longer starts with wardby's marker, or (for pull
|
|
522
|
+
requests opened by an earlier version) it doesn't match the description
|
|
523
|
+
rebuilt from wardby's records. wardby posts or updates the proposal comment
|
|
524
|
+
when it can.
|
|
525
|
+
- `skipped:<reason>`: the description was not updated. The reason is
|
|
526
|
+
`not_open` (the pull request is not open or was not found), `too_long` (the
|
|
527
|
+
description is still over 65,536 characters after dropping **Packages** and
|
|
528
|
+
truncating the final message), or
|
|
529
|
+
`error` (any failure, including a failed update request, a failed load of
|
|
530
|
+
wardby's last-written text, a failed hash record or access re-check, or the
|
|
531
|
+
60-second timeout; the update may still have landed).
|
|
532
|
+
|
|
265
533
|
If a repository already forwards wardby's reviews to a webhook through a
|
|
266
534
|
hand-written CI workflow to fix them automatically, replace that workflow
|
|
267
535
|
with `review_fix`: link the trigger, then delete the workflow and its
|
|
@@ -383,26 +651,29 @@ with:
|
|
|
383
651
|
endpoint answers 404 until this is set.
|
|
384
652
|
- **Subscribe to events**: Pull request, Issue comment, Pull request review
|
|
385
653
|
comment, Check run, Check suite (re-runs a review that was waiting for CI
|
|
386
|
-
once CI finishes,
|
|
387
|
-
finishes
|
|
388
|
-
|
|
654
|
+
once CI finishes, starts a `waitForCi` reviewer's held review once CI
|
|
655
|
+
finishes, and lets [`markReadyWhenPassing`](#mark-ready-when-passing) mark a
|
|
656
|
+
draft ready once CI goes green; without it, those drafts stay drafts),
|
|
657
|
+
Issues (needed for mentions in a newly opened or edited issue; without it
|
|
658
|
+
only comment mentions are seen), and Push (needed
|
|
389
659
|
for the `push` trigger, which starts merge-watcher agents; it is its own
|
|
390
660
|
checkbox, separate from the others, and must be ticked explicitly).
|
|
391
661
|
- **Repository permissions**:
|
|
392
662
|
|
|
393
|
-
| Permission | Access
|
|
394
|
-
| --------------- |
|
|
395
|
-
| Contents | Read
|
|
396
|
-
| Pull requests | Read and write
|
|
397
|
-
| Checks | Read and write
|
|
398
|
-
| Issues | Read and write
|
|
399
|
-
| Commit statuses | Read (optional)
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
663
|
+
| Permission | Access |
|
|
664
|
+
| --------------- | -------------------------------------------------- |
|
|
665
|
+
| Contents | Read and write (Read for an App that only reviews) |
|
|
666
|
+
| Pull requests | Read and write |
|
|
667
|
+
| Checks | Read and write |
|
|
668
|
+
| Issues | Read and write |
|
|
669
|
+
| Commit statuses | Read (optional) |
|
|
670
|
+
|
|
671
|
+
**Contents: Read and write** is required for coding agents, which push a
|
|
672
|
+
branch for each pull request they open. An App used only for review agents
|
|
673
|
+
can have **Read**, except that review agents then can't resolve their own
|
|
674
|
+
fixed threads: GitHub gates resolving a review thread on **Contents: Read
|
|
675
|
+
and write**, although it changes no repository content. wardby asks for it
|
|
676
|
+
only for the resolve call itself.
|
|
406
677
|
|
|
407
678
|
**Issues: Read and write** is also what lets wardby add and remove the
|
|
408
679
|
`wardby-autofix-*` labels used by [automatic review fix
|
|
@@ -444,6 +715,50 @@ A GitHub App has exactly one webhook URL. Register a **separate App** for
|
|
|
444
715
|
local development or a staging environment rather than pointing your
|
|
445
716
|
production App's webhook at a dev host.
|
|
446
717
|
|
|
718
|
+
### Which accounts the App serves (`WARDBY_GITHUB_ALLOWED_ACCOUNTS`)
|
|
719
|
+
|
|
720
|
+
A GitHub App has one webhook URL, so every account that installs it sends its
|
|
721
|
+
events to your server. wardby serves only trusted accounts:
|
|
722
|
+
|
|
723
|
+
- **The App's owner** (the user or organization that owns the App), always.
|
|
724
|
+
- **Accounts in `WARDBY_GITHUB_ALLOWED_ACCOUNTS`**, comma-separated logins:
|
|
725
|
+
|
|
726
|
+
WARDBY_GITHUB_ALLOWED_ACCOUNTS=acme-labs
|
|
727
|
+
|
|
728
|
+
Every other account is refused: its events are answered `202` and ignored before
|
|
729
|
+
anything is recorded, and `link_repository` and coding profiles refuse its
|
|
730
|
+
repositories with `github_account_not_allowed`, even with `adminOverride`.
|
|
731
|
+
There is no setting that serves every account.
|
|
732
|
+
|
|
733
|
+
wardby removes the App from another account's installation only when that
|
|
734
|
+
account installs the App or changes the installation's repository selection.
|
|
735
|
+
Installations that already exist on other accounts stay installed (their
|
|
736
|
+
events are ignored); remove them by hand in the App's settings under
|
|
737
|
+
**Install App**.
|
|
738
|
+
|
|
739
|
+
**When you upgrade**, existing repository links and scheduled runs on
|
|
740
|
+
repositories of accounts that are not served start failing with
|
|
741
|
+
`github_account_not_allowed`. List those accounts in the variable first if they
|
|
742
|
+
should keep working.
|
|
743
|
+
|
|
744
|
+
A private App can only be installed on its owner, so it needs nothing here. Set
|
|
745
|
+
the variable when the App must be installable by other accounts, for example
|
|
746
|
+
when an organization owns the App and a user's repositories should be served
|
|
747
|
+
too. Logins are matched case-insensitively; a malformed value stops the server
|
|
748
|
+
at startup.
|
|
749
|
+
|
|
750
|
+
wardby reads the App's owner login from GitHub (`GET /app`, with the App's own
|
|
751
|
+
credentials) and remembers it until it restarts. If it cannot read the owner,
|
|
752
|
+
it refuses rather than guesses. After you transfer the App to another owner or
|
|
753
|
+
rename the owner account, list the new owner in
|
|
754
|
+
`WARDBY_GITHUB_ALLOWED_ACCOUNTS` (or restart wardby) before relying on it:
|
|
755
|
+
until then, events from the new owner are ignored. Before removing the App
|
|
756
|
+
from an installation, wardby re-reads the owner, so it never removes the App
|
|
757
|
+
from its current owner.
|
|
758
|
+
|
|
759
|
+
Each wardby server should have its own GitHub App: never point other people at
|
|
760
|
+
yours; give them the setup steps above instead.
|
|
761
|
+
|
|
447
762
|
### `GITHUB_APP_WEBHOOK_SECRET`
|
|
448
763
|
|
|
449
764
|
Set alongside `GITHUB_APP_ID` and `GITHUB_APP_PRIVATE_KEY`
|
|
@@ -485,9 +800,9 @@ linking stays disabled there.
|
|
|
485
800
|
First link your GitHub account (`link_host_account`, above). Then use the
|
|
486
801
|
`link_repository` tool (agents:write) on a native agent you own. Calling it
|
|
487
802
|
again for an already-linked repository replaces that link's `access`,
|
|
488
|
-
`triggers`, `checkName`, `reviewFixMaxRounds`,
|
|
489
|
-
fields are cleared, not kept — and checks
|
|
490
|
-
the full desired state. Two common shapes:
|
|
803
|
+
`triggers`, `checkName`, `reviewFixMaxRounds`, `waitForCi`, and
|
|
804
|
+
`markReadyWhenPassing` — omitted fields are cleared, not kept — and checks
|
|
805
|
+
your access again, so always send the full desired state. Two common shapes:
|
|
491
806
|
|
|
492
807
|
**A reviewer**, which starts a check on every PR push:
|
|
493
808
|
|
|
@@ -501,6 +816,11 @@ the full desired state. Two common shapes:
|
|
|
501
816
|
}
|
|
502
817
|
```
|
|
503
818
|
|
|
819
|
+
With Wardby 0.6.0 or later, a `pull_request` reviewer's review of a pull request
|
|
820
|
+
opened by a delegated coding run is held until the run that delegated it
|
|
821
|
+
finishes, whether or not this link sets `waitForCi` — see [Reviewing a pull request a delegated run
|
|
822
|
+
opened](#reviewing-a-pull-request-a-delegated-run-opened) below.
|
|
823
|
+
|
|
504
824
|
Add `"waitForCi": true` to a `pull_request` link to hold the reviewer's
|
|
505
825
|
review of a pushed head until that head's own CI finishes, instead of racing
|
|
506
826
|
it — see [Review after CI (`waitForCi`)](#review-after-ci-waitforci) below.
|
|
@@ -570,6 +890,59 @@ The errors you may get while linking:
|
|
|
570
890
|
| 409 | Another agent already holds the `mention` or `review_fix` trigger, or this `checkName`, on the repository. |
|
|
571
891
|
| 503 | GitHub could not be asked (e.g. the App isn't installed on the repository). Nothing was changed. |
|
|
572
892
|
|
|
893
|
+
### Reviewing a pull request a delegated run opened
|
|
894
|
+
|
|
895
|
+
> **Requires Wardby 0.6.0 or later.** Earlier releases review a delegated
|
|
896
|
+
> run's pull request on its first push, like any other.
|
|
897
|
+
|
|
898
|
+
A coding run can be delegated: a lead agent's `delegate_to_<name>` call
|
|
899
|
+
starts a coding sub-agent that pushes the branch and opens the pull request
|
|
900
|
+
(see [Fanning out to several builders](agent-recipes.md#fanning-out-to-several-builders)).
|
|
901
|
+
While the lead run that delegated it is still running, every reviewer linked
|
|
902
|
+
with the `pull_request` trigger holds its review of that pull request instead
|
|
903
|
+
of starting on the first push — including a reviewer with no `waitForCi` set.
|
|
904
|
+
The review starts once the lead run finishes, however it ends (including
|
|
905
|
+
failing, being cancelled or being lost).
|
|
906
|
+
|
|
907
|
+
Holding the review this way means the request's other pull requests, if any,
|
|
908
|
+
have also been opened by the time any of them is reviewed. When the lead run
|
|
909
|
+
finishes normally, the **Related pull requests** section on each of them has
|
|
910
|
+
also been rewritten with the full list (see [Related pull requests across
|
|
911
|
+
repositories](../help/related-pull-requests.md)). When it is ended another
|
|
912
|
+
way (for example, cancelled), the held reviews start without that section
|
|
913
|
+
having been rewritten, so it can be incomplete. Either way, a reviewer should
|
|
914
|
+
use `repo_pr_read`'s `relatedPullRequests`, which is computed from Wardby's
|
|
915
|
+
own records on every call, so it does not report a field, route, or schema as
|
|
916
|
+
missing only because a sibling repository's pull request had not been opened
|
|
917
|
+
yet.
|
|
918
|
+
|
|
919
|
+
- A reviewer linked with `waitForCi` then also waits for CI on the head, once
|
|
920
|
+
the lead run finishes, exactly as described below — with its own full
|
|
921
|
+
15-minute fallback, counted from that point, not from the original push.
|
|
922
|
+
- If the deployment cannot tell whether the pull request's opening run was
|
|
923
|
+
delegated (for example, the host call to read its origin fails), the
|
|
924
|
+
review starts immediately instead, exactly as it would without this
|
|
925
|
+
behaviour.
|
|
926
|
+
- These pull requests are never held by this: one opened directly by a
|
|
927
|
+
coding run that was not delegated, one opened by a human, and one on a
|
|
928
|
+
local repository (which has no origin to read).
|
|
929
|
+
- A later request that continues an already-open pull request is not held
|
|
930
|
+
again: the request that opened it has already finished. A push that
|
|
931
|
+
continues the pull request inside the same, still-running request is held
|
|
932
|
+
like the first one.
|
|
933
|
+
- From Wardby 0.7.0, a push to a pull request that is still a **draft** is
|
|
934
|
+
held while the coding run that pushed it may still be pushing (its result
|
|
935
|
+
is not recorded yet), so a run that stopped at its budget is never
|
|
936
|
+
reviewed mid-way. When that coding run was delegated by a lead that is
|
|
937
|
+
still running, as for a follow-up request, the review is held until that
|
|
938
|
+
lead finishes, the same as for the first request.
|
|
939
|
+
- As with the CI fallback below, a hold here does not depend on the
|
|
940
|
+
instance that started it still running when the lead run finishes:
|
|
941
|
+
Wardby's reconciliation sweep reconsiders every review held for at least
|
|
942
|
+
15 minutes and releases it once the lead run has finished or no longer
|
|
943
|
+
exists, wherever the scheduler process runs. A held review is dropped
|
|
944
|
+
unreleased after 24 hours, the same as a review held for CI.
|
|
945
|
+
|
|
573
946
|
### Review after CI (`waitForCi`)
|
|
574
947
|
|
|
575
948
|
`waitForCi` (boolean, default `false`, only on a `pull_request` link — 400
|
|
@@ -650,13 +1023,203 @@ Turning `waitForCi` off (re-linking without it, or with it set to `false`)
|
|
|
650
1023
|
only changes how future pushes are handled; it never retroactively starts or
|
|
651
1024
|
drops a review already being held.
|
|
652
1025
|
|
|
1026
|
+
### Large pull requests
|
|
1027
|
+
|
|
1028
|
+
From Wardby 0.7.0, `repo_pr_read` returns a large pull request's diff in pages.
|
|
1029
|
+
All changed files share one character budget per call (`maxPatchChars`,
|
|
1030
|
+
default 60,000, at most 200,000). Source, test and configuration files get it
|
|
1031
|
+
first. Everything else follows: the repository root's `docs/`, `doc/` and
|
|
1032
|
+
`help/` folders; lockfiles; anything under a `generated/`, `__generated__/`,
|
|
1033
|
+
`dist/`, `vendor/`, `fixtures/`, `__fixtures__/`, `__snapshots__/` or
|
|
1034
|
+
`testdata/` folder at any depth; minified `.min.js` and `.min.css` files; and
|
|
1035
|
+
documents and images (`.md`, `.mdx`, `.rst`, `.adoc`, `.txt`, `.snap`, `.svg`,
|
|
1036
|
+
`.png`, `.jpg`, `.jpeg`, `.gif`, `.webp`, `.ico`, `.pdf`, `.lock`).
|
|
1037
|
+
`requirements*.txt` and `CMakeLists.txt` count as code. A page that includes source, test or config files stops before the first doc, help, lockfile or generated file, so those come on later pages and a reviewer can skip them. Patches are split on line boundaries, and a file that does not fit on
|
|
1038
|
+
the page after other content moves to the next page. Each file has a
|
|
1039
|
+
`patchStatus`: `complete`, `partial`, `later_page`, `earlier_page`,
|
|
1040
|
+
`unavailable` (the host has no patch, for example a very large file; read it
|
|
1041
|
+
with `repo_read_file`) or `empty`. A `partial` file also reports
|
|
1042
|
+
`patchOffset`, where its part starts, and `patchContinues`, which is `true`
|
|
1043
|
+
when the next page carries more of the same file.
|
|
1044
|
+
|
|
1045
|
+
When `patchesComplete` is `false`, the result lists `truncatedFiles`, gives
|
|
1046
|
+
`nextPatchCursor`, and estimates the files still to come in
|
|
1047
|
+
`remainingPatchFiles`. Call `repo_pr_read` again with the same arguments plus
|
|
1048
|
+
`patchCursor` to get the next page. Because code is filled first, a reviewer
|
|
1049
|
+
only has to page while a source, test or config file is still in
|
|
1050
|
+
`truncatedFiles`: the pages after that hold documentation, lockfiles and
|
|
1051
|
+
generated files, which the `unread_files` refusal never requires, so the
|
|
1052
|
+
reviewer can skim or skip them and spend less of its budget. A file the host found `unavailable` stays
|
|
1053
|
+
reported as such on later pages, and `patchesComplete` stays `false`. A cursor
|
|
1054
|
+
only works for the head and compare it was issued for: after a new push,
|
|
1055
|
+
`patch_cursor_stale` says to call again without it, and a damaged or oversized
|
|
1056
|
+
cursor returns `patch_cursor_malformed` (see
|
|
1057
|
+
[Patch cursor is malformed](../help/errors/patch-cursor-malformed.md)).
|
|
1058
|
+
|
|
1059
|
+
`repo_publish_review` refuses `APPROVE` with
|
|
1060
|
+
`unread_files` while a source, test or config file of that head that
|
|
1061
|
+
`repo_pr_read` listed in the run is neither fully delivered nor read with
|
|
1062
|
+
`repo_read_file` at the head (one read of the path at the head counts).
|
|
1063
|
+
Every file any `repo_pr_read` of the head listed in the run stays gated: a
|
|
1064
|
+
later read with `sinceSha` lists fewer files but never takes any off.
|
|
1065
|
+
Removed files, documentation, lockfiles, generated files and fixtures are not
|
|
1066
|
+
gated, `CHANGES_REQUESTED` and `COMMENT` are always allowed, and the refusal
|
|
1067
|
+
changes nothing, so the agent can read the files and publish again. A file read in parts counts only
|
|
1068
|
+
when its parts join up from the start of its patch to its last part. The guard
|
|
1069
|
+
is per run attempt: a head is gated only when the attempt itself read its first
|
|
1070
|
+
page (a `repo_pr_read` without `patchCursor`), so an attempt resumed after a
|
|
1071
|
+
restart is not refused for pages an earlier attempt read. A reviewer that
|
|
1072
|
+
cannot read everything should publish `CHANGES_REQUESTED` and list the files it
|
|
1073
|
+
did not review. Not `COMMENT`: it completes the check as neutral, which GitHub
|
|
1074
|
+
branch protection treats as passing, so an unfinished review would let the pull
|
|
1075
|
+
request merge.
|
|
1076
|
+
|
|
1077
|
+
The `unread_files` refusal applies in both execution modes. In `sandbox` mode
|
|
1078
|
+
(see [Native agent sandbox](native-sandbox.md)) the gateway saves what the run
|
|
1079
|
+
has read on its session after each `repo_pr_read` and `repo_read_file` call, so
|
|
1080
|
+
`repo_publish_review` checks the same reads as in `control-plane` mode.
|
|
1081
|
+
Reviewer prompts written before 0.7.0 still work, because the refusal tells
|
|
1082
|
+
the agent what to do; update them with the paging step from the shipped
|
|
1083
|
+
reviewer prompt.
|
|
1084
|
+
|
|
1085
|
+
The file list itself has an upper bound: `repo_pr_read` lists at most 1,000
|
|
1086
|
+
changed files of a pull request, on GitHub and on a local repository alike,
|
|
1087
|
+
and on GitHub a `sinceSha` compare lists at most 300 (GitHub's own compare
|
|
1088
|
+
limit). When the pull request has more changed files than that, the result
|
|
1089
|
+
has `fileListComplete: false` and the files past the cut are not shown. Once
|
|
1090
|
+
a `repo_pr_read` of a head in the run is cut, `repo_publish_review` refuses
|
|
1091
|
+
`APPROVE` of that head with `file_list_truncated`, even when every listed file
|
|
1092
|
+
was read: an approval would cover files the agent never saw.
|
|
1093
|
+
`CHANGES_REQUESTED` and `COMMENT` still publish. Only a complete read of the
|
|
1094
|
+
whole pull request (without `sinceSha`) in the same run lifts the refusal, so
|
|
1095
|
+
an agent that passed `sinceSha` can call `repo_pr_read` again without it; a
|
|
1096
|
+
complete `sinceSha` read does not. A later run cannot approve the head through a
|
|
1097
|
+
`sinceSha` delta either, because a review whose list was cut never becomes a
|
|
1098
|
+
covered head (below). Otherwise `repo_publish_review` refuses the agent's
|
|
1099
|
+
`APPROVE` of that pull request: split it, or have a person review it. See
|
|
1100
|
+
[`file_list_truncated`](../help/errors/file-list-truncated.md).
|
|
1101
|
+
|
|
1102
|
+
`sinceSha` accepts any earlier commit of the branch, so a read with it only
|
|
1103
|
+
narrows the review to the changes since that commit. `repo_pr_read` therefore
|
|
1104
|
+
also returns `lastCoveredSha`: the latest head this agent reviewed after
|
|
1105
|
+
reading every file, whatever the verdict. A review counts as covering its head
|
|
1106
|
+
when, in that run, no file list of the head was left cut, every source, test
|
|
1107
|
+
and config file it listed was read, and the run either read the whole pull
|
|
1108
|
+
request (no `sinceSha`) or compared only from the `lastCoveredSha` its reads
|
|
1109
|
+
returned. A review that does not cover its head keeps the earlier covered head.
|
|
1110
|
+
On GitHub the covered head is kept in the agent's summary comment marker (a
|
|
1111
|
+
summary comment written by a version before 0.7.0 has none, so the next review
|
|
1112
|
+
reads the whole pull request); on a local repository it is kept with each
|
|
1113
|
+
review. Only a marker at the very start of the App's own summary comment
|
|
1114
|
+
counts. In text an agent or a run supplies and the App posts (`repo_comment`,
|
|
1115
|
+
the summary, body and inline comments of `repo_publish_review`, and a mention
|
|
1116
|
+
run's status and reply), wardby escapes `<!--` as `<!--` wherever it comes
|
|
1117
|
+
right before a wardby marker name, so such text shows as plain text and can
|
|
1118
|
+
never form a wardby marker. Any other HTML comment, such as one in a code
|
|
1119
|
+
block or a one-click suggestion, is posted as written. Text is escaped before
|
|
1120
|
+
its length limit is checked, and wardby adds its own markers after that. The coding-run status comment and the description comment are
|
|
1121
|
+
written by wardby and start with wardby's own marker. So an agent cannot be
|
|
1122
|
+
talked into vouching for a head it never read.
|
|
1123
|
+
|
|
1124
|
+
`repo_publish_review` refuses `APPROVE` with `full_read_required` while the
|
|
1125
|
+
run has no `repo_pr_read` of the head without `sinceSha` and one of its reads
|
|
1126
|
+
compared from a commit other than the `lastCoveredSha` that read returned. A
|
|
1127
|
+
commit named in the pull request's own text, or `lastReviewedSha` when it
|
|
1128
|
+
differs from `lastCoveredSha`, is not a safe base. The agent reads the whole
|
|
1129
|
+
pull request (no `sinceSha`) or passes `lastCoveredSha`; the shipped reviewer
|
|
1130
|
+
prompt does this. See
|
|
1131
|
+
[`full_read_required`](../help/errors/full-read-required.md).
|
|
1132
|
+
|
|
1133
|
+
Reviewer prompts written before 0.7.0 pass `lastReviewedSha` as `sinceSha`.
|
|
1134
|
+
They still work, because the refusal tells the agent to read the whole pull
|
|
1135
|
+
request, but update their re-review step from the shipped reviewer prompt to
|
|
1136
|
+
avoid the extra read. Owners of agents whose prompt is stored with the agent
|
|
1137
|
+
update it with `update_agent`.
|
|
1138
|
+
|
|
1139
|
+
### Mark ready when passing (`markReadyWhenPassing`)
|
|
1140
|
+
|
|
1141
|
+
With Wardby 0.7.0 or later, `markReadyWhenPassing` (boolean, default
|
|
1142
|
+
`false`, only on a write link — 400 on a read link) has wardby mark its own
|
|
1143
|
+
draft pull requests ready for review once they pass, instead of leaving
|
|
1144
|
+
that to a person. Set it with `link_repository` on the write link of the
|
|
1145
|
+
agent that the repository event triggers: a builder that opens the pull
|
|
1146
|
+
request itself, or — for a lead that delegates to a coding builder sub-agent
|
|
1147
|
+
— the lead's link. The coding builder needs no repository link of its own
|
|
1148
|
+
(coding agents can't have one). The setting counts for a pull request
|
|
1149
|
+
opened by that agent's own coding run or by a coding run anywhere below it
|
|
1150
|
+
in its run tree (up to 10 delegation levels); an opted-in agent that is not the
|
|
1151
|
+
opener or one of its ancestors in the run tree never counts. Re-linking that
|
|
1152
|
+
repository without it clears it, like every other link setting (see
|
|
1153
|
+
above); `list_repositories` shows its current value.
|
|
1154
|
+
|
|
1155
|
+
Wardby marks a pull request ready for review once all of these hold, read
|
|
1156
|
+
fresh from GitHub on its current head:
|
|
1157
|
+
|
|
1158
|
+
- the pull request is open and a draft;
|
|
1159
|
+
- Wardby's own GitHub App opened it, and its head is not in a fork;
|
|
1160
|
+
- the agent whose coding run opened it, or an agent that delegated to it
|
|
1161
|
+
(directly or through other sub-agents), has `markReadyWhenPassing` set
|
|
1162
|
+
on an authorized write link to this repository;
|
|
1163
|
+
- at least one authorized reviewer link with the `pull_request` trigger
|
|
1164
|
+
exists on the repository, and every one of those reviewers' own checks on
|
|
1165
|
+
the head completed with conclusion `success`;
|
|
1166
|
+
- CI is green: every check run and commit status on the head that is not
|
|
1167
|
+
one of Wardby's own checks has completed with `success`, `neutral`, or
|
|
1168
|
+
`skipped`, with at least one `success` — or the repository reports no CI
|
|
1169
|
+
at all. All-neutral or all-skipped CI counts as inconclusive and waits. A
|
|
1170
|
+
pull request with more checks and statuses than Wardby reads (about 50) is
|
|
1171
|
+
truncated and never marked ready automatically. CI still pending, failing,
|
|
1172
|
+
truncated, or unreadable leaves the pull request in draft; see the
|
|
1173
|
+
re-evaluation triggers below for when Wardby checks again.
|
|
1174
|
+
- the `wardby merge order` check (see [The wardby merge order
|
|
1175
|
+
check](../help/merge-order-check.md)) is `success`, or is not posted on
|
|
1176
|
+
this pull request at all.
|
|
1177
|
+
|
|
1178
|
+
A commit status only counts toward CI being green if the App can read it:
|
|
1179
|
+
grant **Commit statuses: Read** (see [Registering the GitHub
|
|
1180
|
+
App](#registering-the-github-app) above) if your CI reports commit statuses
|
|
1181
|
+
rather than check runs; without it, wardby judges CI from check runs alone.
|
|
1182
|
+
|
|
1183
|
+
Wardby marks a given pull request ready at most once. If a person moves it
|
|
1184
|
+
back to draft afterward, wardby leaves it there — it never re-marks a pull
|
|
1185
|
+
request once it has done so.
|
|
1186
|
+
|
|
1187
|
+
Wardby re-checks whether a pull request is ready to mark on any of these
|
|
1188
|
+
events:
|
|
1189
|
+
|
|
1190
|
+
- a reviewer run finishing;
|
|
1191
|
+
- a CI check suite completing on its head;
|
|
1192
|
+
- its `wardby merge order` check turning `success` — for example, right
|
|
1193
|
+
after an earlier step in its set merges;
|
|
1194
|
+
- and, as a fallback for any of the above missed, wardby's own merge-order
|
|
1195
|
+
reconciliation sweep, for a pull request that is part of a merge-ordered
|
|
1196
|
+
set (see [The reconciliation sweep](../help/merge-order-check.md#the-reconciliation-sweep)).
|
|
1197
|
+
|
|
1198
|
+
CI that reports only commit statuses (no check suite) is not re-checked when
|
|
1199
|
+
it finishes — GitHub does not raise a check-suite event for a status-only
|
|
1200
|
+
commit. Such a pull request is marked ready the next time one of the events
|
|
1201
|
+
above fires, or stays in draft until then.
|
|
1202
|
+
|
|
1203
|
+
With a merge-ordered set of delegated pull requests (see [Fanning out to
|
|
1204
|
+
several builders](agent-recipes.md#fanning-out-to-several-builders)), a
|
|
1205
|
+
later step only becomes ready for review once the steps it depends on have
|
|
1206
|
+
merged — it stays a draft until the `wardby merge order` check on it reports
|
|
1207
|
+
`success`.
|
|
1208
|
+
|
|
1209
|
+
`markReadyWhenPassing` never approves, merges, or converts a pull request
|
|
1210
|
+
back to draft — a person's own approval stays the gate wherever branch
|
|
1211
|
+
protection requires one. It needs the App's **Pull requests: Read and
|
|
1212
|
+
write** permission, which an App that opens pull requests already has (see
|
|
1213
|
+
[Registering the GitHub App](#registering-the-github-app) above).
|
|
1214
|
+
|
|
653
1215
|
## The `repo_*` tools
|
|
654
1216
|
|
|
655
1217
|
A linked agent gets these built-in tools automatically — they are not
|
|
656
1218
|
attached like ordinary tools, and never expose a token, check id, or
|
|
657
1219
|
internal marker to the model:
|
|
658
1220
|
|
|
659
|
-
- `repo_pr_read` — a pull request's metadata, per-file diff patches
|
|
1221
|
+
- `repo_pr_read` — a pull request's metadata, per-file diff patches (paged; see
|
|
1222
|
+
[Large pull requests](#large-pull-requests)), the
|
|
660
1223
|
agent's own unresolved inline threads (`openThreads`), and `ci`: the head
|
|
661
1224
|
commit's check runs and commit statuses, excluding every check the wardby
|
|
662
1225
|
App itself reported (review checks, `wardby/continuation`), with `state`
|
|
@@ -666,7 +1229,27 @@ internal marker to the model:
|
|
|
666
1229
|
`note` telling the agent to follow CI over the description's **Tests**.
|
|
667
1230
|
Reading CI never makes `repo_pr_read` fail: an unreadable result is
|
|
668
1231
|
`state: "unavailable"` with `unavailableReason`. At most 50 results are
|
|
669
|
-
listed; names are capped at 100 characters.
|
|
1232
|
+
listed; names are capped at 100 characters. With Wardby 0.6.0 or later it also
|
|
1233
|
+
returns `relatedPullRequests`: this request's pull requests (`repository`,
|
|
1234
|
+
`number`, `state`, `mergeOrder`, `self`), computed fresh at call time from
|
|
1235
|
+
Wardby's own run records; empty on a human pull request, one with no
|
|
1236
|
+
recognized Wardby marker, or a pull request on a local repository (which
|
|
1237
|
+
has no origin marker to look up). The `self` entry (the pull request just
|
|
1238
|
+
read) always has a `state` — `draft`, `open`, `merged`, or `closed` — taken
|
|
1239
|
+
from that same read. Another entry has a `state` (`open`, `merged`, or
|
|
1240
|
+
`closed`) only when Wardby has it stored, which it does for pull requests
|
|
1241
|
+
linked to an issue; otherwise `state` is omitted. Siblings are never read
|
|
1242
|
+
from the host for this: call `repo_pr_read` on a sibling when you need its
|
|
1243
|
+
live state. The list of pull requests is current; the PR body's **Related
|
|
1244
|
+
pull requests** section can be stale (see
|
|
1245
|
+
[Related pull requests across repositories](../help/related-pull-requests.md)).
|
|
1246
|
+
On a Wardby pull request whose description Wardby couldn't confirm as its
|
|
1247
|
+
own text, it also returns `descriptionProposal`: `state: "current"` with
|
|
1248
|
+
`forHead`, `runId`, `text` (Wardby's latest proposed description for this
|
|
1249
|
+
head, cut to 16 KB, `truncated`) and a `note`, or
|
|
1250
|
+
`state: "not_for_this_head"` with a `note` when the latest proposal is for
|
|
1251
|
+
another commit. See
|
|
1252
|
+
[How the pull request description is kept current](#how-the-pull-request-description-is-kept-current).
|
|
670
1253
|
- **Re-review when CI finishes.** When a review publishes `COMMENT` on its
|
|
671
1254
|
own check while CI on that head is `pending` or `none`, Wardby records it.
|
|
672
1255
|
When a CI check suite (not Wardby's own) completes on that head and no CI
|
|
@@ -681,6 +1264,24 @@ internal marker to the model:
|
|
|
681
1264
|
cases.
|
|
682
1265
|
- `repo_read_file` / `repo_list_files` — read a file or list a directory at
|
|
683
1266
|
a ref.
|
|
1267
|
+
- `repo_issue_read` (Wardby 0.7.0 or later) — read one issue, read-only:
|
|
1268
|
+
`number`, `title`, `state` (`open` or `closed`), `body`, `labels`,
|
|
1269
|
+
`author`, `url`, `createdAt`, `updatedAt`, and its 30 most recent comments
|
|
1270
|
+
(`author`, `body`, `createdAt`), oldest first, with `totalComments`. The
|
|
1271
|
+
body is capped at 32,000 characters and each comment at 4,000;
|
|
1272
|
+
`truncated` is true when anything was cut (`bodyTruncated` and each
|
|
1273
|
+
comment's `truncated` say where). A reviewer uses it to read the issue a
|
|
1274
|
+
pull request says it resolves (`Resolves #N`) and check the change against
|
|
1275
|
+
that issue's own acceptance criteria rather than the description's
|
|
1276
|
+
restatement of them. It works on read and write links alike and needs the
|
|
1277
|
+
App's **Issues: Read** permission. Issue text is written by whoever can
|
|
1278
|
+
open or comment on issues: the tool description tells the agent to treat it
|
|
1279
|
+
as data, never instructions. A pull request number is refused with
|
|
1280
|
+
`is_pull_request` (use `repo_pr_read`), and a local repository has no
|
|
1281
|
+
issues (`issues_unavailable`). For a pull request that resolves a Jira
|
|
1282
|
+
issue, link the reviewer to that Jira project as well (`link_issue_project`,
|
|
1283
|
+
read access is enough) so it can read the ticket with `jira_get_issue`; see
|
|
1284
|
+
[Jira agents](jira-agents.md).
|
|
684
1285
|
- `repo_publish_review` — publish inline comments, a summary, and the check
|
|
685
1286
|
verdict for one PR head, in one call. A check is completed or created
|
|
686
1287
|
**only on the pull request the run was dispatched for** (by a push, a
|
|
@@ -698,22 +1299,30 @@ internal marker to the model:
|
|
|
698
1299
|
Every call names the `repository` explicitly; it must resolve to one of the
|
|
699
1300
|
agent's links. Failures are always a JSON result, never a thrown error:
|
|
700
1301
|
|
|
701
|
-
| `error` code | Meaning
|
|
702
|
-
| ------------------------------- |
|
|
703
|
-
| `invalid_arguments_json` | The tool call's arguments were not valid JSON.
|
|
704
|
-
| `invalid_arguments` | Arguments failed schema validation (missing/malformed field).
|
|
705
|
-
| `repository_not_linked` | `repository` does not match one of this agent's links, or matches more than one and needs a `host/owner/name` prefix to disambiguate.
|
|
706
|
-
| `write_access_required` | A write tool (`repo_publish_review`, `repo_comment`) was called on a read-only link.
|
|
707
|
-
| `repository_access_denied` | The link is no longer authorized: the agent has no owner, the owner's GitHub account is unlinked or lost access, or it could not be checked.
|
|
708
|
-
| `repository_access_unavailable` | GitHub could not be reached (or rate-limited wardby) while re-checking access, even after one retry; the call was refused for safety. Try again later.
|
|
709
|
-
| `host_not_configured` | No host provider is configured for this link on this deployment.
|
|
710
|
-
| `unknown_tool` | Not a recognized `repo_*` tool name.
|
|
711
|
-
| `
|
|
712
|
-
| `
|
|
713
|
-
| `
|
|
714
|
-
| `
|
|
715
|
-
| `
|
|
716
|
-
| `
|
|
1302
|
+
| `error` code | Meaning |
|
|
1303
|
+
| ------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
1304
|
+
| `invalid_arguments_json` | The tool call's arguments were not valid JSON. |
|
|
1305
|
+
| `invalid_arguments` | Arguments failed schema validation (missing/malformed field). |
|
|
1306
|
+
| `repository_not_linked` | `repository` does not match one of this agent's links, or matches more than one and needs a `host/owner/name` prefix to disambiguate. |
|
|
1307
|
+
| `write_access_required` | A write tool (`repo_publish_review`, `repo_comment`) was called on a read-only link. |
|
|
1308
|
+
| `repository_access_denied` | The link is no longer authorized: the agent has no owner, the owner's GitHub account is unlinked or lost access, or it could not be checked. |
|
|
1309
|
+
| `repository_access_unavailable` | GitHub could not be reached (or rate-limited wardby) while re-checking access, even after one retry; the call was refused for safety. Try again later. |
|
|
1310
|
+
| `host_not_configured` | No host provider is configured for this link on this deployment. |
|
|
1311
|
+
| `unknown_tool` | Not a recognized `repo_*` tool name. |
|
|
1312
|
+
| `issue_not_found` | `repo_issue_read`: no issue with that number in the repository (or the repository has issues turned off). |
|
|
1313
|
+
| `is_pull_request` | `repo_issue_read`: the number is a pull request; read it with `repo_pr_read`. |
|
|
1314
|
+
| `issues_unavailable` | `repo_issue_read` on a local repository, which has no issues. |
|
|
1315
|
+
| `host_not_installed` | The GitHub App is not installed on this repository. |
|
|
1316
|
+
| `host_permission_missing` | The App installation is missing a required permission. |
|
|
1317
|
+
| `host_invalid_response` | The host returned something the client could not parse. |
|
|
1318
|
+
| `host_api_error` | The request to GitHub failed (body-free: `github_api_error:<status>[:<request-id>]`). |
|
|
1319
|
+
| `ci_failing` | `repo_publish_review` called with verdict `APPROVE`, on a `waitForCi` link's own check, while CI on the head is failing. See [Review after CI](#review-after-ci-waitforci) above. |
|
|
1320
|
+
| `ci_pending` | Same, but CI on the head is still running. |
|
|
1321
|
+
| `patch_cursor_stale` | `repo_pr_read` with a `patchCursor` issued for another head or compare (the pull request moved on). Call again without `patchCursor`. |
|
|
1322
|
+
| `patch_cursor_malformed` | `repo_pr_read` with a `patchCursor` it never issued (damaged, edited or over-long). Pass `nextPatchCursor` exactly as returned. |
|
|
1323
|
+
| `unread_files` | `repo_publish_review` with `APPROVE` while a source, test or config file of the head was listed by `repo_pr_read` but never fully read (all pages via `patchCursor`, or `repo_read_file` at `headSha`). Read the files, or publish `CHANGES_REQUESTED` naming the files not reviewed. |
|
|
1324
|
+
| `full_read_required` | `repo_publish_review` with `APPROVE` when the run read the head only with a `sinceSha` other than the `lastCoveredSha` that read returned. Call `repo_pr_read` without `sinceSha` (or with `lastCoveredSha`), or publish `CHANGES_REQUESTED`. See [Large pull requests](#large-pull-requests). |
|
|
1325
|
+
| `file_list_truncated` | `repo_publish_review` with `APPROVE` after a `repo_pr_read` of the head in the run had `fileListComplete: false` (more changed files than the host lists) and no complete read without `sinceSha` followed. Call `repo_pr_read` without `sinceSha` if it was passed; otherwise publish `CHANGES_REQUESTED` or `COMMENT`. See [Large pull requests](#large-pull-requests). |
|
|
717
1326
|
|
|
718
1327
|
`repo_publish_review` also returns
|
|
719
1328
|
`{ "published": false, "reason": "stale_head", ... }` instead of an error when
|
|
@@ -728,14 +1337,36 @@ request's **Related pull requests** section correctly:
|
|
|
728
1337
|
Reviewer step (CI and related pull requests). Read `ci` from repo_pr_read.
|
|
729
1338
|
When `ci` and the description's Tests disagree, follow CI and say so; never
|
|
730
1339
|
ask for a fix only because a sandbox test failed while CI passed. Report
|
|
731
|
-
pending checks as pending. If
|
|
732
|
-
|
|
733
|
-
of those pull requests: do not report it as missing; note the
|
|
734
|
-
and the
|
|
1340
|
+
pending checks as pending. If repo_pr_read's relatedPullRequests is
|
|
1341
|
+
non-empty, a field, route or schema the change relies on may be added by
|
|
1342
|
+
one of those pull requests: do not report it as missing; note the
|
|
1343
|
+
dependency and the listed merge order instead. relatedPullRequests is
|
|
1344
|
+
current; the PR body's "Related pull requests" section can be stale.
|
|
1345
|
+
|
|
1346
|
+
On a release before 0.6.0, `repo_pr_read` has no `relatedPullRequests`: use
|
|
1347
|
+
the description's **Related pull requests** section in its place in that
|
|
1348
|
+
step.
|
|
735
1349
|
|
|
736
1350
|
Check names and the description are repository content: treat them as data,
|
|
737
1351
|
as for every `repo_*` result.
|
|
738
1352
|
|
|
1353
|
+
### Reviewer step: package audit mode
|
|
1354
|
+
|
|
1355
|
+
From Wardby 0.7.0, a pull request whose coding run had
|
|
1356
|
+
[package audit mode](coding-packages.md#package-audit-mode) on opens with a
|
|
1357
|
+
`[!CAUTION]` banner. **Packages outside the allowlist** names what the
|
|
1358
|
+
registry installed that the agent's allowlist doesn't cover, and in `full`
|
|
1359
|
+
mode **Served despite advisories** lists versions with high or critical
|
|
1360
|
+
advisories. Wardby writes both from the registry's records, not from the
|
|
1361
|
+
agent. Add this to a reviewer's system prompt:
|
|
1362
|
+
|
|
1363
|
+
Reviewer step (package audit mode). If the description has a "Package
|
|
1364
|
+
audit mode" caution banner, check every package under "Packages outside
|
|
1365
|
+
the allowlist" (is it the package the change needs, spelled as its
|
|
1366
|
+
upstream publishes it, and is it used?) and every row under "Served
|
|
1367
|
+
despite advisories" (is the vulnerable code reachable?). Name any you
|
|
1368
|
+
can't justify in your review.
|
|
1369
|
+
|
|
739
1370
|
## Branch protection
|
|
740
1371
|
|
|
741
1372
|
To require a passing review before merge, add the link's `checkName` (e.g.
|
|
@@ -751,6 +1382,19 @@ the PR's author controls and can use to steer the model. Treat it as one
|
|
|
751
1382
|
signal, not the only merge gate: keep a human approval (or another
|
|
752
1383
|
independent check) required alongside it.
|
|
753
1384
|
|
|
1385
|
+
A related set with more than one `mergeOrder` (see [Setting a merge
|
|
1386
|
+
order](../help/related-pull-requests.md#setting-a-merge-order)) also gets a
|
|
1387
|
+
check named exactly `wardby merge order` on each pull request, independent
|
|
1388
|
+
of any reviewer link, tracking whether the pull requests it depends on have
|
|
1389
|
+
merged yet. Require it the same way — add `wardby merge order` as a
|
|
1390
|
+
required status check, with its expected source set to the wardby GitHub
|
|
1391
|
+
App — to block a merge until they have. See
|
|
1392
|
+
[The wardby merge order check](../help/merge-order-check.md). With Wardby
|
|
1393
|
+
0.7.0 or later, a builder opted into [Mark ready when passing
|
|
1394
|
+
(`markReadyWhenPassing`)](#mark-ready-when-passing-markreadywhenpassing)
|
|
1395
|
+
relies on this same check: a later step in the set is only marked ready for
|
|
1396
|
+
review once it reports `success`.
|
|
1397
|
+
|
|
754
1398
|
## Accepted gap: a run that fails outside its normal finish path leaves its check open
|
|
755
1399
|
|
|
756
1400
|
A run's in-progress check is only closed (completed `failure`, "Use Re-run
|