[Bug]: Intermittent failure in PathUtilsTests.testNewDirectoryIsExcludedAndExistingChoiceIsKept
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 2/5
- Tiempo estimado
- 1-3 horas
- Aptitud para principiantes
- 65/100
Línea de trabajo
Lee PathUtilsTests.swift alrededor de la expectativa que falla en la línea 99 e inspecciona las lecturas y escrituras del valor del recurso de la prueba. Ejecuta repetidamente swift test --filter testNewDirectoryIsExcludedAndExistingChoiceIsKept y luego compara con ejecuciones repetidas de make test para investigar el comportamiento intermitente reportado. El objetivo es que la prueba verifique de forma fiable que la opción de copia de seguridad del directorio existente siga incluida.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
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
- Lenguaje dominante
- Swift
- Estrellas
- 51.1k
- Forks
- 1.8k
- Merge medio
- 2 d 10 h
- PR fusionados (30 d)
- 37
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de apple/container
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 1 día
-
[Request]: container ls --filter label=key=valuePosiblemente ocupada @kavix la tomó hace 14 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 75/100
apple/container#2403 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
[Request]: Improve robustness and path resolution in ensure-hawkeye.shPosiblemente ocupada @denizguney la tomó hace 38 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
Los mantenedores suelen responder en 1 día
-
[Bug]: kernel download hangs forever when the server stops sendingPosiblemente ocupada @devops-thiago la tomó hace 40 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
apple/container#2327 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
[Bug]: container export -o deletes an existing directoryPosiblemente ocupada @devops-thiago la tomó hace 40 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
apple/container#2325 · 1 comentario ·
Los mantenedores suelen responder en 1 día
Todos los issues de apple/container
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
swiftlang/github-workflows#352 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
jphacks/kz_2601#1375 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 83/100
paritytech/polkadot-ios-community#415 ·
Los mantenedores suelen responder en 1 día
-
area:infra enhancement
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
axeslasher/Jelly-Shark#352 ·
Los mantenedores suelen responder en 1 día