mirror of
https://github.com/garrytan/gstack.git
synced 2026-11-03 07:18:03 +01:00
v1.92.21.0 ci: blobless clones on the PR and train path, fail-loud history reads (GSTA-203 PR 5) (#3713)
* ci: blobless clones on the PR and train path, fail-loud history reads (GSTA-203 PR 5) Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * changelog: GSTA-203 PR 5 fragment Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix: tree-only merge-base diff in the Version Gate; ls-tree --full-tree in both history readers Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * ci: keep the route and backstop policy reads inline (git and jq only); docs follow Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * fix: base CHANGELOG read in readFragments fails loudly; history readers try git show first Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> * docs: HISTORY_READ_FAILED from gstack-restamp and ship-queue land Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com> --------- Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
fd5fcb4318
commit
c03f185d15
16 files changed
+498
-21
No files matched your search
@@ -2896,6 +2896,34 @@ fetching it cannot create that ref, so pass a branch that exists on `origin`
|
||||
(`git branch -r --list 'origin/*'` lists them). `gstack-pregate` says so in
|
||||
its fix instead of suggesting the fetch.
|
||||
|
||||
<a id="history-read-failed"></a>
|
||||
### `cannot read <path> at <ref>. <cause> (git version <v>). Fix: see docs/troubleshooting.md#history-read-failed (HISTORY_READ_FAILED)`
|
||||
|
||||
**Meaning.** A CI job or a local release tool read a file at an older commit
|
||||
and git could not produce it. The PR and train path jobs (Free Tests' plan, the Version Gate,
|
||||
and E2E Evals' route, screen summary, planner, slices, reruns, bisect and
|
||||
report) check out blobless clones (`filter: blob:none`): every commit and
|
||||
tree is there, but an older file's contents are fetched from GitHub the first
|
||||
time something reads them. When that fetch fails three times (a GitHub outage,
|
||||
a network drop), or the ref does not resolve at all, the read fails here
|
||||
instead of counting as "the file is absent". A file the commit really does not
|
||||
have still reads as absent, as before. No ship policy at the base means no
|
||||
train, and no VERSION means `0.0.0.0`. The route and backstop policy reads (inline
|
||||
in their workflows), `.github/scripts/history-read.sh` (the Version Gate's base
|
||||
`VERSION`) and `lib/history-read.ts` (the Version Gate's train classification)
|
||||
print this line. The Version Gate prints the same code when
|
||||
`git fetch origin <base>` fails three times. `gstack-restamp` and
|
||||
`gstack-ship-queue land` print it too when they cannot read the base branch's
|
||||
CHANGELOG, which they check fragments against (`lib/changelog-fragments.ts`
|
||||
reads it through `lib/history-read.ts`); outside a partial clone they do not
|
||||
retry.
|
||||
|
||||
**Fix.** Rerun the failed job once GitHub is reachable. If it fails the same
|
||||
way on a healthy network, check that the ref exists on `origin` and that the
|
||||
runner's git supports partial clone (`git --version` 2.22 or newer; the eval
|
||||
image asserts it at build time in `.github/docker/Dockerfile.ci`). For a local
|
||||
tool, run `git fetch origin <base>` and rerun it.
|
||||
|
||||
<a id="policy-invalid"></a>
|
||||
### `POLICY_INVALID`
|
||||
|
||||
|
||||
Reference in new issue
Block a user