Trims output length to avoid hitting github 2Mb limitation (#206)
Co-authored-by: ahub <ahub@riseup.net>pull/207/head
parent
34809a534f
commit
b9980d6db7
|
@ -76,6 +76,14 @@ const ResultsCheck = {
|
||||||
const pullRequest = github.context.payload.pull_request;
|
const pullRequest = github.context.payload.pull_request;
|
||||||
const headSha = (pullRequest && pullRequest.head.sha) || github.context.sha;
|
const headSha = (pullRequest && pullRequest.head.sha) || github.context.sha;
|
||||||
|
|
||||||
|
const maxLen = 65534;
|
||||||
|
if(output.length > maxLen)
|
||||||
|
{
|
||||||
|
core.warning(`Output too long (${output.length}) truncating to ${maxLen}`);
|
||||||
|
output = output.substring(0, maxLen);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
core.info(`Posting results for ${headSha}`);
|
core.info(`Posting results for ${headSha}`);
|
||||||
const createCheckRequest = {
|
const createCheckRequest = {
|
||||||
...github.context.repo,
|
...github.context.repo,
|
||||||
|
|
Loading…
Reference in New Issue