Skip to content

Don't append the build prefix when a line is being continued from a previous log entry - #40947

Merged
Blue (OneBlue) merged 1 commit into
masterfrom
user/oneblue/build-output
Jun 30, 2026
Merged

Blue (OneBlue) merged 1 commit into
masterfrom
user/oneblue/build-output

Conversation

@OneBlue

Copy link
Copy Markdown
Collaborator

Summary of the Pull Request

PR Checklist

This change solves an issue causing the build prefix to be inserted in a middle of a line of a build status is split across two logs entries (which can lead to test failures)

  • Closes: Link to issue #xxx
  • Communication: I've discussed this with core contributors already. If work hasn't been agreed, this work might be rejected
  • Tests: Added/updated if needed and all pass
  • Localization: All end user facing strings can be localized
  • Dev docs: Added/updated if needed
  • Documentation updated: If checked, please file a pull request on our docs repo and link it here: #xxx

Detailed Description of the Pull Request / Additional comments

Validation Steps Performed

Copilot AI review requested due to automatic review settings June 29, 2026 23:04

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes BuildKit progress/log rendering in WSLCSession so the stage/build prefix is not inserted mid-line when a log line is split across multiple JSON log chunks from the same vertex (i.e., when the previous chunk didn’t end with \n).

Changes:

  • Extend the IndentLines() helper to optionally skip prefixing the first line.
  • Track whether the current log chunk is continuing an unterminated line from the same vertex and suppress the first-line prefix in that case.
@OneBlue
Blue (OneBlue) marked this pull request as ready for review June 30, 2026 02:04
@OneBlue
Blue (OneBlue) requested a review from a team as a code owner June 30, 2026 02:04

@dkbennett David Bennett (dkbennett) left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

May want to add an E2E test later for the session logging output validation to ensure it's happening and in the expected format.

@OneBlue
Blue (OneBlue) merged commit 5321612 into master Jun 30, 2026
12 checks passed
@OneBlue
Blue (OneBlue) deleted the user/oneblue/build-output branch June 30, 2026 22:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

3 participants