Skip to content

lib: Route status output through the progress API, deny (e)println! - #1

Closed
cgwalters-bot wants to merge 5 commits into
mainfrom
bot/lib-no-println
Closed

cgwalters-bot wants to merge 5 commits into
mainfrom
bot/lib-no-println

Conversation

@cgwalters-bot

@cgwalters-bot cgwalters-bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Collaborator

Library code that writes straight to stdout/stderr is easy to add and hard to spot in review. It also bypasses --progress-fd, so anything consuming the progress API never sees bootc's status output. This came up in bootc-dev#2449 (comment), where a stray println!() slipped into the composefs pull path ("We may need a blanket ban on (e)println! in crates/lib").

This series sends human-facing status through the progress API, then denies clippy::print_stdout and clippy::print_stderr in bootc-lib.

The progress protocol gets a generic Message event ({"type":"Message","level":"info"|"warning","text":"..."}). ProgressWriter::message() (and its info()/warning() shorthands) prints the text exactly as before, info to stdout and warnings to stderr. If a progress fd is attached, it also sends the event. So output without --progress-fd doesn't change, and ProgressWriter::default() works as a plain printer for commands that don't take the flag. Adding an event type can break consumers that match strictly on type, so the protocol goes to 0.2.0, and the docs now say that unknown event types must be ignored.

To keep each step reviewable and rebase-friendly, the conversion is split into small commits, and each one builds on its own:

  1. lib: write command results (digests, JSON, tables, GC stats) to an explicit stdout writer
  2. lib/fsck: write passing checks to the writer fsck() is given
  3. progress_jsonl: make ProgressWriter usable from sync code (std mutex, blocking writes). Tokio used to set O_NONBLOCK on the fd; this now clears it. The CLI runs a single-threaded runtime, so a --progress-fd reader that stops reading now stalls the whole process. Any writable fd is accepted now, not just a pipe, and the help text says so.
  4. progress_jsonl: add the Message event and message(), bump to 0.2.0, update the schema and docs, and have the booted pushpull-upgrade tmt test check for Message events; the first user is the staging summary
  5. deploy: pull "No changes", prune and fstab status
  6. rollback: ostree and composefs
  7. cli: upgrade, switch (including --mutate-in-place) and edit (upgrade/switch pass their --progress-fd writer)
  8. composefs: update, switch, soft-reboot, usr-overlay
  9. install: keep a ProgressWriter in State, convert install.rs (red warnings keep their highlighting and are also sent as events)
  10. install: the helpers under install/ (block setup, config, completion), and the non-empty target warning of install mount
  11. bootloader
  12. boundimage
  13. image: push and set-unified
  14. task: task descriptions and command lines
  15. lib: deny clippy::print_stdout/print_stderr at the crate root

Only a few direct prints are left, each with a targeted #[expect(..., reason = ...)]: global_init() runs before tracing is set up, journal_send() and the progress writer report that they themselves are failing, the spinner has a plain-text fallback when there's no tty, and medium_visibility_warning() colors its warning for the terminal (and also sends it as an event). Tests are exempt via allow-print-in-tests in clippy.toml.

The ban uses the print_stdout/print_stderr restriction lints, denied by a bootc-lib crate attribute. This scopes it to that crate: the root clippy.toml is shared by the whole workspace, and a crates/lib/clippy.toml would replace the root config rather than extend it. anstream's print macros aren't covered by those lints, so they're listed in disallowed-macros in clippy.toml, and only bootc-lib denies that lint (it's also the only crate using them).

Not in this PR: install (to-disk/to-filesystem/to-existing-root) and rollback still don't take --progress-fd. With this series, adding it only means passing the fd to prepare_install(), or to the writer rollback already creates. Task and the anaconda/ostree completion paths also use a plain printing writer for now, and the output of child processes (e.g. Task commands, bootupctl) still goes straight to the inherited stdout/stderr.

Other possible follow-ups:

  • Harden the progress fd against a stalled reader, e.g. make it non-blocking and drop lossy events on EAGAIN (with a poll or timeout for required ones).
  • Message texts keep existing prefixes like warning: ... and notice: ... so the terminal output stays identical, which means the JSON text can repeat the level. I'd rather not strip them ad hoc. If we want bare text later, message() should add the warning: prefix itself based on the level and send the bare text in the event. notice: is info-level, so that prefix carries its own meaning.

Testing

Rebased onto main b06e0b0 (c47ebf9). The rebase was clean, apart from one real conflict: bootc-dev#2483 added an eprintln! warning to install mount (crates/lib/src/mount.rs), which the new deny rejected. That warning now goes through a ProgressWriter (squashed into the install helpers commit). The experimental-progress-fd.md edit follows the bootc-dev#2508 rename to bootc-experimental-progress-fd.7.md. At c47ebf9, on a 16-core devspace (cgwalters-devspace-36601734885, CentOS Stream 10 base):

  • just validate and just unit-tests (465 passed) passed. validate's clippy run (-A clippy::all, CI's config) warns that the disallowed_macros expectation on medium_visibility_warning() is unfulfilled; that isn't new with the rebase.
  • just test-tmt plan-20-image-pushpull-upgrade passed, including the new check for Message events on the progress fd.

Before the rebase, on a 16-core RHEL 10 devspace:

On a 16-core RHEL 10 devspace:

  • For each commit: cargo check -p bootc-lib --all-targets (no warnings) and cargo test -p bootc-lib --lib.
  • The tmt test change is checked for syntax (nu --ide-check), and the filter logic was run against sample JSONL (passes with a Message event, fails without one). I haven't run it in a VM.
  • At the head: make validate (fmt, cargo test --no-run, --no-default-features checks, clippy with CI's flags, cargo doc with -D warnings), clippy with -D unfulfilled_lint_expectations, and cargo xtask update-generated {direct,from-code} --check. I also added a stray println!() and a stray anstream::eprintln!() to check that clippy rejects them.

Apart from plan-20 above, I haven't run the integration tests (tmt/VM). The terminal output is meant to be byte-for-byte unchanged.

Caveats

  • This touches a lot of crates/lib, mostly one-line println! → prog.info() swaps. Because the commits are split by subsystem, a conflict should only affect one of them.

Generated-by: https://github.com/cgwalters/#llms


Review draft in cgwalters-forge, not upstream yet. This section is removed when the PR is opened upstream.

  • Upstream: bootc-dev/bootc, base main
  • Board item: PVTI_lADOE9oHIs4BlJLczg9kEIg
  • Fork CI: off; the devspace testing described above is this PR's CI, and upstream CI runs once it is opened there

To review:

  • Approve, or comment /promote on a line of its own, to open it upstream, ready for review. Either covers only the commits pushed so far.
  • If upstream requires DCO, approving also signs off: promote adds Signed-off-by: Colin Walters <[email protected]> to the commits lacking it (the bot's and yours; anyone else's only if you ask), with you as committer.
  • Add a /draft line (in the same comment or before) to open it upstream as a draft (/ready undoes that).
  • Close to drop it.
  • Edit the title and description freely: they become the upstream PR's. Review comments are squashed into the commits they concern, with a reply here.

println!() panics if stdout is closed (e.g. a broken pipe when piping
into head), whereas writeln!() lets us propagate the error normally.
These call sites are the actual output of a subcommand (digests, JSON,
tables, GC stats), so an explicit stdout writer is the right thing
anyway.

Prep for denying clippy::print_stdout in crates/lib, see
bootc-dev#2449 (comment)

Generated-by: AI
let reverting = new_spec.boot_order == BootOrder::Default;
if reverting {
println!("notice: Reverting queued rollback state");
cli_status!("notice: Reverting queued rollback state");

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What I'm thinking here is we should try to go all-in on the progress API, so basically we have a generic "message" event or so, then we're drinking our own champagne

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense. Proposed design:

  • Event: add Event::Message { level: Info|Warning, text }, serialized as {"type":"Message","level":"info","text":"..."}. Consumers that match on type strictly will see a new variant. So I'd bump API_VERSION to 0.2.0, regenerate progress-v0.schema.json, and say in experimental-progress-fd.md that unknown types must be ignored.

  • Rendering: ProgressWriter::message(level, text) prints the text exactly as today (info to stdout, warning to stderr, via indicatif's println while pull bars are active). If an fd is attached, it also emits the JSONL event. So non-JSONL output stays the same, and JSONL mode additionally gets the events.

  • Getting a writer to call sites: this is where I'd like your call. Only upgrade, switch and install reset take --progress-fd today, and they cover about 30 of the ~90 cli_status!/cli_warn! sites. The rest are in install/to-disk, bootloader, rollback, baseline, fsck and edit, and many of them are sync, while ProgressWriter::send is async (tokio mutex and pipe). Options:

    • A) Explicit threading (my recommendation; it's the "all-in" version). A prep commit makes ProgressWriter usable from sync code (std mutex, blocking writes; events are tiny and rate-limited). Then &ProgressWriter is passed down, stored in install's State. Commands without --progress-fd pass ProgressWriter::default(), which just prints. It's a larger diff, but it's greppable and has no hidden state.
    • B) A process-global sink, set once in cli.rs after parsing --progress-fd. cli_status! would emit through it. It's a much smaller diff, but it's ambient state, and the macros stay.

    Separately: should install and rollback grow --progress-fd now, or later?

I'll hold until you pick A or B. With A, I'd restructure the commits as follows: make ProgressWriter sync-capable, add Message, convert the call sites, then deny.

Generated-by: https://github.com/cgwalters/#llms

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Option A though let's try to break this up into separate commits that at least compile check, not one big likely to conflict-fest "thread progress writer through everywhere"

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, with option A as 15 small commits. Each one passes cargo check -p bootc-lib --all-targets with no warnings, plus the bootc-lib unit tests, on its own:

  • lib, lib/fsck: the two existing prep commits (command results to an explicit stdout writer)
  • progress_jsonl: make ProgressWriter usable from sync code (std mutex + blocking writes)
  • progress_jsonl: add Event::Message { level, text } and ProgressWriter::message()/info()/warning(). These print the same text as before and also send the event when an fd is attached. The protocol goes to 0.2.0, the schema is regenerated, and the docs say that consumers must ignore unknown event types.
  • one commit each for deploy, rollback, cli (upgrade/switch/edit), composefs, install (writer kept in State), install/* helpers, bootloader, boundimage, image, task
  • lib: deny clippy::print_stdout/print_stderr, with four justified #[expect]s (global_init, journal_send, the progress writer's own error path, the spinner's no-tty fallback)

Output without --progress-fd is unchanged. Commands that don't take the flag use ProgressWriter::default(), which just prints.

For the ban I kept the crate-level restriction lints instead of disallowed-macros, because clippy.toml applies to the whole workspace.

Deferred (not in this PR): --progress-fd for install and rollback. Adding it now only means passing the fd to prepare_install() or to the writer rollback already creates. Task and the anaconda/ostree completion entry points also still use a plain printing writer.

Tested on a 16-core devspace. At the head I ran make validate, clippy with -D unfulfilled_lint_expectations, and cargo xtask update-generated {direct,from-code} --check, and checked that a stray println!() fails clippy. I didn't run tmt/VM tests.

Generated-by: https://github.com/cgwalters/#llms

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pushed a follow-up round (head 973e510b). The changes are squashed into the commits they belong to:

  • sync ProgressWriter: the commit message now says that the CLI runtime is single-threaded, so a --progress-fd reader that stops reading stalls the whole process. It also says that tokio used to set O_NONBLOCK on the shared file description and we now clear it. The pipe check is gone, so the --progress-fd help text now just says "typically the write end of a pipe". The progress tests note that the pipe must not fill up, since the sender and the reader share a thread.
  • Message event: test-image-pushpull-upgrade.nu now filters Message events out before checking events by position, and asserts that at least one Message event is there. I checked it with nu --ide-check and against sample JSONL but haven't run it in a VM.
  • cli: switch --mutate-in-place now uses its --progress-fd writer.
  • install: the ----- separator lines go only to the terminal (stderr) and are no longer sent as warning events.
  • deny: anstream::{print,println,eprint,eprintln} are now in disallowed-macros, and only bootc-lib denies that lint (it's also the only crate using them). medium_visibility_warning has a justified #[expect].
  • PR body: I fixed the reasoning for using crate-level lints (a crates/lib/clippy.toml would replace the root config, not extend it). I also noted that Task/child process output still goes to the inherited stdout, and listed hardening against a stalled reader (EAGAIN/poll) as a possible follow-up. On the prefix question, the recommendation is not to strip prefixes ad hoc: if we want bare text later, message() should add warning: itself based on the level. notice: is info-level, so that prefix carries its own meaning.

I re-ran the checks on a 16-core devspace. Every commit passes cargo check -p bootc-lib --all-targets with no warnings, and the unit tests pass (271 passed, 1 ignored). At the head, these all pass: make validate, clippy with CI's flags plus -D unfulfilled_lint_expectations, update-generated {direct,from-code} --check and cargo fmt --check. A stray println!() or anstream::eprintln!() fails clippy.

Generated-by: https://github.com/cgwalters/#llms

Status output must reach progress-fd consumers, including from synchronous code. Add Message events and bump the protocol to 0.2.0; blocking writes can stall the single-threaded runtime if a reader stops draining.

Generated-by: AI
Upgrade and switch status should reach their progress-fd consumers. Route deployment, rollback and composefs status through ProgressWriter while keeping terminal output unchanged.

Generated-by: AI
Keep install status off direct stdout/stderr prints and ready for progress-fd support. Carry the writer in install State and pass it to installation, bootloader and bound-image helpers.

Generated-by: AI
Direct library prints bypass progress consumers and are easy to miss in review. Convert the remaining image and task status, then deny the print lints with targeted exceptions for initialization and output infrastructure.

Generated-by: AI
@cgwalters-bot cgwalters-bot changed the title lib: Deny println!/eprintln! in bootc-lib via clippy lib: Route status output through the progress API, deny (e)println! Sep 23, 2026
cgwalters-bot added a commit that referenced this pull request Sep 25, 2026
The Boot Loader Specification reserves `+` in entry file names for boot
counting, so an os-release version like `1.2.3+42` gave an entry that
systemd-boot treats as having 42 boot attempts left, and counts down.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Sep 25, 2026
systemd-boot puts entries whose boot counter has run out after all
others, whatever their sort-key, so after a new deployment fails to boot
the previous one becomes the default. Mirror that when ordering Type #1
entries, so that `bootc status` reports the failed deployment as the
rollback rather than claiming a rollback is queued when it isn't, and
`bootc rollback` swaps the entries the bootloader actually uses.

Prep for enabling boot counting for new deployments.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Sep 26, 2026
The composefs backend always wrote systemd-boot's Type #1 entries,
kernels and UKIs to the ESP, even when the disk had an XBOOTLDR
partition. Per the Boot Loader Specification, XBOOTLDR is $BOOT when it
exists, and it's how a system with a small ESP (e.g. one shared with
another OS) gets room for several deployments. An unused XBOOTLDR also
gets in the way at runtime: systemd-gpt-auto-generator mounts it on
/boot, which is why image-builder now drops it for UKI images. Once
bootc installs with the container's own repart.d definitions, a
container that asks for XBOOTLDR should get one that's used.

So when there's an XBOOTLDR partition next to the ESP, put the entries,
kernels and UKIs there, keeping only systemd-boot and loader.conf on the
ESP. systemd-boot reads XBOOTLDR through the firmware, which in practice
means FAT, so another filesystem is ignored with a warning. GRUB is
unchanged.

On a booted system XBOOTLDR is only used if it has the booted
deployment's entry, so existing systems that have an unused XBOOTLDR
(for example from an older image-builder layout) keep using the ESP.
With XBOOTLDR, bootc no longer mounts the ESP at runtime at all.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Sep 29, 2026
The Boot Loader Specification reserves `+` in entry file names for boot
counting, so an os-release version like `1.2.3+42` gave an entry that
systemd-boot treats as having 42 boot attempts left, and counts down.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Sep 29, 2026
systemd-boot puts entries whose boot counter has run out after all
others, whatever their sort-key, so after a new deployment fails to boot
the previous one becomes the default. Mirror that when ordering Type #1
entries, so that `bootc status` reports the failed deployment as the
rollback rather than claiming a rollback is queued when it isn't, and
`bootc rollback` swaps the entries the bootloader actually uses.

Prep for enabling boot counting for new deployments.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Sep 29, 2026
The composefs backend always wrote systemd-boot's Type #1 entries,
kernels and UKIs to the ESP, even when the disk had an XBOOTLDR
partition. Per the Boot Loader Specification, XBOOTLDR is $BOOT when it
exists, and it's how a system with a small ESP (e.g. one shared with
another OS) gets room for several deployments. An unused XBOOTLDR also
gets in the way at runtime: systemd-gpt-auto-generator mounts it on
/boot, which is why image-builder now drops it for UKI images. Once
bootc installs with the container's own repart.d definitions, a
container that asks for XBOOTLDR should get one that's used.

So when there's an XBOOTLDR partition next to the ESP, put the entries,
kernels and UKIs there, keeping only systemd-boot and loader.conf on the
ESP. systemd-boot reads XBOOTLDR through the firmware, which in practice
means FAT, so another filesystem is ignored with a warning. GRUB is
unchanged.

On a booted system XBOOTLDR is only used if it has the booted
deployment's entry, so existing systems that have an unused XBOOTLDR
(for example from an older image-builder layout) keep using the ESP.
With XBOOTLDR, bootc no longer mounts the ESP at runtime at all.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Oct 17, 2026
The Boot Loader Specification reserves `+` in entry file names for boot
counting, so an os-release version like `1.2.3+42` gave an entry that
systemd-boot treats as having 42 boot attempts left, and counts down.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Oct 17, 2026
systemd-boot puts entries whose boot counter has run out after all
others, whatever their sort-key, so after a new deployment fails to boot
the previous one becomes the default. Mirror that when ordering Type #1
entries, so that `bootc status` reports the failed deployment as the
rollback rather than claiming a rollback is queued when it isn't, and
`bootc rollback` swaps the entries the bootloader actually uses.

Prep for enabling boot counting for new deployments.

Generated-by: AI
@cgwalters-bot

cgwalters-bot commented Oct 31, 2026 •

Copy link
Copy Markdown
Collaborator Author

@cgwalters-bot

cgwalters-bot commented Oct 31, 2026 •

Copy link
Copy Markdown
Collaborator Author

✅ dispatch ended well. Result: #1

@cgwalters-bot cgwalters-bot added the needs-human The poll stopped here; a person decides what is next label Oct 31, 2026
@cgwalters-bot

Copy link
Copy Markdown
Collaborator Author

The poll stopped following this pull request: a draft with no checkpoint; mark it ready if the work is complete. It is labelled needs-human; remove the label to have the poll start again on it, with fresh fix rounds.

Generated-by: https://github.com/cgwalters/#llms

cgwalters-bot added a commit that referenced this pull request Oct 31, 2026
The Boot Loader Specification reserves `+` in entry file names for boot
counting, so an os-release version like `1.2.3+42` gave an entry that
systemd-boot treats as having 42 boot attempts left, and counts down.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Oct 31, 2026
systemd-boot puts entries whose boot counter has run out after all
others, whatever their sort-key, so after a new deployment fails to boot
the previous one becomes the default. Mirror that when ordering Type #1
entries, so that `bootc status` reports the failed deployment as the
rollback rather than claiming a rollback is queued when it isn't, and
`bootc rollback` swaps the entries the bootloader actually uses.

Prep for enabling boot counting for new deployments.

Generated-by: AI
@cgwalters-bot

Copy link
Copy Markdown
Collaborator Author

Closing as superseded: #63 is the rebased continuation of this series. The ranking that found this is cgwalters-forge/tracker#1177.

Generated-by: https://github.com/cgwalters/#llms

cgwalters-bot pushed a commit to cgwalters-bot/review that referenced this pull request Nov 5, 2026
Part of cgwalters-forge#244

I rendered Needs you at cgwalters-forge#233 (94b73c0), before and after each of cgwalters-forge#231, cgwalters-forge#236, cgwalters-forge#237, cgwalters-forge#238 and cgwalters-forge#242, and with this change, all against the same data at 1280px and 390px: the redacted 3 Nov capture, the 661 publication fixture, and that fixture plus a #680 promote group. No newer live publication was readable (bot-ops#1 returns 404). cgwalters-forge#231 and cgwalters-forge#236 change nothing visible. The regressions:

- cgwalters-forge#237 (58a247f) gave every card a second fold, "Published decision context", next to Context. Its contents now go in the single Context fold.
- cgwalters-forge#237 drew an inventory identity without details as an Answer card with a red "descriptors could not be read safely" box. It is now a two-line read-only row, "Act · Detail not published".
- cgwalters-forge#237 also dropped the epic chips. cgwalters-forge#238 already restored them, and on this data the order and counts match cgwalters-forge#232.
- cgwalters-forge#242 (cc71322, 4a8d672) drew Previous/Next member buttons and quick/deep/unknown/deep headings on every promote group before anything was read. It then moved members under those headings as they were read, and printed each member's evidence as a paragraph with two 40-character heads. Members are back to one line each, in the pass's order. The bucket is now a label on the row, and the evidence is one short line, which says when it was assessed at a different head.

The counts were honest at every step ("Hidden: N by the pass's cap, M by the epic filter").

This run can only hand back text, so the screenshots aren't attached. `test/e2e/render-needs-you.ts` reproduces them for any commit:

```
git worktree add /tmp/before 4a8d672 && ln -s "$PWD/node_modules" /tmp/before/
node test/e2e/render-needs-you.ts /tmp/before group /tmp/before.html cgwalters-forge/bootc#1
chromium --headless --screenshot=/tmp/before.png --window-size=390,2400 file:///tmp/before.html
```

Verified with `npm run check` (1857 tests, typecheck, build). The new replay test in needsyou.test.ts fails on main and on cgwalters-forge#238 (run through REPLAY_ENTRY) and passes here.

Not changed, because cgwalters-forge#233 already looked the same: on desktop, Approve rows leave a gap under the button because Chat gets its own grid row. Long asks also wrap to many lines on phones, by design ("never clipped").

Review: one pass, no blockers. I fixed its important finding (stale evidence read as current) and two nits; that delta was not reviewed again. Still open: the "no group writes" sentence shows only when members can't be inspected in place, as before cgwalters-forge#242.

Generated-by: https://github.com/cgwalters/#llms
cgwalters-bot pushed a commit to cgwalters-forge/review that referenced this pull request Nov 5, 2026
Part of #244

I rendered Needs you at #233 (94b73c0), before and after each of #231, #236, #237, #238 and #242, and with this change, all against the same data at 1280px and 390px: the redacted 3 Nov capture, the 661 publication fixture, and that fixture plus a #680 promote group. No newer live publication was readable (bot-ops#1 returns 404). #231 and #236 change nothing visible. The regressions:

- #237 (58a247f) gave every card a second fold, "Published decision context", next to Context. Its contents now go in the single Context fold.
- #237 drew an inventory identity without details as an Answer card with a red "descriptors could not be read safely" box. It is now a two-line read-only row, "Act · Detail not published".
- #237 also dropped the epic chips. #238 already restored them, and on this data the order and counts match #232.
- #242 (cc71322, 4a8d672) drew Previous/Next member buttons and quick/deep/unknown/deep headings on every promote group before anything was read. It then moved members under those headings as they were read, and printed each member's evidence as a paragraph with two 40-character heads. Members are back to one line each, in the pass's order. The bucket is now a label on the row, and the evidence is one short line, which says when it was assessed at a different head.

The counts were honest at every step ("Hidden: N by the pass's cap, M by the epic filter").

This run can only hand back text, so the screenshots aren't attached. `test/e2e/render-needs-you.ts` reproduces them for any commit:

```
git worktree add /tmp/before 4a8d672 && ln -s "$PWD/node_modules" /tmp/before/
node test/e2e/render-needs-you.ts /tmp/before group /tmp/before.html cgwalters-forge/bootc#1
chromium --headless --screenshot=/tmp/before.png --window-size=390,2400 file:///tmp/before.html
```

Verified with `npm run check` (1857 tests, typecheck, build). The new replay test in needsyou.test.ts fails on main and on #238 (run through REPLAY_ENTRY) and passes here.

Not changed, because #233 already looked the same: on desktop, Approve rows leave a gap under the button because Chat gets its own grid row. Long asks also wrap to many lines on phones, by design ("never clipped").

Review: one pass, no blockers. I fixed its important finding (stale evidence read as current) and two nits; that delta was not reviewed again. Still open: the "no group writes" sentence shows only when members can't be inspected in place, as before #242.

Generated-by: https://github.com/cgwalters/#llms
cgwalters-bot pushed a commit that referenced this pull request Nov 17, 2026
The Boot Loader Specification lets systemd-boot read Type #1 entries
and UKIs from an Extended Boot Loader Partition (XBOOTLDR) on the
ESP's disk. The composefs backend always wrote them to the ESP, which
doesn't work when the ESP is small. That's the usual case next to
Windows: its ESP is often 100 MB, a UKI with a full initramfs can be
bigger than that, and composefs keeps the booted, staged and rollback
ones side by side.

For bootloaders that read entries the way BLS describes, which for
now is only systemd-boot, install the UKIs, BLS entries and their
kernels and initramfs images to a VFAT XBOOTLDR partition next to the
ESP when there is one. The bootloader and loader.conf, which
systemd-boot only reads from the ESP, stay there.

When booted, BootedStorage, which upgrades, rollback, finalize and GC
go through, uses the XBOOTLDR partition next to the ESP named by
LoaderDevicePartUUID only if it holds the booted deployment's entries,
and the ESP otherwise. That way systems installed by an older bootc,
or before an XBOOTLDR partition was added, keep their entries on the
ESP.

GRUB keeps its own /boot handling, and grub-cc is left alone since
it's unclear whether it reads XBOOTLDR.

The new tmt test splits the VM's ESP in half with an empty XBOOTLDR
partition, and checks that a switch keeps the entries on the ESP. It
then moves them to the XBOOTLDR partition, as an install there would
have put them, and upgrades and rolls back. Sealed runs skip it, since
the derived images are built in the VM without keys to sign them.

Assisted-by: AI
Signed-off-by: Kristof Imeri <[email protected]>
cgwalters-bot added a commit that referenced this pull request Dec 2, 2026
The Boot Loader Specification reserves `+` in entry file names for boot
counting, so an os-release version like `1.2.3+42` gave an entry that
systemd-boot treats as having 42 boot attempts left, and counts down.

Generated-by: AI
cgwalters-bot added a commit that referenced this pull request Dec 2, 2026
systemd-boot puts entries whose boot counter has run out after all
others, whatever their sort-key, so after a new deployment fails to boot
the previous one becomes the default. Mirror that when ordering Type #1
entries, so that `bootc status` reports the failed deployment as the
rollback rather than claiming a rollback is queued when it isn't, and
`bootc rollback` swaps the entries the bootloader actually uses.

Prep for enabling boot counting for new deployments.

Generated-by: AI
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/documentation area/install needs-human The poll stopped here; a person decides what is next

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants