Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@gitulisca
Copy link
Contributor

Why is this change required?

Although we already have a handleLargeSummary function, prior to this change it would return a shorter summary but it would not update the actual core.summary object.

As core.summary was unaltered by that function the finally block in the run function would throw an exception whenever it called core.summary.write() on a core.summary that exceeded the 1024KB maximum Summary size.

summary-size-exceeds-1024k

Testing

  • Updated the code on a fork repository. Built and packaged it.
  • Used the updated action on a workflow triggered for a commit containing 900 npm packages which resulted in a summary larger than 1024K. The updated version handled that commit successfully. The original action version didn't.

@gitulisca gitulisca requested a review from a team as a code owner October 22, 2025 07:12
Copilot AI review requested due to automatic review settings October 22, 2025 07:12
Copy link
Contributor

Copilot AI left a comment

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 a bug where handleLargeSummary would return a shortened summary but fail to update core.summary, causing the finally block to throw an exception when attempting to write a summary exceeding 1024KB.

Key changes:

  • Updates core.summary to contain the shortened summary before returning it
  • Clears the existing buffer and sets it to the shortened summary content to prevent exceeding size limits

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Copy link
Contributor

@ljones140 ljones140 left a comment

Choose a reason for hiding this comment

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

It looks good.
Thanks for the PR.

Can you generate dist and commit so the CI passes?

@ljones140 ljones140 merged commit 8e51299 into actions:main Oct 27, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants