Commit Graph
1487 Commits
Author SHA1 Message Date
sam b708d7e2d0 fix(webui): cut tutorial and marketing prose from labels, hints, empty states and confirms 2026-10-13 17:37:53 +11:00
sam 48371f3291 fix(archied): load and report EDA playbooks at start instead of at the first dispatch 2026-10-13 17:22:01 +11:00
sam afa6da70ce fix(webui): task page drops filler copy, the unattributed-events note and the New run tooltip 2026-10-13 17:16:25 +11:00
sam e06693ffe3 fix(webui): alerts drop UI-explaining prose and align Dismiss with the title 2026-10-13 17:14:43 +11:00
sam b74f2a0189 fix(config): a task snapshot carries only the model limits its aliases resolve to 2026-10-13 17:07:40 +11:00
sam bbbb527721 feat(webui): finish redesign dashboard task and secret settings 2026-10-13 16:41:35 +11:00
sam 858e99ef4c fix(taskactions): a failed callee cancel no longer leaves the caller's run going
Issue: archie-core-kig5j
2026-10-13 16:22:40 +11:00
sam 91fd383bdb fix(eda): the undispatched-capture batch lists only captures an enabled binding still owes
Issue: archie-core-kfjz1
2026-10-13 16:21:21 +11:00
sam 81e878c2bb fix(postgres): age retention spares captures still waiting to be dispatched
Issue: archie-core-jrh2m
2026-10-13 16:19:12 +11:00
sam dc6db30576 fix(postgres): assign bootstrapped agent identities to the default org on every start
Issue: archie-core-n5yj5
2026-10-13 16:18:19 +11:00
sam 5af4428fc3 fix(controlplane): instance settings are written by the system org only
Issue: archie-core-f5zso
2026-10-13 16:17:38 +11:00
sam 0a96ccddcc fix(controlplane): playbook dispatch resolves and caches per the task's org
Issue: archie-core-5t4z7
2026-10-13 16:16:31 +11:00
sam 84507c1ae2 fix(statestore): an invalid stored policy raises an alert and resolves when it validates
Issue: archie-core-kgxw.16
2026-10-13 16:14:16 +11:00
sam c3933c6628 fix(webui): a source create is authorized against the workspace it names
Issue: archie-core-ed8tw
2026-10-13 16:00:37 +11:00
sam ed5dae1017 fix(webui): channel reload route is authorized as the channel action
Issue: archie-core-4laa1
2026-10-13 15:59:36 +11:00
sam 925dfb8f6f fix(staterpc): an org-scoped caller cannot read or write another org's harness secret
Issue: archie-core-jo15w
2026-10-13 15:58:51 +11:00
sam ac4e4b398a fix(statestore): a restart never resolves a service alert still inside its grace
Issue: archie-core-07lyl
2026-10-13 15:56:23 +11:00
sam 9ea8e2f290 fix(statestore): service-unhealthy grace counts from the last stored report and covers silent services
Issue: archie-core-07lyl
2026-10-13 15:29:29 +11:00
sam 4babf0f887 fix(servicekit): report apply status only for kinds the process re-applies live
Issue: archie-core-mt91
2026-10-13 15:28:43 +11:00
sam a5041f0b24 fix(postgres): clamp event, token and denial limits to int32
Issue: archie-core-g14d
2026-10-13 15:27:36 +11:00
sam 132152f545 fix(daemon): run-time workflow check sees the binding event's signature and address
Issue: archie-core-bmro8
2026-10-13 15:10:31 +11:00
sam 815a151c55 fix(postgres): confine identity writes and GetPrincipal to the caller's org
Issue: archie-core-wkey2
2026-10-13 15:07:48 +11:00
sam c832257fda fix(workflows): callees of a test run inherit the test source 2026-10-13 12:46:48 +11:00
sam d54f4af11e feat(workflows): test-run unsaved drafts and browse workflow version history
A test run pins a validated draft, runs with forge and push writes
suppressed and recorded per step, and is excluded from workflow stats.
The History tab lists revisions that changed a workflow, diffs them as
YAML and on the canvas, restores into the editor, and ties runs to the
revision they used.
2026-10-13 12:27:40 +11:00
sam b391e8a9bf fix(postgres): quote the alert lock key so a NUL cannot reach Postgres text 2026-10-13 03:15:06 +11:00
sam 747a7cbfd7 Feat/operator alerts (#1635)
* feat(state): durable operator alerts owned by the State Store

Alerts dedup on org+kind+subject, resolve themselves when a condition
clears, and are raised, resolved, dismissed and listed through the state
contract. Task transitions raise needs-human and failed alerts in the same
transaction; the store checks service health and prunes closed alerts.
Each raise and resolve queues a webhook delivery whose attempts are kept.

* feat(notify): deliver operator alerts to the webhook; raise config and release alerts

notify.webhook now receives raised and resolved alerts above a severity
threshold with HMAC-signed payloads, bounded retry and every attempt recorded
on the alert. archied raises model alias, provider and credential-binding
alerts from the effective configuration, an update alert from the release
channel, and a credential-rejected alert from the egress resolver. The
dashboard API lists and dismisses the caller's org's alerts.

* feat(ui): alert bell in the top bar and webhook alert settings

The bell lists the org's open alerts by severity with dismiss and a link per
alert, and refreshes from the event stream. The task settings page gains the
webhook severity threshold and signing secret. ui/dist rebuilt.
2026-10-12 03:30:46 +11:00
sam 3960a00f5d Feat/org epic (#1634)
* fix(postgres): scope OpenPRs to the caller's org

A principal-carrying caller read every org's pr_open tasks. The query now
honours the request scope; the daemon's unscoped review scan still sees all
orgs.

Issue: archie-core-kgxw.23

* fix(statestore): serve task logs only to the task's org

ReadTaskLog and StreamTaskLogContent took a task ID and read the file with
no org check. The State Store's task-log reader now confirms the task is
visible under the caller's scope first; unscoped services read as before.

Issue: archie-core-kgxw.24

* fix(postgres): scope ListPolicies to the caller's org

Every org's policy text reached any principal-carrying caller. A scoped read
now sees its own org's policies, plus instance policies when scoped to the
system org. The engines and the lockout guard decide for every org, so they
read the full chain unscoped: the dashboard engine loads without the
request's principal and the guard lifts the caller's scope.

Issue: archie-core-kgxw.25

* fix(postgres): scope identity reads to the caller's org

ListIdentities and GetIdentity (and its alias fallback) returned every
identity to any caller. A caller scoped to an org now sees only that org's
members and assigned agents; the system org and unscoped services still see
the whole instance.

Issue: archie-core-kgxw.26

* fix(postgres): hide instance status from other orgs

ListPresence, ListChannelStatus, ListApplyStatus and GetConfigSnapshot
answered any org principal with instance-wide state. They now return nothing
unless the request is unscoped or scoped to the system org. The dashboard
reads the published config as itself, since its handlers project it for
callers of every org.

Issue: archie-core-kgxw.27

* feat(postgres): assign new agents an org and role at creation

A bot or service account created through the API served no org until the
next State Store boot granted it one. Create now assigns it to the org the
request acts in with the developer role in the same transaction, so it is
authorized immediately.

Issue: archie-core-kgxw.14

* feat(edastore): create event records in a chosen workspace

Sources are created in a workspace of the caller's org, the default one when
none is named; event types and bindings take their source's workspace and
mappings their event type's, the same rule the org backfill applied. The
binding, mapping and event type contracts carry the workspace, the four list
endpoints accept ?workspace=, and the Events page has a workspace selector
that filters every step and picks where a new source goes.

Issue: archie-core-kgxw.11

* feat(webui): authorize a record in its workspace

The API built every access request with no workspace, so workspace
policies and per-workspace roles never applied. A request naming a source,
binding, mapping, event type or task now reads the record's workspace under
the caller's scope and authorizes in it; tasks carry their workspace on the
State Store contract for this.

Issue: archie-core-kgxw.9

* feat(access): expose workspace environment to policies

Policies can test resource.workspace.environment. The workspace attribute
is the workspace entity, which carries its environment; the principal
brings its org's workspaces from the State Store, so the dashboard and the
daemon's run checks describe a resource's workspace without another lookup,
and the daemon now authorizes runs in the task's or binding's workspace.

Issue: archie-core-kgxw.10

* fix(webui): ask read_secret when a source secret is read

Rotating a source's secret returns its value, but the route asked update,
which every developer holds, so no policy could narrow who reads a secret.
It now asks read_secret on the secret, which the shipped roles give admins
and an object policy can narrow further.

Issue: archie-core-kgxw.17

* refactor(org): delete the unused upgrade-incomplete sentinel

Nothing returns org.ErrUpgradeIncomplete: the State Store finishes the org
upgrade before it serves.

Issue: archie-core-kgxw.18
2026-10-12 03:24:04 +11:00
sam 3edbd6b0a7 feat(releaseupdate): transactional self-update through archied (#1633)
archied update install verifies the release zip, checks every binary
reports the release, pulls the agent image by digest, backs up the
database in-process and stages the binaries before handing off to
archied update watchdog in its own process. The watchdog restarts units
in release order, requires archied healthy for 120s and otherwise rolls
back binaries and image policy, restoring the database only when a
migration ran. Boot recovery resumes the frozen watchdog.

Deletes scripts/archie-update-install, scripts/archie-update-watchdog,
the updater's --from-source and --auto, CommandInstaller,
ScriptInstaller and the update-image and update-topology subcommands.
2026-10-12 03:21:02 +11:00
sam af1a5f0b89 Fix/workflow eda audit (#1627)
* fix(webui): accept the merge task action

The action whitelist omitted merge, so the dashboard's Merge button on a
pr_open task was refused with 400 unknown action.

Closes: archie-core-slpoz

* fix(workflow): give each parallel branch its own outputs

Branches shared the task's Outputs map, so concurrent declared-output
writes raced (or were lost when the map started nil). Each branch now
writes a copy; join merges new outputs in branch-name order and refuses
one written by two branches as a second write.

Closes: archie-core-3a7w2

* fix(postgres): dispatch captures oldest first and keep pending ones

ListUndispatchedCaptures ordered newest first and listed captures no
binding can match (failed HMAC), so sustained intake starved older work
and bad signatures held the batch. It is now oldest first and lists only
dispatchable captures. Count retention no longer evicts a capture that
is still pending for an armed binding. The daemon lists only sources
with an enabled workflow, so captures waiting on a disabled one do not
hold the oldest-first batch.

Closes: archie-core-2et4b, archie-core-o0s0z

* fix(ui): refuse renaming a workflow onto an existing id

Saving upserts by id, so editing a workflow's id to another workflow's
id removed the open one and overwrote the other. The editor now refuses
that save and says why.

Closes: archie-core-wpoz8

* fix(workflow): reject unknown step settings at save

Step factories decoded settings with yaml.Node.Decode, which drops keys
it does not know, and settings-less steps ignored settings entirely, so a
misspelt key (readOnly for read_only) saved and silently did nothing.
Every factory now decodes strictly and settings-less steps refuse
settings; ParseDefinition runs the factories, so the save refuses them.

Closes: archie-core-8b5nk

* fix(postgres): keep a stored capture when its prune fails

InsertCapture committed the capture, then returned the prune's error, so
intake answered 500 and a sender without a delivery header retried into
a duplicate capture and a duplicate dispatch. A failed prune is now
logged and the stored capture's id returned.

Closes: archie-core-3miuh

* fix(crondelivery): fail and advance a job no runner can deliver

Router.Run returned nil for a kind with no runner, so the engine reported
a successful run while the schedule never advanced and the job fired on
every tick. The run now fails with the refusal, which the engine reports,
and the schedule advances (a one-shot is removed). The router's own
refusal event is gone with it.

Closes: archie-core-s6ahh

* fix(taskactions): stop the runs of cancelled callees

CancelExecution cancelled a caller's waited-on callees in the store, but
only the caller's run was stopped, so callee containers ran to the end.
CancelExecution now returns the callees it cancelled (nested included)
in place of the step ids nobody read, and every cancelling action stops
their runs too.

Closes: archie-core-9labz

* fix(workflow): treat a zero json.Number as false in when

Task inputs and step results decode numbers as json.Number, which truthy
did not unpack, so when: inputs.count held for a count of 0.

Closes: archie-core-uv270

* fix(webui): read a workflow's runs with a workflow-filtered page

The workflows page and the canvas run picker filtered the newest 100
tasks of every workflow client-side, so on a busy instance a workflow's
older runs were invisible. GET /api/tasks takes a workflow filter, carried
through the State Store's Tasks request to the query, and both views ask
for the selected workflow's runs.

Closes: archie-core-tpiw1

* fix(ui): load the restored workflow into the editor

Restore Defaults saved the shipped definition but left the open draft in
the editor, still marked unsaved, so a later save re-applied it. The
editor now reloads the restored definition.

Closes: archie-core-85e7w
2026-10-12 03:20:00 +11:00
sam 2cef93a59d feat(workflow): shipped workflows run as the instance root 2026-10-12 01:53:55 +11:00
sam f78f2a1629 feat(daemon): run each workflow as its declared identity
Every attempt checks that the identity that started the task and the
identity the workflow declares may both run it, recording a denial for
either. A workflow that declares no identity is refused rather than
running as its starter or the root. A workflow.call callee is started by
its caller's declared identity instead of inheriting the caller's row.
The workflow settings panel marks the identity as required and offers
the agent identities.
2026-10-11 14:49:38 +00:00
sam 1030fdb27b fix(postgres): allocate synthetic issue numbers from a per-repo counter
InsertChatTask and EnqueueCallTask computed MAX(issue_number)+1, so
concurrent inserts in one repository took the same number and the second
failed on the unique key. Both now bump a chat_issue_numbers row, seeded
from the existing maxima, whose row lock serializes allocation.
2026-10-11 14:21:27 +00:00
sam 77837aad2e fix(daemon): claim binding dispatch and enqueue its task atomically
EnqueueBindingTask now takes the capture and claims the ledger row,
inserts the task, stamps its provenance and links the ledger row in one
State Store transaction. A failure anywhere leaves the delivery
undispatched for the next cycle; a replay or concurrent claim is refused
by the ledger's unique index. SetDispatchTask is removed.
2026-10-11 14:19:43 +00:00
sam 531f3c13bd test(postgres): remove database-backed tests and the testcontainers harness 2026-10-12 01:17:02 +11:00
sam 7d1f2d73ea Merge branch 'work/53jc' 2026-10-11 04:11:43 +11:00
sam 6ba2458280 Merge branch 'work/ry4k' 2026-10-11 04:11:43 +11:00
sam 0d78df69a3 fix(prreview): restore the benchmark runner on configured models and public PRs 2026-10-11 04:11:40 +11:00
sam 11ece3b027 fix(gateway): remove the web /restart command that no process could serve 2026-10-11 04:11:37 +11:00
sam 3d625ad29e feat(storepkg): auto-update policy, applied by a State Store ticker 2026-10-11 04:10:53 +11:00
sam 1d95b060fd refactor(servicediscovery): delete unreachable contract and NATS implementation 2026-10-11 04:09:56 +11:00
sam 2ee0b1df45 fix(daemon): bound a package workflow's triggers by its accepted authority 2026-10-11 04:08:02 +11:00
sam 23a96bf015 fix(postgres): number the outcome-posted migration after package updates 2026-10-11 04:04:45 +11:00
sam 386e4b0a92 Merge branch 'work/mt9xo' 2026-10-11 04:03:52 +11:00
sam 07a95e94ec Merge branch 'work/zcg8' 2026-10-11 04:03:52 +11:00
sam eaed88a97b Merge branch 'work/mqti13'
# Conflicts:
#	internal/contracts/state/v1/state.pb.go
2026-10-11 04:03:52 +11:00
sam 2b2f78ccf6 feat(archied): post a chat task's outcome back to its chat 2026-10-11 04:03:30 +11:00
sam 0d5a12bf97 fix(webui): the setup checklist and skill catalogue are system-org only 2026-10-11 04:01:46 +11:00
sam 7ca1896b16 fix(daemon): reown worktrees a killed container left root-owned 2026-10-11 04:01:19 +11:00
sam 79b5e8fc43 fix(telegram): publish /approve, which the router already serves 2026-10-11 03:57:10 +11:00
sam 3a9bb2b487 feat(webui): add a member by provider subject or email
POST /api/orgs/{id}/members binds a person by subject, or by email as a
placeholder. The first sign-in whose provider vouches for that email
claims it: the State Store moves the binding onto the provider's subject
in one statement, so a second account with the same address finds
nothing to claim and later sign-ins rest on the subject alone.
2026-10-11 03:54:49 +11:00