[Bug]: Intermittent failure in PathUtilsTests.testNewDirectoryIsExcludedAndExistingChoiceIsKept
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 65/100
Direzione di ricerca
Leggi PathUtilsTests.swift intorno all’aspettativa che fallisce alla riga 99 e controlla le letture e le scritture del valore della risorsa del test. Esegui ripetutamente swift test --filter testNewDirectoryIsExcludedAndExistingChoiceIsKept, poi confronta con esecuzioni ripetute di make test per indagare il comportamento intermittente segnalato. L’obiettivo è che il test verifichi in modo affidabile che la scelta di backup della directory esistente rimanga inclusa.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
I have done the following
- I have searched the existing issues
- If possible, I've reproduced the issue using the 'main' branch of this project
Steps to reproduce
Run make test repeatedly. The failure is intermittent, and I have no reliable way to trigger it.
I saw 1 failure across about 12 test runs on working branches. PathUtils.swift and PathUtilsTests.swift are unchanged from main on that branch. The test then passed 5 times when run alone with swift test --filter testNewDirectoryIsExcludedAndExistingChoiceIsKept, and passed in the next 2 full runs.
Problem description
PathUtilsTests.testNewDirectoryIsExcludedAndExistingChoiceIsKept intermittently fails on its last expectation, which checks that an existing directory's choice to be included in backups is kept:
◇ Test testNewDirectoryIsExcludedAndExistingChoiceIsKept() started.
✘ Test testNewDirectoryIsExcludedAndExistingChoiceIsKept() recorded an issue at PathUtilsTests.swift:99:9: Expectation failed: try !Self.isExcludedFromBackup(snapshots)
↳ try !Self.isExcludedFromBackup(snapshots) → <not evaluated>
✘ Test testNewDirectoryIsExcludedAndExistingChoiceIsKept() failed after 0.015 seconds with 1 issue.
✘ Suite PathUtilsTests failed after 0.016 seconds with 1 issue.
The test reads isExcludedFromBackup as true, sets it to false through a copy of the URL, calls createDirectoryExcludingFromBackup again, and expects to read false.
A possible cause, which I have not confirmed: URL caches resource values, so the last read through snapshots could return the earlier value. If so, the fault is in the test rather than in createDirectoryExcludingFromBackup, and calling removeAllCachedResourceValues() before the read may fix it.
Environment
- OS: macOS 27.2
- Xcode: Swift 6.4 (swiftlang-6.4.0.34.1 clang-2100.3.34.1)
- Container: working branch based on main at ec82253e
- Temporary directory: on the boot volume (APFS)
Code of Conduct
- I agree to follow this project's Code of Conduct
- Lingua principale
- Swift
- Stelle
- 51k
- Fork
- 1.8k
- Merge medio
- 2g 10h
- PR unite (30g)
- 39
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 apple/container
-
[Request]: container ls --filter label=key=valueForse già presa @kavix l’ha presa 11 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
apple/container#2403 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[Request]: Improve robustness and path resolution in ensure-hawkeye.shForse già presa @denizguney l’ha presa 34 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
[Bug]: kernel download hangs forever when the server stops sendingForse già presa @devops-thiago l’ha presa 36 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
apple/container#2327 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug]: container export -o deletes an existing directoryForse già presa @devops-thiago l’ha presa 36 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
apple/container#2325 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
[Bug]: --mount and -v accept a relative container path and mount it at /<path>Forse già presa @devops-thiago l’ha presa 36 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 86/100
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di apple/container
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
nightscout/Trio#1748 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
carp-dk/flutter-plugins#1312 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
newrelic/newrelic-flutter-agent#256 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 75/100
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 83/100
I maintainer di solito rispondono entro 1 giorno