Skip to content

Commit b9980d6

Browse files
Trims output length to avoid hitting github 2Mb limitation (game-ci#206)
Co-authored-by: ahub <[email protected]>
1 parent 34809a5 commit b9980d6

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/model/results-check.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,14 @@ const ResultsCheck = {
7676
const pullRequest = github.context.payload.pull_request;
7777
const headSha = (pullRequest && pullRequest.head.sha) || github.context.sha;
7878

79+
const maxLen = 65534;
80+
if(output.length > maxLen)
81+
{
82+
core.warning(`Output too long (${output.length}) truncating to ${maxLen}`);
83+
output = output.substring(0, maxLen);
84+
}
85+
86+
7987
core.info(`Posting results for ${headSha}`);
8088
const createCheckRequest = {
8189
...github.context.repo,

0 commit comments

Comments
 (0)