Skip to content

status: Render cached update info in human-readable output#2047

Draft
cgwalters wants to merge 3 commits intobootc-dev:mainfrom
cgwalters:cached-status
Draft

status: Render cached update info in human-readable output#2047
cgwalters wants to merge 3 commits intobootc-dev:mainfrom
cgwalters:cached-status

Conversation

@cgwalters
Copy link
Collaborator

After running bootc upgrade --check, the registry metadata for a
newer image is cached in ostree commit metadata. The bootc status
command already reads this into the cachedUpdate field and exposes
it in JSON/YAML output, but the human-readable output never displayed
it. This meant users had to parse structured output or re-run
upgrade --check to see available updates.

Render the cached update inline with each deployment entry, showing
version, timestamp, and digest when the cached digest differs from
the currently deployed image.

Relates: https://issues.redhat.com/browse/RHEL-139384

Run update-generated to sync man pages and tmt plans with
current CLI options and test summaries.

Assisted-by: OpenCode (Claude claude-opus-4-6)
Signed-off-by: Colin Walters <walters@verbum.org>
Deduplicate the timestamp formatting code used in human-readable
status output. The format string was inlined with a multi-line
comment explaining it; extract it into a named function.

Assisted-by: OpenCode (Claude claude-opus-4-6)
After running `bootc upgrade --check`, the registry metadata for a
newer image is cached in ostree commit metadata. The `bootc status`
command already reads this into the `cachedUpdate` field and exposes
it in JSON/YAML output, but the human-readable output never displayed
it. This meant users had to parse structured output or re-run
`upgrade --check` to see available updates.

Render the cached update inline with each deployment entry, showing
version, timestamp, and digest when the cached digest differs from
the currently deployed image.

Relates: https://issues.redhat.com/browse/RHEL-139384

Assisted-by: OpenCode (Claude claude-opus-4-6)
@github-actions github-actions bot added the area/documentation Updates to the documentation label Mar 5, 2026
@bootc-bot bootc-bot bot requested a review from gursewak1997 March 5, 2026 00:21
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request enhances the bootc status command to display cached update information, which is populated by bootc upgrade --check. The implementation is well-structured, introducing a new render_cached_update function and a format_timestamp helper. The changes are thoroughly tested with new unit tests and an integration test, covering various scenarios. The unrelated documentation changes to rename --insecure to --allow-missing-verity also improve clarity. Overall, this is a solid improvement to user experience.

@henrywang
Copy link
Collaborator

The OpenSSF Scorecard failure should be fixed by PR bootc-dev/actions#18

@cgwalters cgwalters marked this pull request as draft March 5, 2026 12:29
@cgwalters cgwalters marked this pull request as draft March 5, 2026 12:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/documentation Updates to the documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants