Skip to content

apps dashboard operations and policy

bondiano edited this page Nov 12, 2026 · 1 revision

Operations and policy

Active contributors: Vassiliy Kuzenkov

These screens expose operational state and explicit human decisions: recover an uncertain publication, inspect delivery failures, try a review without publishing, or accept a scoped rule risk. Configuration and policy remain file-based; the dashboard is not a general server-settings editor.

Scope: Admin, Audit, Operations, Playground, Policy, Suggestions and Waivers under web/src/modules/ contain 27 source files, 4 test files, a 14.8% test/source file ratio and 1 unique nonbot author on origin/main. Route pages are excluded; see the counting method.

Queue and publication recovery

web/src/pages/queue/index.vue has a shared repository filter, unresolved publications and a jobs section shown to callers with writer access somewhere. web/src/modules/Operations/queries.ts loads jobs newest first with cursor pagination, but unresolved publications are a nonpaginated query ordered oldest first.

web/src/modules/Operations/ui/JobsTable.vue shows the job kind, linked run and change, job state, attempts/max attempts, next queued attempt or lease deadline, creation time and failure. It prefers a run failure over a job's last error when both exist. Cancellation requires writer access on the row's repository and a run in QUEUED, WAITING_EVIDENCE or RUNNING, using the public Changes action.

web/src/modules/Operations/ui/UnresolvedList.vue shows publications still PUBLISHING or UNCERTAIN, including their slot, attempts, reconciler deadline and last error. Only an UNCERTAIN row with writer access on its repository exposes ReconcileForm.

To authorize recreation:

  1. Open the linked pull request and check whether delivery already happened.
  2. Read the duplicate-comment warning in web/src/modules/Operations/ui/ReconcileForm.vue.
  3. Enter a nonblank reason and choose Create again. The form submits that trimmed reason and a retained idempotency key to /v1/publications/{id}/reconcile.
  4. A successful action invalidates data queries through web/src/modules/Operations/queries.ts; it is not a browser-side declaration that GitHub received the publication.

Recreation is an audited operator decision, not a safe generic “retry everything” button. See server publication and reconciliation for durable outbox behavior. The queue page explains that finished jobs are kept 30 days and run failures remain on their pull requests after that, in web/src/pages/queue/index.vue.

Read-only administration

The Admin navigation link is driven by me.admin, not by a repository maintainer check. crates/sych-app/src/server/admin.rs limits the API view to a maintainer client with access to every repository; a GitHub user's maintain permission does not grant this instance-wide view. See session roles.

web/src/pages/admin/index.vue composes three reads:

View Data shown Source
Connections App/bot identity, allowed repositories, environment, publication/check-run flags, build commit and reviewer pin web/src/modules/Admin/ui/ConnectionCard.vue
Webhook deliveries Received time, connection, event/action, decision and delivery ID; filter by connection/decision and Load more web/src/modules/Admin/ui/DeliveriesTable.vue, web/src/modules/Admin/queries.ts
Effective config Expandable JSON with secret environment-variable names rather than secret values web/src/pages/admin/index.vue, web/src/modules/Admin/queries.ts

The connection card warns when a self-review connection's build and pinned reviewer commit differ. It also shows the last SCM read failure and links to the affected change, plus 30-day webhook decision counts. These are diagnostic reads, not controls for changing the pin or replaying a delivery.

Connections, model profiles, budgets and API clients change in server YAML. Policy changes through a pull request to .sych/. The page states this explicitly in web/src/pages/admin/index.vue; use the configuration reference and server runbook for those changes.

Audit

web/src/pages/audit/index.vue filters recorded actions, supports cursor pagination and links to a CSV export advertised as at most 10,000 newest actions. Its scope is repositories the caller maintains; sign-in records are reserved for an operator of every repository.

web/src/modules/Audit/queries.ts lists filter choices for run requests/cancellation, CI cancellation, feedback, waiver creation/revocation, publication requests/recreate authorization and session start/end. web/src/modules/Audit/ui/AuditTable.vue displays time, actor, action, repository, target and metadata. web/src/modules/Audit/target.ts links run and finding targets to their detail routes, waiver targets to the waiver list and leaves unsupported targets as text.

Use this screen to trace a human action and its recorded reason, not to infer that every internal worker transition is an audit event. The endpoint contract is in the API reference.

Playground

From an OPEN or DRAFT change, a repository maintainer can select default/deep and Try in the playground using web/src/modules/Playground/ui/TryForm.vue. It calls /v1/changes/{id}/playground, retains the key for unchanged options, rotates it for another profile/change or accepted try, and follows the returned run ID.

web/src/pages/playground/index.vue explains the boundary: a try reviews the change as it is now with current policy, publishes nothing, stays out of tracked findings and analytics, and spends from the day's playground budget. This is still a paid review, not a free local simulation.

web/src/modules/Playground/queries.ts reads the 50 newest tries for readable repositories and refreshes only the playground query family after starting one. web/src/modules/Playground/ui/PlaygroundRuns.vue links runs and changes and displays state, coverage and known/unknown usage. The normal run reader marks these results as playground output.

Pinned policy

web/src/pages/policy/index.vue requires a selected repository; web/src/modules/Policy/queries.ts disables the request without one. The screen is a read of the newest run's policy reconstructed at its pinned source, not an editor or a live preview of policy proposed in a pull request.

It displays the run link, trusted ref/commit or engine-default source, rules/config hashes and effective policy JSON. If matches_snapshot is false, it warns that the server configuration or Sych changed and the reconstructed hashes differ from the run's pinned snapshot. Do not silently treat that reconstruction as identical to the historical result. Trusted-policy rules belong in the configuration reference and review flow.

Feedback-derived suggestions

web/src/pages/suggestions/index.vue requires one repository and separates PENDING suggestions from decided entries. The screen describes a server computation over the last 90 days of feedback against current repository policy, without a model.

web/src/modules/Suggestions/ui/SuggestionCard.vue shows the rule/version, evidence counts and linked findings, an exception-path or “not required” kind, and copyable YAML. Clipboard refusal falls back to selecting the visible YAML. Sych does not edit policy for the user:

  1. Review the feedback and proposed YAML.
  2. Apply an appropriate policy change through a repository pull request.
  3. As a maintainer, record Applied, optionally with its pull-request URL, or Dismiss.

web/src/modules/Suggestions/queries.ts posts a decision by repository ID and suggestion fingerprint and invalidates the suggestions family. Marking a suggestion applied records a decision; it does not merge a policy change or disable a rule. The distinction is explicit in web/src/pages/suggestions/index.vue.

Waivers

Waivers are created from a rule-backed finding, not from the list page. web/src/modules/Waivers/ui/WaiverForm.vue requires:

  • At least one nonblank path, submitted as trimmed lines.
  • A rule ID supplied by the finding and a change ID.
  • Nonblank owner and reason.
  • A future local date/time or a nonblank “until” condition. If an expiry is supplied, it must still be in the future even when a condition is also present.

The date/time input is converted to an ISO UTC instant. Submission retains a key for the normalized request body and displays the recorded waiver ID on success. The form says that the next review lowers the risk decision while the assessed rule status stays unchanged; it does not rewrite an old result.

web/src/pages/waivers/index.vue filters by repository and active/expired/revoked state. web/src/modules/Waivers/queries.ts reads the list all at once rather than with cursor pagination.

web/src/modules/Waivers/state.ts derives display state with revoked first, then expired at expires_at <= now, then expiring within seven days. A condition-only waiver never expires automatically in this helper. web/src/modules/Waivers/ui/WaiversTable.vue ticks the display clock every minute and shows rule, paths, reason, owner/author, end conditions and revocation time. Maintainers may revoke nonrevoked entries on their repository, including expired ones.

Create/revoke actions broadly invalidate data queries in web/src/modules/Waivers/queries.ts; a future review uses the updated acceptance state. Waivers remain separate from feedback dismissals and from a tour reader finishing a step.

Key source files

File Modification entry
web/src/pages/queue/index.vue Queue composition and URL filters
web/src/modules/Operations/queries.ts Job/publication reads and reconcile request
web/src/modules/Operations/ui/ReconcileForm.vue Duplicate-risk warning, reason and retry identity
web/src/pages/admin/index.vue Read-only operator page
web/src/modules/Admin/ui/ConnectionCard.vue Pin/build drift and SCM diagnostics
web/src/modules/Audit/queries.ts Recorded-action filter vocabulary
web/src/modules/Audit/target.ts Audit-target navigation
web/src/modules/Playground/ui/TryForm.vue Try options and accepted-run navigation
web/src/pages/policy/index.vue Pinned policy display and mismatch warning
web/src/modules/Suggestions/ui/SuggestionCard.vue YAML, evidence and maintainer decisions
web/src/modules/Waivers/ui/WaiverForm.vue Scope, expiry and acceptance fields
web/src/modules/Waivers/state.ts Time-dependent waiver labels

Tests and safe change points

The scoped tests are web/src/modules/Operations/__tests__/ReconcileForm.spec.ts, web/src/modules/Audit/__tests__/target.spec.ts, web/src/modules/Waivers/__tests__/WaiverForm.spec.ts and web/src/modules/Waivers/__tests__/state.spec.ts. They check trimmed retry identity, audit links, UTC expiry requests and expiry/revocation boundaries.

For a new operator mutation, add a domain query, the matching server authorization/API contract, a clear reason/side-effect disclosure and idempotency tests. For new diagnostics, extend read-only Admin components rather than placing secret values or configuration mutation controls in the browser. Admin, Playground, Policy and Suggestions have no module-local spec files in this revision; see frontend testing boundaries.

Clone this wiki locally