<feed xmlns='http://www.w3.org/2005/Atom'>
<title>aur-build/testcorpus, branch ai/main</title>
<subtitle>Unnamed repository
</subtitle>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/'/>
<entry>
<title>tests: make the blanket `allow(dead_code)` in the test tier worth keeping</title>
<updated>2026-11-21T14:01:34+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-21T14:01:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=47f6c6db7faedc292fb55b6637a5f6e292ffcaec'/>
<id>47f6c6db7faedc292fb55b6637a5f6e292ffcaec</id>
<content type='text'>
`tests/common/mod.rs` opened with `#![allow(dead_code)]` and nothing else, which
means it could have been hiding helpers no test called. It was not hiding many —
`upstream2_commit` and nothing else at file scope — but "not many" is not a
check, and the file cannot simply drop the allowance: it is compiled into every
test binary, so a helper one binary uses is dead code in the other twenty and
the lint fires everywhere and means nothing.

So the allowance stays and the check moves up a level. `the_test_helpers_are_used`
reads the file and fails on any `pub` item no test writes, counting a type as
used when a field or method of it is — `Web::raw_request` hands back a `Raw` no
test ever names. `every_fixture_is_referenced` does the same for `testcorpus/`,
which had one entry, `git-submodules`, that no test had ever driven; it is gone.
Both were checked by planting a dead helper and a dead fixture and watching the
suite refuse them.

`tests/dispatch.rs` also carried a function whose entire body was an
`#[allow(dead_code)]` on `fn unused(_: AtomicBool, _: Config) {}` — the deadest
code in the repository, with its two imports behind it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
`tests/common/mod.rs` opened with `#![allow(dead_code)]` and nothing else, which
means it could have been hiding helpers no test called. It was not hiding many —
`upstream2_commit` and nothing else at file scope — but "not many" is not a
check, and the file cannot simply drop the allowance: it is compiled into every
test binary, so a helper one binary uses is dead code in the other twenty and
the lint fires everywhere and means nothing.

So the allowance stays and the check moves up a level. `the_test_helpers_are_used`
reads the file and fails on any `pub` item no test writes, counting a type as
used when a field or method of it is — `Web::raw_request` hands back a `Raw` no
test ever names. `every_fixture_is_referenced` does the same for `testcorpus/`,
which had one entry, `git-submodules`, that no test had ever driven; it is gone.
Both were checked by planting a dead helper and a dead fixture and watching the
suite refuse them.

`tests/dispatch.rs` also carried a function whose entire body was an
`#[allow(dead_code)]` on `fn unused(_: AtomicBool, _: Config) {}` — the deadest
code in the repository, with its two imports behind it.
</pre>
</div>
</content>
</entry>
<entry>
<title>tests: record the vercmp oracle instead of spawning it 1,089 times</title>
<updated>2026-11-19T19:40:38+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-19T19:40:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=bc4916d4a7de6a60d8b73ed7e3ccc0ec0695d580'/>
<id>bc4916d4a7de6a60d8b73ed7e3ccc0ec0695d580</id>
<content type='text'>
The differential against pacman's vercmp is the suite's second biggest
process cost, and its verdicts are a function of two strings plus the pacman
that produced them. They are recorded in testcorpus/vercmp-oracle.tsv now and
compared in process on every run, antisymmetry of the table included. The live
differential is still there - AUR_LIVE_VERCMP=1 runs it and says so when it is
not run.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The differential against pacman's vercmp is the suite's second biggest
process cost, and its verdicts are a function of two strings plus the pacman
that produced them. They are recorded in testcorpus/vercmp-oracle.tsv now and
compared in process on every run, antisymmetry of the table included. The live
differential is still there - AUR_LIVE_VERCMP=1 runs it and says so when it is
not run.
</pre>
</div>
</content>
</entry>
<entry>
<title>docs: drop the citations the deleted docs left behind</title>
<updated>2026-11-19T18:13:13+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-19T18:13:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=893763060ec01d356ade9f6c011519a7f47a92e9'/>
<id>893763060ec01d356ade9f6c011519a7f47a92e9</id>
<content type='text'>
The §n, I-n, M-n and m-n references survived in string literals the comment
strip never touched: migration SQL comments, assertion messages, runtime error
text, Cargo.toml, a CSS and template note, and one corpus manifest. They named
sections of files that no longer exist, so the prose stays and the citation
goes.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The §n, I-n, M-n and m-n references survived in string literals the comment
strip never touched: migration SQL comments, assertion messages, runtime error
text, Cargo.toml, a CSS and template note, and one corpus manifest. They named
sections of files that no longer exist, so the prose stays and the citation
goes.
</pre>
</div>
</content>
</entry>
<entry>
<title>staleness: blocked builds wait properly, and the review answers §10.3 before you approve</title>
<updated>2026-11-18T09:25:13+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-18T09:25:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=bc543e4182d51917fe6bfa608af2c09c8b578671'/>
<id>bc543e4182d51917fe6bfa608af2c09c8b578671</id>
<content type='text'>
Three real defects, all found while writing the tests that pin §10 down:

- **requeue_blocked requeued everything blocked.** The dispatcher sweeps it
  every pass, so a build waiting on a package that has not arrived was put back
  on the queue, claimed, blocked again, and repeated — a busy loop burning a
  claim and a plan step each tick. It now only requeues a build whose every
  blocking name is actually in the index. The old pipeline test asserted the
  broken behaviour and has been rewritten to assert the correct one.

- **The review page could not warn about missing dependencies, because nothing
  ever computed them.** candidates::set_missing_deps existed and was never
  called; missing deps were discovered at plan time, i.e. after a human had
  already approved. Detection now records them with the same rule the plan step
  uses, so the reviewer sees 'the build will block until these are published'
  before deciding, and the CLI and the page agree because both read the row.

- **The dependents question was unanswered.** §10.3 asks 'approving this marks N
  packages stale'. The review page now says exactly that and names them, from
  the same derivation the Attention page uses.

tests/staleness.rs (6 tests) also pins the claims that were easy to fake:
staleness is derived on read — a schema scan asserts no column anywhere stores
it, and withdrawing a dependency flips a dependent from Outdated to Missing
without a single write to the dependent; a blocked build names its blocker on
Attention and is not counted as a failure; a dependency we stopped publishing
reads as missing rather than outdated.

dep-partner added to the corpus so blocked builds are testable end to end.
149 tests pass, clippy clean.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Three real defects, all found while writing the tests that pin §10 down:

- **requeue_blocked requeued everything blocked.** The dispatcher sweeps it
  every pass, so a build waiting on a package that has not arrived was put back
  on the queue, claimed, blocked again, and repeated — a busy loop burning a
  claim and a plan step each tick. It now only requeues a build whose every
  blocking name is actually in the index. The old pipeline test asserted the
  broken behaviour and has been rewritten to assert the correct one.

- **The review page could not warn about missing dependencies, because nothing
  ever computed them.** candidates::set_missing_deps existed and was never
  called; missing deps were discovered at plan time, i.e. after a human had
  already approved. Detection now records them with the same rule the plan step
  uses, so the reviewer sees 'the build will block until these are published'
  before deciding, and the CLI and the page agree because both read the row.

- **The dependents question was unanswered.** §10.3 asks 'approving this marks N
  packages stale'. The review page now says exactly that and names them, from
  the same derivation the Attention page uses.

tests/staleness.rs (6 tests) also pins the claims that were easy to fake:
staleness is derived on read — a schema scan asserts no column anywhere stores
it, and withdrawing a dependency flips a dependent from Outdated to Missing
without a single write to the dependent; a blocked build names its blocker on
Attention and is not counted as a failure; a dependency we stopped publishing
reads as missing rather than outdated.

dep-partner added to the corpus so blocked builds are testable end to end.
149 tests pass, clippy clean.
</pre>
</div>
</content>
</entry>
<entry>
<title>http: surfaces driven by live state — staleness, downgrades, deps, rebuild (I6)</title>
<updated>2026-11-18T08:23:14+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-18T08:23:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=eefbefed9cbea6b2edef65900fbe6cb6da0b48e4'/>
<id>eefbefed9cbea6b2edef65900fbe6cb6da0b48e4</id>
<content type='text'>
Attention, the package page and the builds page now answer real questions
instead of rendering empty tables:

- Attention lists outdated dependencies derived from the recorded world
  snapshots, naming the dependency that moved, what the artifact was built
  against and what the index holds now; also missing dependencies and
  downgrades (AUR offering a lower version than we serve), which is an
  announcement for a human, not a build request.
- The package page shows depends-on from the recipe we actually serve and
  needed-by from the packages whose recipes name it, plus staleness and the
  aur_commit timeline, each release linking into cgit at that exact commit.
- Builds rows carry the version they are about, in both the live and the
  recently-finished table.
- A manual rebuild reuses the approved source identity and mints no approval
  (I6); the test asserts the approval count is unchanged before and after the
  rebuild runs.
- A paused subscription is not observed at all: detection returns Paused
  without polling, so pausing a broken package stops it opening reviews.
- Staleness stays computed on read (§10.2). Nothing stores a stale flag, so
  nothing can serve a stale lie.

Also: dep-client fixture added for dependency pairs.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Attention, the package page and the builds page now answer real questions
instead of rendering empty tables:

- Attention lists outdated dependencies derived from the recorded world
  snapshots, naming the dependency that moved, what the artifact was built
  against and what the index holds now; also missing dependencies and
  downgrades (AUR offering a lower version than we serve), which is an
  announcement for a human, not a build request.
- The package page shows depends-on from the recipe we actually serve and
  needed-by from the packages whose recipes name it, plus staleness and the
  aur_commit timeline, each release linking into cgit at that exact commit.
- Builds rows carry the version they are about, in both the live and the
  recently-finished table.
- A manual rebuild reuses the approved source identity and mints no approval
  (I6); the test asserts the approval count is unchanged before and after the
  rebuild runs.
- A paused subscription is not observed at all: detection returns Paused
  without polling, so pausing a broken package stops it opening reviews.
- Staleness stays computed on read (§10.2). Nothing stores a stale flag, so
  nothing can serve a stale lie.

Also: dep-client fixture added for dependency pairs.
</pre>
</div>
</content>
</entry>
<entry>
<title>review: advisory risk scoring and non-publishable change handling (§6, §5.3, I11)</title>
<updated>2026-11-18T07:29:07+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-18T07:29:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=04b40812f3366c71bf1c99779f880cc74b7f9efa'/>
<id>04b40812f3366c71bf1c99779f880cc74b7f9efa</id>
<content type='text'>
Every candidate is scored against the recipe the accepted release was
actually built from (release -&gt; candidate -&gt; snapshot), never against
'last seen'. Signals: SKIP on a non-VCS source, a sum changed to SKIP,
new source host, --skippgpcheck, removed validpgpkeys, new makedepends
and fetching build tools (cargo/npm/go/pip), .install scripts, weakened
options, removed checkdepends, pkgrel reset, epoch bump, downgrade, a
diff touching build()/package() bodies rather than metadata, upstream
ranges that touch a build-system file, and first introduction. Advisory
only — there is no auto-approval, so a wrong score costs attention and
never safety (§7.3).

Fixes a fixture bug the new tests exposed: digest-drift and
skip-checksum declared bare paths as sources, which parse as local
recipe files rather than remote downloads, so the drift path never
fired. They now use file:// URLs like a real remote would.

tests/notices.rs: integrity_alert is high severity and leaves no
candidate, pin_drift is informational, recipe drift under a static
version is a warning, SKIP-on-non-VCS is a high risk signal, repeated
polling of one drift is one notice, and an I11 sweep over twelve
fixtures proving a change is never silently dropped.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Every candidate is scored against the recipe the accepted release was
actually built from (release -&gt; candidate -&gt; snapshot), never against
'last seen'. Signals: SKIP on a non-VCS source, a sum changed to SKIP,
new source host, --skippgpcheck, removed validpgpkeys, new makedepends
and fetching build tools (cargo/npm/go/pip), .install scripts, weakened
options, removed checkdepends, pkgrel reset, epoch bump, downgrade, a
diff touching build()/package() bodies rather than metadata, upstream
ranges that touch a build-system file, and first introduction. Advisory
only — there is no auto-approval, so a wrong score costs attention and
never safety (§7.3).

Fixes a fixture bug the new tests exposed: digest-drift and
skip-checksum declared bare paths as sources, which parse as local
recipe files rather than remote downloads, so the drift path never
fired. They now use file:// URLs like a real remote would.

tests/notices.rs: integrity_alert is high severity and leaves no
candidate, pin_drift is informational, recipe drift under a static
version is a warning, SKIP-on-non-VCS is a high risk signal, repeated
polling of one drift is one notice, and an I11 sweep over twelve
fixtures proving a change is never silently dropped.
</pre>
</div>
</content>
</entry>
<entry>
<title>watch: two-stage VCS watcher — ls-remote probe, pkgver() resolution, pin capture (§5.2)</title>
<updated>2026-11-18T07:16:36+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-18T07:16:36+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=0b3cb443e70b46ec61455255c3ddfc2a26997613'/>
<id>0b3cb443e70b46ec61455255c3ddfc2a26997613</id>
<content type='text'>
Stage A probes every VCS source in source=() with git ls-remote,
respecting #commit/#tag/#branch fragments, and returns one UpstreamPin
per source. If the tip set equals the accepted release's pins, nothing
can have changed and Stage B never runs — the common case costs one
round trip per source and no clone. svn/hg have no cheap universal probe,
so they are reported as unprobed and force Stage B rather than being
silently treated as unchanged.

Stage B runs only on movement: it fetches into a persistent vcs_cache
(rather than re-cloning a multi-gigabyte upstream daily), runs makepkg
--vercheck, and captures the pins from the clone it already has. Results
are cached on (pkgbase, recipe_hash, upstream_tip) with a per-pkgbase
cooldown, and a process-wide slot cap bounds concurrent resolutions.
The resolved epoch:pkgver-pkgrel plus the pins go into identity_hash, so
a different commit is a different thing to approve.

Also fixes a misclassification the new path exposed: a VCS source's
digest is its pin, so upstream movement showed up as an integrity_alert.
Integrity events are now restricted to fixed downloads; VCS movement
under a frozen pkgver is pin_drift, as §5.2 specifies.

New fixtures git-multi (two upstreams) and git-tagged (#tag pin). 10
tests in tests/vcs.rs.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Stage A probes every VCS source in source=() with git ls-remote,
respecting #commit/#tag/#branch fragments, and returns one UpstreamPin
per source. If the tip set equals the accepted release's pins, nothing
can have changed and Stage B never runs — the common case costs one
round trip per source and no clone. svn/hg have no cheap universal probe,
so they are reported as unprobed and force Stage B rather than being
silently treated as unchanged.

Stage B runs only on movement: it fetches into a persistent vcs_cache
(rather than re-cloning a multi-gigabyte upstream daily), runs makepkg
--vercheck, and captures the pins from the clone it already has. Results
are cached on (pkgbase, recipe_hash, upstream_tip) with a per-pkgbase
cooldown, and a process-wide slot cap bounds concurrent resolutions.
The resolved epoch:pkgver-pkgrel plus the pins go into identity_hash, so
a different commit is a different thing to approve.

Also fixes a misclassification the new path exposed: a VCS source's
digest is its pin, so upstream movement showed up as an integrity_alert.
Integrity events are now restricted to fixed downloads; VCS movement
under a frozen pkgver is pin_drift, as §5.2 specifies.

New fixtures git-multi (two upstreams) and git-tagged (#tag pin). 10
tests in tests/vcs.rs.
</pre>
</div>
</content>
</entry>
<entry>
<title>test: toolchain shims and the fake-package corpus (§16a)</title>
<updated>2026-11-17T21:30:38+00:00</updated>
<author>
<name>aur-build</name>
<email>aur-build@localhost</email>
</author>
<published>2026-11-17T21:30:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.jnsn.dev/cgit/aur-build/commit/?id=a6f69962e85ccf0f0cfd86f7c85bf0f9a2c8c09e'/>
<id>a6f69962e85ccf0f0cfd86f7c85bf0f9a2c8c09e</id>
<content type='text'>
The harness that makes the rest of this developable. Six real binaries
named exactly like the tools the pipeline shells out to, sharing one
shim module, driven entirely by environment so no production code path
is test-only:

  AUR_SHIM_DIR       where invocations are recorded (jsonl)
  AUR_SHIM_MANIFEST  the fixture manifest to obey
  AUR_SHIM_FAIL      optional tool forced to fail

makechrootpkg emits real .pkg.tar.zst files with .PKGINFO and
.BUILDINFO (the full chroot world, which is why §10.1 filters it),
makepkg answers --printsrcinfo and --vercheck for Stage B, repo-add
rebuilds a gzip'd .db with %FILENAME%/%VERSION%/%SHA256SUM% DESC
entries, gpg writes a detached signature, mkarchroot creates a warm
root. Each one records its invocation so tests assert on what actually
ran.

testcorpus/ holds 17 fixtures, each a PKGBUILD plus a manifest with the
scripted outcome: plain-make, with-patch, install-hooks, skip-checksum,
split-pkgbase, build-fails, check-fails, missing-dep, dep-cycle,
epoch-bump, pkgrel-reset, downgrade, digest-drift, pin-drift,
git-sourced, git-submodules, unresolvable. The harness commits a fixture
into a real git repo standing in for AUR, materialises a local upstream
git repo for VCS fixtures, and swaps payload bytes for the drift cases.

Config.child_env is what puts the shims on PATH for child processes, so
the pipeline runs completely unmodified under test.

Part of P0 (DESIGN.md §17).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The harness that makes the rest of this developable. Six real binaries
named exactly like the tools the pipeline shells out to, sharing one
shim module, driven entirely by environment so no production code path
is test-only:

  AUR_SHIM_DIR       where invocations are recorded (jsonl)
  AUR_SHIM_MANIFEST  the fixture manifest to obey
  AUR_SHIM_FAIL      optional tool forced to fail

makechrootpkg emits real .pkg.tar.zst files with .PKGINFO and
.BUILDINFO (the full chroot world, which is why §10.1 filters it),
makepkg answers --printsrcinfo and --vercheck for Stage B, repo-add
rebuilds a gzip'd .db with %FILENAME%/%VERSION%/%SHA256SUM% DESC
entries, gpg writes a detached signature, mkarchroot creates a warm
root. Each one records its invocation so tests assert on what actually
ran.

testcorpus/ holds 17 fixtures, each a PKGBUILD plus a manifest with the
scripted outcome: plain-make, with-patch, install-hooks, skip-checksum,
split-pkgbase, build-fails, check-fails, missing-dep, dep-cycle,
epoch-bump, pkgrel-reset, downgrade, digest-drift, pin-drift,
git-sourced, git-submodules, unresolvable. The harness commits a fixture
into a real git repo standing in for AUR, materialises a local upstream
git repo for VCS fixtures, and swaps payload bytes for the drift cases.

Config.child_env is what puts the shims on PATH for child processes, so
the pipeline runs completely unmodified under test.

Part of P0 (DESIGN.md §17).
</pre>
</div>
</content>
</entry>
</feed>
