[Bug]: TIA replays a fetched baseline without the reachability check, so an unreachable SHA passes with no tests run
I maintainer di solito rispondono entro 5 giorni
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 30/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- git, github-actions, php
- Ambito
- testing-qa
Direzione di ricerca
Start in src/Plugins/Tia.php: compare the local-graph reachability check near lines 858-865 with handleParent() and enterReplayMode(), where $changedFiles->since($branchSha) ?? [] around line 1053 treats null as no changes. Run vendor/bin/pest --tia with an unreachable baseline SHA to reproduce. Done when a fetched graph with an unreachable SHA is rebuilt or runs the full suite, and null from since() no longer means no changes.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
What Happened
When the TIA graph comes from a fetched baseline, handleParent() goes straight to replay mode without checking that the baseline's recorded commit is reachable.
- A locally loaded graph is checked first:
src/Plugins/Tia.phparound lines 858–865 rebuilds it with "Recorded commit is no longer reachable — graph will be rebuilt." - A fetched graph never gets that check.
enterReplayMode()then does$changed = $changedFiles->since($branchSha) ?? [];(line 1053), so an unreachable SHA reads as "nothing changed", and every test is replayed as passed.
Expected: a fetched graph gets the same reachability check as a local one, and is rebuilt (or the whole suite runs) when its SHA is unreachable. since() returning null should never mean "no changes".
How to Reproduce
- Fetch a baseline whose recorded SHA is not an ancestor of
HEAD. Two ordinary ways to get there:actions/checkout's defaultfetch-depth: 1, where no older commit exists locally;- with full history, a baseline recorded on a default-branch commit newer than the pull request's merge base.
- Put a parse error in an application class.
- Run
vendor/bin/pest --tia.
Result: Tests: 2429 passed (8667 assertions, 2429 replayed), exit 0. With a reachable SHA and a valid edit to the same class, the same run selects 16 test files.
Sample Repository
No response
Pest Version
5.3.2 (PHPUnit 13.4.2, paratest 7.26.1)
PHP Version
8.5.8
Operation System
macOS
Notes
Related in spirit to #1856 (a result recorded for code that never ran), but the trigger here is a fetched baseline rather than a commit during the run.
- Lingua principale
- PHP
- Stelle
- 11.8k
- Fork
- 559
- Merge medio
- 5g 23h
- PR unite (30g)
- 24
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di pestphp/pest
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 5 giorni
-
[Bug]: --mutate hides unreadable files, so mutants behind a failed read can never be killedForse di nuovo libera Una pull request per questa issue è stata chiusa senza essere unita. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 5 giorni
-
[Bug]: [mutate] Windows: @pest-mutate-ignore comments land on line 1 in files with LF line endingsForse già presa @webdevsamran l’ha presa 57 giorni fa. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 5 giorni
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 80/100
I maintainer di solito rispondono entro 5 giorni
-
[pest-plugin-browser] Page::waitForLoadState() never sends its message — waitForEvent() is a silent no-opForse già presa @asllanmaciel l’ha presa 70 giorni fa. Apertabug
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
pestphp/pest#1892 · 2 commenti ·
I maintainer di solito rispondono entro 5 giorni
Tutte le issue di pestphp/pest
Issue simili
-
Group 2 - Data Storage | Tripal DBX | Chado Group 5 - Search | ElasticSearch | Views Priority - Medium
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
-
nginx update required due to NGINX2RootForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 65/100
mailcow/mailcow-dockerized#7668 · 5 commenti · 2 reazioni ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
lara-zeus/spatie-translatable#80 ·
I maintainer di solito rispondono entro 1 giorno
-
small
Difficoltà 2/5 1-3 ore Idoneità per principianti 66/100
uiowa/uiowa#10296 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
asyncapi/modelina#2709 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno