@trim21/personal-pi-extensions 0.0.135 → 0.0.138
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/gh-readonly.ts +14 -5
package/package.json
CHANGED
package/src/gh-readonly.ts
CHANGED
|
@@ -407,11 +407,20 @@ async function getJobLog(
|
|
|
407
407
|
// Not cached, fetch from GitHub
|
|
408
408
|
}
|
|
409
409
|
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
410
|
+
// `gh api` refuses to print responses that contain terminal escape
|
|
411
|
+
// sequences unless `--allow-escape-sequences` is passed. Job logs are a
|
|
412
|
+
// binary zip, so without this flag the download always fails with
|
|
413
|
+
// "the response contains terminal escape sequences; pass
|
|
414
|
+
// --allow-escape-sequences to output it anyway". The ANSI escapes are
|
|
415
|
+
// stripped later by `cleanStepOutput`, so there is no injection surface.
|
|
416
|
+
const log = await ghExec(
|
|
417
|
+
["api", "--allow-escape-sequences", `/repos/${effectiveRepo}/actions/jobs/${jobId}/logs`],
|
|
418
|
+
{
|
|
419
|
+
cwd,
|
|
420
|
+
signal,
|
|
421
|
+
input,
|
|
422
|
+
},
|
|
423
|
+
);
|
|
415
424
|
|
|
416
425
|
// Write to cache
|
|
417
426
|
await mkdir(cacheDir, { recursive: true });
|