docker / docker/buildx

Always print error in the end of history logs command

Open
#3,132 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area/history
Dominant language
Go
Stars
4.5k
Forks
682
Avg merge
2d 14h
Merged PRs (30d)
29

Description

Sometimes build can fail because of an error that is not directly associated with a build step or before the associated build step ever ran(eg. if the failure happens in cache key computation). That leaves behind state where if you run buildx history inspect you get error information as expected but if you run buildx history logs then there is no obvious build step with failure.

I think we should just print the error information in the end of history logs, the same way as we do for history inspect. It may even make sense to repeat the logs for the failed step because the initial logs for that step may not be at the end of the output.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the buildx history logs and history inspect command entry points and compare how each renders failures. Reproduce a failure outside a build step, such as during cache-key computation, then verify that history logs ends with the error information and, if applicable, the failed-step logs.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.