Skip to content

[need #294] status: settle the context a per-attribute restart set pending - #295

Open
Padraic-O-Mhuiris wants to merge 2 commits into
Mic92:mainfrom
Padraic-O-Mhuiris:status-restart-context
Open

Padraic-O-Mhuiris wants to merge 2 commits into
Mic92:mainfrom
Padraic-O-Mhuiris:status-restart-context

Conversation

@Padraic-O-Mhuiris

Copy link
Copy Markdown

Fixes #292. Stacked on #294: both change the loop that settles a commit's stored statuses.

A per-attribute restart posts its attribute's context pending, and nothing settles it:

  • The pending post replaces the stored failure, and a rebuild flips only stored failures, so a rebuild that succeeds leaves the context pending.
  • The restart builds the context with the default checks prefix. In a repository whose nixbot.toml sets another attribute, it posts to a context no build reports under.

A rebuild now settles the attribute contexts a restart set pending as it does stored failures (FailedCommitStatuses becomes UnresolvedCommitStatuses). The restart flips the context its
attribute was posted under, which carries the repository's prefix. An attribute without a failed or pending context gets no context of its own; the gate still goes pending.

Tests: a restart then a successful rebuild settles the context, for the checks and a hydraJobs prefix; the store test covers the query against Postgres. The whole suite passes.

A complete rebuild of a commit posts success, "not part of this build",
to every stored failure it doesn't cover. Those include the commit's
failed nix-build gate and effects, which carry no attribute. A rebuild
that fails again turns the required gate green until its own summary
lands, and a failed effect stays green until it runs again.

Resolve only the stored failures of attributes.

Assisted-By: omp (claude-opus-5-5)
A per-attribute restart posts its attribute's context pending, and
nothing settles it:

- The pending post replaces the stored failure, and a rebuild flips
  only stored failures, so a rebuild that succeeds leaves the context
  pending.
- The restart builds the context with the default `checks` prefix. In
  a repository whose nixbot.toml sets another `attribute`, it posts to
  a context no build reports under.

A rebuild now settles the attribute contexts a restart set pending as
it does stored failures. The restart flips the context its attribute
was posted under, which carries the repository's prefix. An attribute
without a failed or pending context gets no context of its own; the
gate still goes pending.

Assisted-By: omp (claude-opus-5-5)

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

A per-attribute restart leaves the attribute's status pending

1 participant