Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Contributors report: split report to work around max body size #1436

Merged
merged 1 commit into from
Apr 23, 2024

Conversation

t-lo
Copy link
Member

@t-lo t-lo commented Apr 22, 2024

The April contributors report action failed with

  Validation Failed: {"resource":"Issue","code":"custom","field":"body","message":"body is too long (maximum is 65536 characters)"}

(https://github.com/flatcar/Flatcar/actions/runs/8776875403)

This is caused by the markdown report being too big.

This change splits the report: Contributions, discussions, advisories, and issues are posted in the iussue summary, and PR stats are posted separately in an issue comment.

Example run of the updated action: https://github.com/flatcar/Flatcar/actions/runs/8786907742
Example report: #1435

The April contributors report action failed with

  Validation Failed: {"resource":"Issue","code":"custom","field":"body","message":"body is too long (maximum is 65536 characters)"}
  (https://github.com/flatcar/Flatcar/actions/runs/8776875403)

This is caused by the markdown report being too big.

This change splits the report: Contributions, discussions, advisories,
and issues are posted in the iussue summary, and PR stats are posted
separately in an issue comment.

Signed-off-by: Thilo Fromm <thilofromm@microsoft.com>
@t-lo t-lo requested a review from a team April 22, 2024 16:16
@@ -287,152 +287,177 @@ jobs:
run: |
set -euo pipefail

echo -e '# Contributions, Discussions, Advisories, and Issues' >> summary_report.md
Copy link
Member

Choose a reason for hiding this comment

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

You probably could have saved yourself from a lot of typing instead of doing:

echo "blabla" >>summary_report.md
echo "ajwaj" >>summary_report.md
echo "more stuff" >>summary_report.md

did:

{
  echo "blabla"
  echo "ajwaj"
  echo "more stuff"
} >>summary_report.md

Copy link
Member Author

Choose a reason for hiding this comment

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

Patches welcome 😉

Copy link
Member Author

Choose a reason for hiding this comment

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

(Or even use { ... } | tee summary_report.md to get the markdown as debug output)

@t-lo t-lo merged commit d2af46a into main Apr 23, 2024
1 check passed
@t-lo t-lo deleted the t-lo/split-contrib-report branch April 23, 2024 16:50
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.

None yet

2 participants