@defrex/autobuild 1.1.0 → 1.3.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/README.md +5 -13
- package/SPEC.md +249 -15
- package/bin/ab-dispatch-generation.ts +11 -2
- package/docs/accounts.md +130 -0
- package/docs/agent-runtimes.md +4 -4
- package/docs/answering-blocked-builds.md +4 -1
- package/docs/architecture.md +224 -12
- package/docs/build-store.md +3 -41
- package/docs/builds.md +2 -0
- package/docs/cli.md +14 -0
- package/docs/configuration-overview.md +117 -0
- package/docs/configuration.md +266 -141
- package/docs/dispatcher-hosting.md +18 -33
- package/docs/intake.md +2 -0
- package/docs/integration-tree.md +16 -5
- package/docs/merge-policy.md +1 -3
- package/docs/operating.md +1 -2
- package/docs/operator-api.md +144 -53
- package/docs/operator-surfaces.md +32 -20
- package/docs/overview.md +1 -1
- package/docs/plugin-authoring.md +27 -1
- package/docs/remote-store-protocol.md +259 -91
- package/docs/remote-ticket-protocol.md +29 -49
- package/docs/restacking.md +45 -0
- package/docs/seams.md +8 -8
- package/docs/setup.md +34 -129
- package/docs/spec-standard.md +4 -2
- package/docs/ticket-dependencies.md +8 -0
- package/docs/ticket-sources.md +18 -0
- package/docs/troubleshooting.md +7 -11
- package/docs/upgrading.md +1 -1
- package/docs/workspaces.md +4 -4
- package/package.json +14 -5
- package/packages/core/src/accounts/chatgpt-oauth.ts +216 -0
- package/packages/core/src/accounts/chatgpt-state.ts +41 -0
- package/packages/core/src/accounts/local-credentials.ts +194 -0
- package/packages/core/src/accounts/local-inference.ts +106 -0
- package/packages/core/src/accounts/local-owner.ts +123 -0
- package/packages/core/src/accounts/sensitive.ts +2 -0
- package/packages/core/src/cli/accounts.ts +147 -0
- package/packages/core/src/cli/binary.ts +3 -1
- package/packages/core/src/cli/connect.ts +3 -3
- package/packages/core/src/cli/dispatch-frontend.ts +1 -0
- package/packages/core/src/cli/dispatch-handoff.ts +125 -44
- package/packages/core/src/cli/dispatch-launch-contract.ts +187 -0
- package/packages/core/src/cli/dispatch-launcher.ts +54 -21
- package/packages/core/src/cli/dispatch-preflight.ts +6 -1
- package/packages/core/src/cli/dispatch-repository-feed.ts +107 -26
- package/packages/core/src/cli/dispatch.ts +135 -27
- package/packages/core/src/cli/dispatcher-liveness.ts +6 -1
- package/packages/core/src/cli/forge-clear.ts +30 -0
- package/packages/core/src/cli/help.ts +17 -0
- package/packages/core/src/cli/init-readiness-remote.ts +22 -1
- package/packages/core/src/cli/init-readiness-shared.ts +5 -1
- package/packages/core/src/cli/init-validation.ts +160 -18
- package/packages/core/src/cli/main.ts +72 -0
- package/packages/core/src/cli/publication-settlement.ts +4 -1
- package/packages/core/src/cli/secrets.ts +173 -0
- package/packages/core/src/cli/store-opening.ts +11 -1
- package/packages/core/src/cli/upgrade-agent.ts +9 -1
- package/packages/core/src/cli/watch.ts +12 -14
- package/packages/core/src/config/accounts.ts +101 -0
- package/packages/core/src/config/live.ts +14 -1
- package/packages/core/src/config/roles.ts +54 -3
- package/packages/core/src/config/schema.ts +60 -0
- package/packages/core/src/events/catalog.ts +1 -0
- package/packages/core/src/events/compatibility.ts +2 -1
- package/packages/core/src/events/forge-degradation-policy.ts +11 -0
- package/packages/core/src/events/payloads.ts +13 -0
- package/packages/core/src/events/policy.ts +9 -0
- package/packages/core/src/events/repository.ts +75 -2
- package/packages/core/src/kernel/__snapshots__/reducer-accumulator-shapes.json +278 -0
- package/packages/core/src/kernel/change-presence.ts +74 -8
- package/packages/core/src/kernel/engine.ts +8 -0
- package/packages/core/src/kernel/generators/node-restack-log.ts +14 -0
- package/packages/core/src/kernel/node-polling.ts +40 -7
- package/packages/core/src/kernel/node-restack-demand.ts +74 -0
- package/packages/core/src/kernel/node-restack-state.ts +5 -1
- package/packages/core/src/kernel/node-restack-transaction.ts +33 -1
- package/packages/core/src/kernel/read-facts.ts +6 -0
- package/packages/core/src/kernel/reducer-registry.ts +3 -0
- package/packages/core/src/kernel/reducer.ts +4 -1
- package/packages/core/src/kernel/ticket-preparation.ts +66 -0
- package/packages/core/src/operator/annotations.ts +6 -0
- package/packages/core/src/operator/control.ts +20 -0
- package/packages/core/src/operator/index.ts +4 -0
- package/packages/core/src/operator/protocol.ts +6 -0
- package/packages/core/src/operator/registry.ts +42 -1
- package/packages/core/src/operator/tickets.ts +25 -4
- package/packages/core/src/plugins/manifest.ts +2 -1
- package/packages/core/src/ports/runner/account-env.ts +139 -0
- package/packages/core/src/ports/runner/chatgpt-provider.ts +85 -0
- package/packages/core/src/ports/runner/claude.ts +70 -42
- package/packages/core/src/ports/runner/codex.ts +63 -31
- package/packages/core/src/ports/runner/one-shot.ts +2 -0
- package/packages/core/src/ports/runner/provider-error.ts +5 -0
- package/packages/core/src/ports/runner/routing.ts +35 -4
- package/packages/core/src/ports/tickets/contract.ts +58 -0
- package/packages/core/src/ports/tickets/tree.ts +1 -1
- package/packages/core/src/ports/types.ts +28 -7
- package/packages/core/src/ports/workspace/account-policy.ts +72 -0
- package/packages/core/src/ports/workspace/build-execution.ts +6 -1
- package/packages/core/src/ports/workspace/builtin-capabilities.ts +1 -0
- package/packages/core/src/ports/workspace/create.ts +2 -0
- package/packages/core/src/ports/workspace/git-worktree.ts +6 -1
- package/packages/core/src/ports/workspace/provider-capabilities.ts +1 -0
- package/packages/core/src/ports/workspace/vercel-sandbox.ts +125 -35
- package/packages/core/src/processes/build-runner.ts +32 -1
- package/packages/core/src/processes/dispatcher.ts +493 -121
- package/packages/core/src/processes/execution-no-progress.ts +1 -0
- package/packages/core/src/processes/execution-settlement.ts +21 -3
- package/packages/core/src/processes/harvest-runner.ts +68 -8
- package/packages/core/src/processes/harvest.ts +11 -16
- package/packages/core/src/processes/repo-view.ts +3 -0
- package/packages/core/src/project-secrets.ts +105 -0
- package/packages/core/src/secret-name.ts +41 -0
- package/packages/core/src/store/account-redaction.ts +156 -0
- package/packages/core/src/store/artifact-meta.ts +7 -0
- package/packages/core/src/store/contract.ts +60 -1
- package/packages/core/src/store/memory.ts +4 -0
- package/packages/core/src/store/reducer-value-shapes.json +7389 -6647
- package/packages/core/src/store/reducer-value-validation.ts +106 -6
- package/packages/core/src/store/remote/client.ts +85 -50
- package/packages/core/src/store/remote/compatibility.ts +57 -0
- package/packages/core/src/store/remote/index.ts +6 -0
- package/packages/core/src/store/remote/protocol.ts +8 -1
- package/packages/core/src/store/remote/released-reducer-values/1.2.0.json +8129 -0
- package/packages/core/src/store/remote/version.ts +4 -0
- package/packages/core/src/store/repo-state-events.ts +4 -2
- package/packages/core/src/store/snapshots.ts +16 -3
- package/packages/core/src/store/types.ts +2 -0
- package/packages/core/src/testing/dispatch-read-budget.ts +266 -5
- package/packages/core/src/testing/index.ts +2 -1
- package/packages/core/src/testing/reduced-read-budget.ts +560 -5
- package/skills/guide/SKILL.md +164 -37
- package/skills/guide/references/accounts.md +130 -0
- package/skills/guide/references/integration-tree.md +16 -5
- package/skills/guide/references/merge-policy.md +1 -3
- package/skills/guide/references/operator-api.md +144 -53
- package/skills/guide/references/plugin-authoring.md +27 -1
- package/skills/guide/references/remote-store-protocol.md +259 -91
- package/skills/guide/references/remote-ticket-protocol.md +29 -49
- package/skills/guide/references/restacking.md +45 -0
- package/skills/guide/references/setup.md +34 -129
- package/skills/guide/references/spec-standard.md +4 -2
- package/skills/guide/references/ticket-dependencies.md +8 -0
- package/skills/harvest/SKILL.md +3 -1
- package/skills/harvest-review/SKILL.md +3 -1
- package/skills/operate/SKILL.md +26 -11
- package/skills/reconcile/SKILL.md +6 -0
- package/skills/spec/SKILL.md +1 -1
- package/skills/tickets/SKILL.md +10 -5
- package/templates/hosted-service/package.json +2 -2
- package/docs/hosted-dispatcher-cutover-validation.md +0 -178
- package/docs/hosted-dispatcher.md +0 -278
- package/docs/hosted-service.md +0 -304
- package/docs/mcp.md +0 -150
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# Hosted ticket protocol
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A conforming hosted instance implements this normative remote ticket contract
|
|
4
|
+
for the complete `TicketSource` port without
|
|
4
5
|
exposing backend credentials. It shares the Autobuild and remote protocol
|
|
5
6
|
version headers with the remote BuildStore. The version must be in the
|
|
6
7
|
published service window and the protocol must
|
|
@@ -10,13 +11,12 @@ A service accepts stable and prerelease clients from its own `major.minor`
|
|
|
10
11
|
release line and the two preceding minor lines in the same major. A major starts a new family:
|
|
11
12
|
X.0 accepts only X.0, X.1 accepts X.0/X.1, and X.2 onward accepts three lines.
|
|
12
13
|
Patch versions are interchangeable in both directions and must never change
|
|
13
|
-
the protocol.
|
|
14
|
-
its window. Supported release lines retain their wire handlers and known
|
|
14
|
+
the protocol. Clients must remain within the instance’s published compatibility window. Supported release lines retain their wire handlers and known
|
|
15
15
|
protocol identities; an unknown protocol is refused independently of version.
|
|
16
16
|
Stable and prerelease service and client identities share their numeric major/minor
|
|
17
17
|
line. Malformed or missing identities, build metadata (`+…`), prefixes and
|
|
18
18
|
whitespace are refused with HTTP 409.
|
|
19
|
-
A newer client
|
|
19
|
+
A newer client receives an instance-upgrade diagnostic; a client below the window is
|
|
20
20
|
told to upgrade the project's Autobuild. Diagnostics name the service version
|
|
21
21
|
and supported range.
|
|
22
22
|
|
|
@@ -39,29 +39,28 @@ Project credentials are opaque `abp_1_<id>_<secret>` bearer values bound to one
|
|
|
39
39
|
registered normalized repository. The service stores only a SHA-256 digest of
|
|
40
40
|
the random secret, plus project, creator, creation time, last use, expiry and
|
|
41
41
|
revocation metadata. It checks credential status and project registration on
|
|
42
|
-
every request.
|
|
42
|
+
every request. Registry, grant authentication and adapters share one full
|
|
43
|
+
registration/deletion admission per repository within that request; the next
|
|
44
|
+
request admits afresh. Each mutation transaction checks and locks the admitted
|
|
45
|
+
generation before writing. Deletion invalidates that generation with its initial
|
|
46
|
+
purge, so a later transaction in the same request may be refused atomically;
|
|
47
|
+
earlier committed operations remain committed. Reads need no further admission.
|
|
48
|
+
Revocation takes effect on the next request without affecting
|
|
43
49
|
other credentials. Unknown, expired or revoked credentials receive `401 auth`;
|
|
44
|
-
removed projects receive `403 auth` with `project not registered
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
retired: the service responds that the credential format changed and points
|
|
59
|
-
to `credentials issue`. Supported old protocol shapes still work with a new
|
|
60
|
-
credential; protocol compatibility does not restore retired authentication.
|
|
61
|
-
|
|
62
|
-
`mint admin --ttl-seconds N` creates an explicit versioned, attributed owner
|
|
63
|
-
break-glass credential. It can cross project boundaries. Keep it owner-only:
|
|
64
|
-
never give it or `AB_STORE_SECRET` to a dispatcher or build agent.
|
|
50
|
+
removed projects receive `403 auth` with `project not registered` when the
|
|
51
|
+
repository is established independently. Permanent project deletion removes
|
|
52
|
+
credentials, so old credentials receive `401` unknown or revoked credential,
|
|
53
|
+
including on `/connect/v1/status`, and remain invalid after reconnection.
|
|
54
|
+
See [permanent project deletion](operator-api.md#permanent-project-deletion)
|
|
55
|
+
for purge, retry and generation-bound confirmation semantics.
|
|
56
|
+
|
|
57
|
+
Obtain a project credential with `ab connect <instance-url>` or from the
|
|
58
|
+
instance, and use `AB_TOKEN` on non-interactive clients. Interactive connection
|
|
59
|
+
saves the credential outside the repository. Retired credential formats are
|
|
60
|
+
refused with a credential-format-changed diagnostic; supported old protocol
|
|
61
|
+
shapes still require current credentials. Compatibility does not restore retired
|
|
62
|
+
authentication. Versioned, attributed owner-admin credentials are an explicit
|
|
63
|
+
cross-project exception and must never be supplied to build agents.
|
|
65
64
|
|
|
66
65
|
Hosted tickets, comments, blockers, creation-key deduplication and assets belong
|
|
67
66
|
to exactly one registered project, even when projects use the same team key.
|
|
@@ -133,12 +132,6 @@ MCP ticket surfaces refuse with a message naming that project and source: its
|
|
|
133
132
|
tickets live in its own source, accessed directly by its dispatcher. This is a
|
|
134
133
|
409 conflict, not an empty queue. The dispatcher's direct adapters are unchanged.
|
|
135
134
|
|
|
136
|
-
`AB_TICKET_BACKEND` and `LINEAR_API_KEY` are removed service settings. Their
|
|
137
|
-
presence (even blank or unknown values) is ignored and emits one startup removal
|
|
138
|
-
message. `AB_TICKET_TRIAGE_STATE`, `AB_TICKET_READY_STATE`,
|
|
139
|
-
`AB_TICKET_DOING_STATE` and `AB_TICKET_DONE_STATE` are removed and ignored,
|
|
140
|
-
including malformed values. These retired settings do not prevent startup.
|
|
141
|
-
|
|
142
135
|
## Operations
|
|
143
136
|
|
|
144
137
|
The operation names and `input` values are:
|
|
@@ -173,7 +166,7 @@ lines, or trailing whitespace.
|
|
|
173
166
|
New hosted tickets use `<teamKey>-<n>`, for example `ENG-1`. The effective
|
|
174
167
|
project configuration supplies the literal prefix; the request's `teamKey`
|
|
175
168
|
does not choose it. Numbers start at 1 in each project, increase atomically
|
|
176
|
-
across concurrent creates, and are never reused after deletion. Projects sharing
|
|
169
|
+
across concurrent creates, and are never reused after individual ticket deletion. Permanent project deletion removes the counter; an approved reconnection starts at 1. Projects sharing
|
|
177
170
|
a team key have independent counters. Changing `teamKey` affects only future
|
|
178
171
|
ids and continues the same numbering; existing ids retain their captured prefix.
|
|
179
172
|
|
|
@@ -185,18 +178,6 @@ is `dependency-states`: each result's `id` echoes the requested id for correlati
|
|
|
185
178
|
while its `blockedBy` edges are canonical. Raw historical events and artifacts
|
|
186
179
|
remain unchanged. These rules apply only to hosted tickets, not file or Linear ids.
|
|
187
180
|
|
|
188
|
-
Upgrade the service with its environment-aware migration command before serving
|
|
189
|
-
requests. The transactional migration preserves storage keys and assigns existing
|
|
190
|
-
tickets numbers in `(created_at, id)` order within each project. It first resolves
|
|
191
|
-
legacy team ownership, then reads each populated project's current independent
|
|
192
|
-
ticket policy. Projects without that policy use their selected effective
|
|
193
|
-
configuration through the configured blob backend. Independent-policy projects
|
|
194
|
-
need no uploaded config or blob access. Missing or invalid fallback config,
|
|
195
|
-
missing `teamKey`, or inaccessible required blobs abort the entire migration
|
|
196
|
-
unchanged with a project diagnostic. Restore that config/blob access and rerun;
|
|
197
|
-
an ownership assignment alone cannot supply a readable prefix. Empty projects
|
|
198
|
-
need no config lookup. Re-running a completed migration does not renumber tickets.
|
|
199
|
-
|
|
200
181
|
## Errors and conformance
|
|
201
182
|
|
|
202
183
|
Errors are JSON `{ "error": string, "kind": "validation" | "not-found" |
|
|
@@ -205,10 +186,9 @@ or backend construction. Responses never include exception causes, stacks,
|
|
|
205
186
|
environment values, or credentials. Client 401/403 responses become
|
|
206
187
|
`AuthError`; other backend messages remain actionable.
|
|
207
188
|
|
|
208
|
-
The shared `TicketSource` contract is normative for
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
GraphQL contract; no Linear adapter ships through the hosted ticket entry point.
|
|
189
|
+
The shared `TicketSource` contract is normative for protocol implementations.
|
|
190
|
+
Project partitions must be isolated. The direct Linear client retains its
|
|
191
|
+
separate opt-in GraphQL contract; this protocol does not proxy Linear.
|
|
212
192
|
|
|
213
193
|
Every ticket returned by list, get, or create requires a boolean `resolved`,
|
|
214
194
|
with the same source-native completion semantics as `DependencyState.resolved`.
|
package/docs/restacking.md
CHANGED
|
@@ -47,6 +47,19 @@ actual destination, processing ancestors first. Unrelated siblings stay idle;
|
|
|
47
47
|
changes absent from all ancestors cannot trigger a speculative replay. Tickets
|
|
48
48
|
remain queued until presence is observed in their destination.
|
|
49
49
|
|
|
50
|
+
A presence request whose identities are absent from its immediate parent remains
|
|
51
|
+
pending while ancestors restack or reconcile. A durable availability observation
|
|
52
|
+
allows unchanged idle ticks, including after restart, to skip repository preparation
|
|
53
|
+
and native auto-merge cancellation. Exact node/parent heads, contribution base,
|
|
54
|
+
request contents, accepted ancestry, foreign aliases and confirmed landing evidence
|
|
55
|
+
invalidate that observation when they change; polling timestamps do not. Failed
|
|
56
|
+
assessments never establish unavailability. Availability is not proof of destination
|
|
57
|
+
coverage. Moving to another destination branch explicitly settles obsolete requests
|
|
58
|
+
with `destination-changed`; losing identities on the same branch leaves them waiting.
|
|
59
|
+
Native auto-merge is suspended with confirmed, reusable receipts only when replay
|
|
60
|
+
is actionable, and is revalidated during recovery before rewrite effects.
|
|
61
|
+
|
|
62
|
+
|
|
50
63
|
`ab restack <node>` (operator tool `builds.restack`, input `{repo, slug}`) records
|
|
51
64
|
a durable request, coalescing pending demand. It refuses leaves, terminal nodes,
|
|
52
65
|
and unopened nodes. Paused or blocked nodes wait for their normal safety gates.
|
|
@@ -154,3 +167,35 @@ publication keeps its workspace through backoff and unresolved exhaustion.
|
|
|
154
167
|
Classified rate limits retain repository cooldown and consume no publication
|
|
155
168
|
retry allowance. Rejected pushes, lease conflicts, dirty trees and unclassified
|
|
156
169
|
errors retain their existing behavior.
|
|
170
|
+
|
|
171
|
+
## Ticket preparation before build creation
|
|
172
|
+
|
|
173
|
+
Before claiming, the dispatcher journals a repository-scoped preparation intent;
|
|
174
|
+
a won claim and the exact selected creation slug are durable boundaries. Caught
|
|
175
|
+
asset-copy, spec-authoring, naming, and build-creation failures return the ticket
|
|
176
|
+
to configured Ready; a nonconforming spec goes to configured Triage. Recovery
|
|
177
|
+
checks the exact selected build first: a matching record and atomic
|
|
178
|
+
`build.created` retain ownership even if creation threw after committing.
|
|
179
|
+
Unavailable or conflicting readback never authorizes release or a replacement
|
|
180
|
+
build. Pending attempts retain the original failure, latest recovery error and
|
|
181
|
+
retry deadline in the canonical repository reduced value; resolved attempts
|
|
182
|
+
leave that value. Under repository ownership, each tick admits at most eight
|
|
183
|
+
due recovery attempts, before intake and independently of capacity or intake
|
|
184
|
+
settings, with a 30-second durable retry delay after recovery failure. Unresolved
|
|
185
|
+
ticket identities remain withheld. An uncertain claim outcome or unrelated
|
|
186
|
+
external ticket state, missing ticket/state, or conflicting slug ownership terminates
|
|
187
|
+
automatic recovery with an `abandoned` resolution and diagnostic reason. The
|
|
188
|
+
ticket is left unchanged; an operator can leave it finished or cancelled, or
|
|
189
|
+
inspect ownership and explicitly return it to Ready for another attempt. These
|
|
190
|
+
cases stop provider polling and diagnostic appends. Recovery failures are
|
|
191
|
+
reported without preventing janitor, lease sweep, or other dispatch recovery.
|
|
192
|
+
This is not general process
|
|
193
|
+
crash recovery. Confirmed Ready/Triage transitions settle idempotently, so a
|
|
194
|
+
failed bounce comment does not return an invalid ticket to Ready.
|
|
195
|
+
|
|
196
|
+
Once a build is established, ordinary interrupted-dispatch recovery completes
|
|
197
|
+
its missing boundaries; preparation cleanup cannot release its claim.
|
|
198
|
+
|
|
199
|
+
## Spec revision during leaf reconcile
|
|
200
|
+
|
|
201
|
+
If a leaf spec revision arrives during an unfinished reconcile, the same reconcile attempt resumes under the revised spec on its retained frozen target. Its replay and committed contribution remain owned by reconcile. Confirmed publication must settle before the fresh plan loop opens; prior approvals and verification remain invalidated. The retained transaction and restack identity are reused; no abort or destructive reset is needed.
|
package/docs/seams.md
CHANGED
|
@@ -13,7 +13,7 @@ Adapters supply storage, agent execution, code publication, workspaces and ticke
|
|
|
13
13
|
|
|
14
14
|
## Storage and tickets
|
|
15
15
|
|
|
16
|
-
- **BuildStore.** Local SQLite with filesystem artifacts by default; a
|
|
16
|
+
- **BuildStore.** Local SQLite with filesystem artifacts by default; a remote store implementing the remote BuildStore protocol.
|
|
17
17
|
- **Tickets.** Local files, Linear, or hosted tickets. A hosted Store doesn't require hosted tickets.
|
|
18
18
|
|
|
19
19
|
See [Build store](build-store.md) and [Tickets](ticket-sources.md).
|
|
@@ -32,16 +32,16 @@ Every environment needs the runtime, tools, dependencies and credentials; remote
|
|
|
32
32
|
|
|
33
33
|
| Piece | All local | All remote |
|
|
34
34
|
|---|---|---|
|
|
35
|
-
| Dispatcher | your machine |
|
|
35
|
+
| Dispatcher | your machine | origin-mode CLI on an operator host |
|
|
36
36
|
| Build runners, agents, checks | your machine, in git worktrees | Vercel Sandbox |
|
|
37
|
-
| Store | local SQLite |
|
|
37
|
+
| Store | local SQLite | remote BuildStore protocol |
|
|
38
38
|
| Tickets | file or any other source | a remote ticket source |
|
|
39
39
|
| Forge | local git or GitHub | GitHub |
|
|
40
|
-
| Operator access | terminal dashboard and local CLI |
|
|
40
|
+
| Operator access | terminal dashboard and local CLI | Operator API client |
|
|
41
41
|
|
|
42
42
|
- File tickets and local git make all-local independent of GitHub.
|
|
43
43
|
- The operator agent is external in both.
|
|
44
|
-
- Choosing
|
|
44
|
+
- Choosing a remote Store alone does not move dispatch or build execution off this machine.
|
|
45
45
|
- Mixed deployments work within adapter constraints, e.g. a local dispatcher with a hosted Store and remote sandboxes.
|
|
46
46
|
|
|
47
47
|
See [Dispatcher hosting](dispatcher-hosting.md).
|
|
@@ -60,7 +60,7 @@ See [Dispatcher hosting](dispatcher-hosting.md).
|
|
|
60
60
|
- [Agent runtimes](agent-runtimes.md): Claude Code, Codex, Pi, models.
|
|
61
61
|
- [Workspaces](workspaces.md): git worktree, Vercel Sandbox, provisioning.
|
|
62
62
|
- [Forges](forges.md): GitHub, local git, publication adapters.
|
|
63
|
-
- [Build store](build-store.md): SQLite,
|
|
64
|
-
- [Dispatcher hosting](dispatcher-hosting.md): local
|
|
65
|
-
- [Operator surfaces](operator-surfaces.md): terminal,
|
|
63
|
+
- [Build store](build-store.md): SQLite, remote HTTP, contracts.
|
|
64
|
+
- [Dispatcher hosting](dispatcher-hosting.md): local and origin-mode CLI processes.
|
|
65
|
+
- [Operator surfaces](operator-surfaces.md): terminal, CLI, stdio MCP, Operator API.
|
|
66
66
|
- [Writing a plugin](plugin-authoring.md): modules, contracts, packaging, publishing.
|
package/docs/setup.md
CHANGED
|
@@ -32,7 +32,7 @@ maintainer before selecting it:
|
|
|
32
32
|
- a dispatcher-side push-capable `GITHUB_TOKEN` or `GH_TOKEN`;
|
|
33
33
|
- for a private repository, a separate read-only clone identity named by
|
|
34
34
|
`gitUsernameEnv` and `gitPasswordEnv`;
|
|
35
|
-
-
|
|
35
|
+
- a remote store that speaks the remote BuildStore protocol and is reachable from Vercel, configured through `ab connect <url>`;
|
|
36
36
|
- each selected role and alternate's runtime/model, its pinned
|
|
37
37
|
`[workspace.config.runtimeProvisioning.<runtime>]` commands, and the API
|
|
38
38
|
credential names it needs in `[workspace.config].environmentVariables`.
|
|
@@ -67,8 +67,7 @@ preflight = "test \"$(pi --version)\" = \"0.84.4\" && pi update --models"
|
|
|
67
67
|
```
|
|
68
68
|
|
|
69
69
|
Use a `vercel-ai-gateway/...` Pi model with `AI_GATEWAY_API_KEY` in the
|
|
70
|
-
dispatcher environment.
|
|
71
|
-
runtime auth state, and do not attempt interactive login in a sandbox. Runtime
|
|
70
|
+
dispatcher environment. For Claude Code, configure [accounts](accounts.md) with a manually provisioned `claude setup-token` credential or a Kimi Code membership key; use the unmodified runtime, your own subscription, and ordinary individual usage. ChatGPT subscription accounts use `bun ab accounts login NAME` on your machine with one dispatcher or hosted refresh owner. Pi and ambient Codex login state are not copied, and interactive sandbox login is unsupported. Runtime
|
|
72
71
|
names are open: a plugin runtime uses the same strict map, for example
|
|
73
72
|
`[workspace.config.runtimeProvisioning.opencode]`, with its own immutable
|
|
74
73
|
install and exact-version preflight commands.
|
|
@@ -96,7 +95,10 @@ checkout dependencies in every fresh/replacement sandbox and before the
|
|
|
96
95
|
readiness probe, writes the marker only after success, and reruns every
|
|
97
96
|
preflight before each build runner. A failure names the runtime, selecting
|
|
98
97
|
role/alternate, and field and starts no agent. Runtime provisioning receives
|
|
99
|
-
|
|
98
|
+
allowlisted legacy API credentials named by
|
|
99
|
+
`[workspace.config].environmentVariables` and automatically supplied placeholders
|
|
100
|
+
for every declared account credential variable. Account variables need no
|
|
101
|
+
allowlist entry; their real credentials remain on the dispatcher host.
|
|
100
102
|
|
|
101
103
|
Keep package-level and checkout-level bootstrap in an idempotent
|
|
102
104
|
`[commands].setup`. It runs after system provisioning and must remain safe to
|
|
@@ -156,7 +158,7 @@ to `workspace.config.provisioning` (or a package dependency to setup) while
|
|
|
156
158
|
retaining the universal image; add a runtime credential name to
|
|
157
159
|
`environmentVariables` and its value to the dispatcher environment; correct the
|
|
158
160
|
Vercel team/project credential set; provide separate private-clone credentials;
|
|
159
|
-
use an HTTPS GitHub origin and
|
|
161
|
+
use an HTTPS GitHub origin and remote Store; authorize the Store token; or commit
|
|
160
162
|
and push the selected base branch.
|
|
161
163
|
|
|
162
164
|
## Keep per-build records in separate fragments
|
|
@@ -183,7 +185,7 @@ shared edit surface; the repository owns the release-time assembly tooling.
|
|
|
183
185
|
## Repository identity is the origin, not a checkout path
|
|
184
186
|
|
|
185
187
|
Repository identity in the Store, dispatcher, `ab builds`, `ab build status`,
|
|
186
|
-
`ab repository status
|
|
188
|
+
`ab repository status` is the repository's **normalized origin
|
|
187
189
|
URL** (`https://github.com/owner/repository`), not a checkout's absolute path.
|
|
188
190
|
Two checkouts of the same repository — on different hosts, or a dispatcher and
|
|
189
191
|
its sandboxes — agree on one identity.
|
|
@@ -245,15 +247,14 @@ sources agree with the running system by construction:
|
|
|
245
247
|
runs the dispatcher's own code.
|
|
246
248
|
- **Origin mode** (checkout-less dispatcher): the guest archive is the release
|
|
247
249
|
asset `autobuild-<version>.tgz` fetched from the canonical repository at the
|
|
248
|
-
**running dispatcher's version** (read from the
|
|
250
|
+
**running dispatcher's version** (read from the installed distribution's
|
|
249
251
|
`package.json`), so the guest runs the dispatcher's own release.
|
|
250
252
|
|
|
251
253
|
A service accepts stable and prerelease clients from its own `major.minor`
|
|
252
254
|
release line and the two preceding minor lines in the same major. A major starts a new family:
|
|
253
255
|
X.0 accepts only X.0, X.1 accepts X.0/X.1, and X.2 onward accepts three lines.
|
|
254
256
|
Patch versions are interchangeable in both directions and must never change
|
|
255
|
-
the protocol.
|
|
256
|
-
its window. Supported release lines retain their wire handlers and known
|
|
257
|
+
the protocol. Keep project clients within the instance’s published window. Supported release lines retain their wire handlers and known
|
|
257
258
|
protocol identities; an unknown protocol is refused independently of version.
|
|
258
259
|
Stable and prerelease service and client identities share their numeric major/minor
|
|
259
260
|
line. Malformed or missing identities, build metadata (`+…`), prefixes and
|
|
@@ -274,11 +275,12 @@ It warns and continues when the target is outside the range, naming the
|
|
|
274
275
|
required service upgrade for a newer target or a compatible project range for
|
|
275
276
|
an older one. An unavailable or malformed probe warns that connectivity may
|
|
276
277
|
fail after upgrade. Legacy health without a range means exact-version matching;
|
|
277
|
-
|
|
278
|
+
the hosted instance must publish a compatibility window before clients can
|
|
279
|
+
use release-line compatibility.
|
|
278
280
|
|
|
279
281
|
A distribution fix reaches origin-mode guests after a release is cut and the
|
|
280
282
|
dispatcher is upgraded. Guests continue to run the dispatcher's own version;
|
|
281
|
-
the
|
|
283
|
+
the instance must support that release line.
|
|
282
284
|
|
|
283
285
|
Provisioning records the installed distribution's identity — package version
|
|
284
286
|
and remote-store protocol version — in the guest's
|
|
@@ -305,29 +307,20 @@ perspective:
|
|
|
305
307
|
Local `git-worktree` dispatch keeps working from a checkout exactly as before;
|
|
306
308
|
apart from the identity change, `ab dispatch` behaves as it did.
|
|
307
309
|
|
|
308
|
-
## Hosted deployment variables
|
|
309
|
-
|
|
310
|
-
A hosted-store deployment configures its web/auth variables once — see the
|
|
311
|
-
hosted service README and the complete environment reference in the pinned
|
|
312
|
-
distribution checkout: `BETTER_AUTH_URL`, `AB_WEB_SUPER_USER_EMAILS`,
|
|
313
|
-
and the optional `AB_WEB_MCP_RESOURCE` — the protected
|
|
314
|
-
resource the hosted MCP server (docs/mcp.md) binds its OAuth tokens to,
|
|
315
|
-
defaulting to `<BETTER_AUTH_URL>/mcp`. Set it only when a proxy or custom
|
|
316
|
-
domain fronts the deployment under a different public URL than
|
|
317
|
-
`BETTER_AUTH_URL`; the value must be an absolute http(s) URL (https in
|
|
318
|
-
production) or every MCP client's discovery binds tokens to the wrong
|
|
319
|
-
resource.
|
|
320
|
-
|
|
321
|
-
|
|
322
310
|
## Connect a project
|
|
323
311
|
|
|
324
312
|
From a checkout with an origin remote, run `ab connect https://YOUR_ORIGIN`.
|
|
325
313
|
The CLI prints a verification URL and short code and attempts to open a browser.
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
314
|
+
The code link opens approval directly; if sign-in is needed, it returns there.
|
|
315
|
+
Check the full repository identity and code, and approve or deny. For an
|
|
316
|
+
unassigned project, choose an eligible organization; a sole option is visibly
|
|
317
|
+
selected. Approval requires that destination even for previously registered
|
|
318
|
+
unassigned projects. Assigned projects show their organization as read-only;
|
|
319
|
+
moving them uses project management. With no eligible organization, approval is
|
|
320
|
+
unavailable until a super user creates one. Another device can open the printed
|
|
321
|
+
URL, or visit `/connect` and enter the code. Approval uses the instance’s browser
|
|
322
|
+
consent endpoint. Requests expire after ten minutes. Denial requires no
|
|
323
|
+
organization choice; denial and timeout leave local configuration unchanged.
|
|
331
324
|
|
|
332
325
|
On approval the service registers the project and issues a project credential.
|
|
333
326
|
The CLI keeps it in `$XDG_CONFIG_HOME/autobuild/credentials` (or
|
|
@@ -359,55 +352,6 @@ saved credential for CI and other non-interactive hosts. A service override
|
|
|
359
352
|
never borrows another service's credential. Build and harvest sessions keep
|
|
360
353
|
their explicit scoped authority.
|
|
361
354
|
|
|
362
|
-
## Connected projects
|
|
363
|
-
|
|
364
|
-
Migrate PostgreSQL from the pinned release before deploying (`bun run
|
|
365
|
-
postgres:migrate`). The service keeps an independent, durable project registry;
|
|
366
|
-
existing build or ticket data does not register a project. An administrator
|
|
367
|
-
with deployment database credentials manages it without redeploying:
|
|
368
|
-
|
|
369
|
-
```sh
|
|
370
|
-
ab-hosted-store projects list
|
|
371
|
-
ab-hosted-store projects add https://github.com/owner/project --user owner@example.com
|
|
372
|
-
ab-hosted-store projects remove https://github.com/owner/project --user owner@example.com
|
|
373
|
-
```
|
|
374
|
-
|
|
375
|
-
From a source checkout, substitute `bun packages/hosted-store-service/src/bin.ts`
|
|
376
|
-
for `ab-hosted-store`. Configure `AB_POSTGRES_URL` or `DATABASE_URL` in that
|
|
377
|
-
process. Database possession grants administration; `--user` is declared audit
|
|
378
|
-
attribution, not a verified login. Ordinary project/store tokens cannot manage
|
|
379
|
-
registrations. Each entry records the normalized origin URL, addition time,
|
|
380
|
-
and adding identity. SSH git spellings normalize to HTTPS; local paths and
|
|
381
|
-
credential-bearing HTTPS URLs are rejected. Duplicate adds preserve metadata;
|
|
382
|
-
remove is idempotent, and re-adding records a fresh addition.
|
|
383
|
-
|
|
384
|
-
Super users can operate every registered project. Organization members can
|
|
385
|
-
operate only active projects assigned to their organizations; legacy unassigned
|
|
386
|
-
projects are visible only to super users. Membership is granted by normalized
|
|
387
|
-
email, including before first sign-in, and is rechecked on every request. The dashboard,
|
|
388
|
-
MCP discovery and calls, and every operator API route consult current
|
|
389
|
-
registration. Removal hides a project from all these surfaces and subsequent
|
|
390
|
-
hosted dispatcher invocations; builds, events, artifacts and tickets remain,
|
|
391
|
-
and re-registration restores access. Already-started work is not cancelled.
|
|
392
|
-
Project credentials issued by connect authorize only their registered project. Administrative credential issuance remains available for non-interactive hosts.
|
|
393
|
-
|
|
394
|
-
Link directly to `/?repo=<URL-encoded normalized origin>`. The page selects the
|
|
395
|
-
first registered origin when the requested one is missing or removed, and an
|
|
396
|
-
empty registry shows no project data or controls. Registry errors fail closed;
|
|
397
|
-
there is no environment fallback on database failure.
|
|
398
|
-
|
|
399
|
-
`AB_WEB_REPOSITORIES` is deprecated. A nonempty CSV is imported exactly once per
|
|
400
|
-
database, on the first registry initialization with that variable configured,
|
|
401
|
-
with actor `system:AB_WEB_REPOSITORIES`. The import and durable marker commit
|
|
402
|
-
atomically across concurrent starts. An absent variable does not consume the
|
|
403
|
-
marker. Later restarts or edits to the variable never re-add removed projects;
|
|
404
|
-
use the owner commands for subsequent administration.
|
|
405
|
-
|
|
406
|
-
The hosted dispatcher queries current registrations on every authorized
|
|
407
|
-
invocation. With `AB_DISPATCHER_REPOSITORIES` unset, it serves all registered
|
|
408
|
-
projects; an explicit list preserves its order and is intersected with current
|
|
409
|
-
registration. An empty registry is a successful zero-project invocation.
|
|
410
|
-
|
|
411
355
|
## Authoring an agent verifier
|
|
412
356
|
|
|
413
357
|
A repository-owned agent-verify skill is a verifier, not a reviewer: it drives
|
|
@@ -480,45 +424,8 @@ cannot select another project. See [local builds with hosted tickets](#local-bui
|
|
|
480
424
|
|
|
481
425
|
The service never contacts Linear. Projects with external sources (including
|
|
482
426
|
file and Linear) keep using those sources directly through their dispatcher;
|
|
483
|
-
service ticket HTTP
|
|
484
|
-
feedback rather than returning an empty queue.
|
|
485
|
-
`LINEAR_API_KEY` values are ignored with one startup removal message, including
|
|
486
|
-
blank/unknown values. Removed `AB_TICKET_TRIAGE_STATE`, `AB_TICKET_READY_STATE`,
|
|
487
|
-
`AB_TICKET_DOING_STATE` and `AB_TICKET_DONE_STATE` values are ignored even when
|
|
488
|
-
malformed. None of these retired settings prevents startup.
|
|
489
|
-
|
|
490
|
-
The environment-aware migration imports `AB_WEB_REPOSITORIES` once before
|
|
491
|
-
ownership preflight, including released main-v9 deployments without registry
|
|
492
|
-
tables. A failed migration rolls back the import, main-schema promotion and
|
|
493
|
-
ticket changes together. Owner `projects add` and `tickets assign-team` commands
|
|
494
|
-
bootstrap only the registry/recovery journals and work while the main marker
|
|
495
|
-
is still v9. Without the retired environment, first register the intended
|
|
496
|
-
project with `ab-hosted-store projects add REPOSITORY --user IDENTITY`, then
|
|
497
|
-
assign the team and rerun migration. A successful one-time import is never
|
|
498
|
-
reapplied from later environment edits.
|
|
499
|
-
|
|
500
|
-
Ticket schema v1 migration assigns each whole legacy team to its sole claimant
|
|
501
|
-
among registered projects' latest effective configs, reading their actual blob
|
|
502
|
-
bytes. Projects with no dispatcher run or no effective-config reference make
|
|
503
|
-
no team claim and do not block other projects. Unclaimed teams still fail closed.
|
|
504
|
-
When inferring ownership, a selected configuration whose revision/blob is missing,
|
|
505
|
-
unreadable or invalid stops unchanged with recovery guidance. Restore the selected
|
|
506
|
-
configuration or assign every remaining legacy team explicitly; complete owner
|
|
507
|
-
assignments to registered projects bypass unrelated configuration reads. Conflicts
|
|
508
|
-
and asset ownership mismatches also stop unchanged. Resolve ownership, then rerun:
|
|
509
|
-
|
|
510
|
-
```sh
|
|
511
|
-
ab-hosted-store tickets assign-team TEAM https://github.com/acme/app --user owner@example.com
|
|
512
|
-
ab-postgres-store migrate
|
|
513
|
-
```
|
|
514
|
-
|
|
515
|
-
The assignment journal works before v2 assertion, retains the actor, and grants
|
|
516
|
-
no future cross-project access. Migration preserves ids, states, comments,
|
|
517
|
-
blockers, timestamps and assets. Populated-v1 migration and deployment builds
|
|
518
|
-
require the running service's blob backend, access mode, credentials and prefix
|
|
519
|
-
(`AB_BLOB_PREFIX`), not just PostgreSQL access. `deploy:build` inherits this
|
|
520
|
-
environment and migration failure stops Next build. Fresh databases, empty v1
|
|
521
|
-
queues and v2 reruns stay SQL-only and do not initialize blob storage.
|
|
427
|
+
service ticket HTTP and operator surfaces refuse with project/source
|
|
428
|
+
feedback rather than returning an empty queue.
|
|
522
429
|
|
|
523
430
|
## Local builds with hosted tickets
|
|
524
431
|
|
|
@@ -591,14 +498,12 @@ Follow [ticket migration](ticket-migration.md), keeping the existing BuildStore
|
|
|
591
498
|
and recording continuity before resuming build-related ticket writes.
|
|
592
499
|
|
|
593
500
|
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
and
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
revokes human access on the next request without re-login; existing project
|
|
604
|
-
credentials remain valid until revoked.
|
|
501
|
+
Permanent hosted data removal is available on the web app's Projects page to
|
|
502
|
+
super users and owners of the project's organization. `ab disconnect` only
|
|
503
|
+
revokes a credential; admin `projects remove` only unregisters access and retains
|
|
504
|
+
data. Project deletion removes hosted builds, tickets, blobs, secrets and accounts,
|
|
505
|
+
revokes every credential and retains only a minimal deletion audit. It does not
|
|
506
|
+
change local files or configuration. Failed cleanup is retryable with access
|
|
507
|
+
already refused. Reconnecting requires fresh browser approval and starts empty,
|
|
508
|
+
with hosted ticket numbering reset to 1. See
|
|
509
|
+
[permanent project deletion](operator-api.md#permanent-project-deletion).
|
package/docs/spec-standard.md
CHANGED
|
@@ -131,7 +131,8 @@ The spec is the build's contract artifact (kind `spec`, revision 0).
|
|
|
131
131
|
Every downstream reviewer approves conformance to its pinned revision.
|
|
132
132
|
For leaves, a phase that discovers the spec itself is wrong raises an
|
|
133
133
|
escalation (`ab escalate`); a human answers, the spec gets revision N+1,
|
|
134
|
-
and the leaf restarts from `plan
|
|
134
|
+
and the leaf restarts from `plan` after any unfinished reconcile resumes under
|
|
135
|
+
the revised spec and its publication is confirmed.
|
|
135
136
|
|
|
136
137
|
Operators may explicitly revise an opened idle collecting node or a node blocked on failed
|
|
137
138
|
integration verification without an escalation. Use
|
|
@@ -149,4 +150,5 @@ Active verification/reconcile or writer work, restack/reparent work, pause,
|
|
|
149
150
|
pending controls, merge intent and ended PRs refuse the no-escalation path.
|
|
150
151
|
A concurrent state change refuses publication with a retry explanation;
|
|
151
152
|
uncited artifacts are inert. Leaves still require an open escalation and
|
|
152
|
-
restart from `plan
|
|
153
|
+
restart from `plan` after any unfinished reconcile resumes under the revised
|
|
154
|
+
spec and its publication is confirmed.
|
|
@@ -77,6 +77,14 @@ parent history. An empty completed contribution is satisfied; missing evidence,
|
|
|
77
77
|
an open or aborted node, or ambiguous newest build generations remain queued.
|
|
78
78
|
Older successful generations are never substituted for the newest build.
|
|
79
79
|
|
|
80
|
+
Destination observations retain versioned, head-bound Git witnesses (reachable
|
|
81
|
+
commit SHAs and direct build trailers) and a fixed-length evidence digest. Current
|
|
82
|
+
confirmed landings and aliases from only the destination's accepted ancestry are
|
|
83
|
+
reapplied before reuse. Unrelated merged history and ready destinations do not
|
|
84
|
+
invalidate this proof. Head changes require a fresh Git sample; legacy observations
|
|
85
|
+
without witnesses refresh once rather than replaying repository history. Current
|
|
86
|
+
readiness and newest-generation checks still apply before claim.
|
|
87
|
+
|
|
80
88
|
- Same node: the blocking change merges directly into the target.
|
|
81
89
|
- Ancestor: the change merges into an ancestor, then presence demand restacks only the required path to the target.
|
|
82
90
|
- Sibling: the blocking node merges into their common ancestor, then presence demand reaches the target through the minimal ancestor path.
|
package/docs/ticket-sources.md
CHANGED
|
@@ -130,3 +130,21 @@ bun ab plugin test ticket-source acme
|
|
|
130
130
|
```
|
|
131
131
|
|
|
132
132
|
Declare tree support only if you keep the [optional tree contract](plugin-authoring.md#optional-ticket-tree-capability) on the same port and harness: exhaustive pagination, canonical targets, revision coverage and atomic rejection.
|
|
133
|
+
|
|
134
|
+
Native paging is an optional API 1.9 ticket-source capability:
|
|
135
|
+
`listPage?(criteria: TicketCriteria, page: TicketPage): Promise<TicketPageListing>`.
|
|
136
|
+
The SDK exports these types; the result is `TicketListing & { total: number }`.
|
|
137
|
+
Criteria retain state, labels (AND), and assignee semantics. The page has a
|
|
138
|
+
nonnegative integer `limit`, optional nonnegative integer `offset` (default 0),
|
|
139
|
+
and optional `order: 'oldest' | 'newest'` (default oldest). Newest reverses the
|
|
140
|
+
entire source order before offset and limit. Total counts all matches, even
|
|
141
|
+
with limit zero or an offset past the end. Records, diagnostics and errors
|
|
142
|
+
match the exhaustive listing. The shared `describeTicketSourceContract` suite
|
|
143
|
+
automatically compares declared native paging with full-read windows.
|
|
144
|
+
|
|
145
|
+
Only paged operator listings select this capability. Sources without it retain
|
|
146
|
+
the full-read/reverse/slice fallback; native errors propagate. Unpaged operator
|
|
147
|
+
listings, CLI ticket lists and dispatcher ready scans remain exhaustive through
|
|
148
|
+
`listReady`/`listAll`. The hosted PostgreSQL source counts matches without
|
|
149
|
+
bodies and reads only the SQL-bounded window. File, Linear and the remote
|
|
150
|
+
`HostedTicketSource` retain fallback; the POST list-ready protocol stays exhaustive.
|
package/docs/troubleshooting.md
CHANGED
|
@@ -96,16 +96,12 @@ bun ab builds --queued
|
|
|
96
96
|
|
|
97
97
|
See [answering blocked builds](operating.md#answer-and-pause). Preserve event logs; let the kernel manage leases and recovery.
|
|
98
98
|
|
|
99
|
-
##
|
|
99
|
+
## Remote project access
|
|
100
100
|
|
|
101
|
-
**Symptom.**
|
|
101
|
+
**Symptom.** Remote requests refuse a project despite a configured URL.
|
|
102
102
|
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
- **Dispatcher selection.** `AB_DISPATCHER_REPOSITORIES` in the hosted dispatch environment selects projects: unset selects every active registration; an explicit ordered list is intersected with current registrations.
|
|
109
|
-
- **Dashboard fallback.** With no selection, the dashboard shows the first registered origin.
|
|
110
|
-
|
|
111
|
-
Registry errors fail closed.
|
|
103
|
+
Run `bun ab connect` to check the instance, normalized origin and credential.
|
|
104
|
+
Reconnect on this host/user if credentials are missing or rejected. A project
|
|
105
|
+
must be actively registered with the instance; data alone grants no access.
|
|
106
|
+
If access remains refused, give the instance operator the project identity and
|
|
107
|
+
sanitized error. See the [authentication contract](remote-store-protocol.md#7-authentication-and-project-authority).
|
package/docs/upgrading.md
CHANGED
|
@@ -50,6 +50,6 @@ bun ab dispatch
|
|
|
50
50
|
- **One writer.** Don't run old and new dispatchers at once.
|
|
51
51
|
- **Durable resume.** Work resumes from durable state after a clean stop. Restart doesn't answer escalations.
|
|
52
52
|
- **Old behavior.** Drain old work before switching if it must keep the old execution behavior; no claim-version switch preserves it.
|
|
53
|
-
- **
|
|
53
|
+
- **Remote clients.** Check the instance’s `/health` compatibility window before upgrading connected projects.
|
|
54
54
|
|
|
55
55
|
Read [Infrastructure seams](seams.md) and [Repository configuration](configuration-overview.md) before changing infrastructure or merge policy.
|
package/docs/workspaces.md
CHANGED
|
@@ -47,7 +47,7 @@ Run `bun ab init`, install and authenticate your runtime, then run `bun ab init
|
|
|
47
47
|
|
|
48
48
|
Runs build-runners, agents and checks on remote machines. Install `@defrex/autobuild-vercel-sandbox`, register it in `plugins`, and commit your setup and configuration so remote clones see them. Requires:
|
|
49
49
|
|
|
50
|
-
-
|
|
50
|
+
- a remote store that speaks the remote BuildStore protocol over HTTPS
|
|
51
51
|
- an HTTPS `github.com/owner/repository` origin and `forge = "github"`
|
|
52
52
|
- a push-capable `GITHUB_TOKEN` or `GH_TOKEN` on the dispatcher (a `gh` login isn't enough)
|
|
53
53
|
- `VERCEL_TOKEN`, `VERCEL_TEAM_ID` and `VERCEL_PROJECT_ID` on the dispatcher host
|
|
@@ -110,9 +110,9 @@ Sandbox preparation order:
|
|
|
110
110
|
4. `runtimeProvisioning.<runtime>` installs
|
|
111
111
|
5. `commands.setup`
|
|
112
112
|
|
|
113
|
-
- **Runtimes.** Every primary and alternate runtime needs a pinned install and exact-version preflight, and gets only the credentials named in `environmentVariables
|
|
113
|
+
- **Runtimes.** Every primary and alternate runtime needs a pinned install and exact-version preflight, and gets only the credentials named in `environmentVariables`, except declared [accounts](configuration-overview.md#accounts), whose credentials remain on the host and are brokered by egress policy using guest placeholders.
|
|
114
114
|
- **Repetition.** New sandboxes repeat provisioning and preflights rerun before each build-runner; keep setup idempotent.
|
|
115
|
-
- **Validation.** `bun ab init --validate` runs named provisioning, setup, runtime and Store checks in a disposable environment, deletes it even on failure, and starts no build or agent.
|
|
115
|
+
- **Validation.** `bun ab init --validate` runs named provisioning, setup, runtime and Store checks in a disposable environment, deletes it even on failure, and starts no build. For every declared account, including unused accounts, it runs a tool-free model probe through the account's runtime (Claude Code for Claude/Kimi, Codex for ChatGPT); these probes create no ordinary build phase or persistent agent session. Hosted ChatGPT project secrets report readiness from write-only status metadata instead; the first hosted build is the live check.
|
|
116
116
|
- **Lifetime.** `timeoutSeconds` bounds a sandbox; provider operations have their own timeouts. An intact sandbox resumes; an expired or lost one is rebuilt from durable workspace and publication evidence, losing unpublished work that lived only on it.
|
|
117
117
|
|
|
118
118
|
### Private repositories
|
|
@@ -126,7 +126,7 @@ export AB_GIT_READ_TOKEN='<read-only repository token>'
|
|
|
126
126
|
|
|
127
127
|
- Use a repository-scoped read token, separate from the push identity. For a public clone, remove `gitUsernameEnv` and `gitPasswordEnv`.
|
|
128
128
|
- Autobuild passes these as the authenticated Git source for [Vercel private-repository cloning](https://vercel.com/kb/guide/sandbox-private-github-repositories); don't embed credentials in the origin URL.
|
|
129
|
-
- `environmentVariables`
|
|
129
|
+
- `environmentVariables` forwards legacy runtime API credentials; declared account credentials become placeholders even when listed here. Never forward `AB_TOKEN`, `GITHUB_TOKEN`, `GH_TOKEN`, Vercel tokens or the clone token; Autobuild supplies scoped Store authority, keeps clone secrets out of guest commands, and publishes from the host.
|
|
130
130
|
|
|
131
131
|
## Writing your own
|
|
132
132
|
|