[codex] Skip missing static file sources#4122
Conversation
|
CI note from the first run:
I am keeping this branch scoped to the missing static-file source behavior instead of copying those CI-only fixes into this PR. |
|
Follow-up after the rerun: the code/test failures from the first matrix are gone. The only remaining red checks are both PyPy 3.9 dependency bootstrap failures before MkDocs tests run:
All CPython, macOS PyPy, lint, style, build, and package jobs are green on this head. This matches the PyPy 3.9 CI bootstrap drift addressed separately by #4120 rather than a failure in this static-file change. |
|
I pushed a small follow-up ( Fresh local validation on the current branch:
Current GitHub Actions after the follow-up: build/lint/package/style and all CPython test lanes are passing. The remaining red lanes are the existing PyPy 3.9 dependency-install failures, before tests run: Ubuntu fails building |
|
CI note: the two red PyPy 3.9 jobs are failing before the MkDocs test suite starts, during the workflow dependency install step (
|
Summary
is_modified()can raise before copy reaches the missing-source warningWhy
Broken symlinks or files that disappear after discovery currently raise
FileNotFoundErrorwhile MkDocs is copying static files. There is an older related PR in #3785; this keeps the fix local toFile.copy_file, avoids release/version churn, and adds focused test coverage including dirty-copy behavior.Validation
git diff --checkhatch run test.py3.12-default:python -m unittest mkdocs.tests.structure.file_tests.TestFiles.test_copy_file_missing_source mkdocs.tests.structure.file_tests.TestFiles.test_copy_file_dirty_missing_sourcehatch run test.py3.12-default:python -m unittest mkdocs.tests.structure.file_testsmkdocs buildrepro with a broken docs symlink completes withWARNING - File skipped: ... does not exist.mkdocs build --dirtyrepro after breaking a previously valid symlink completes with the same warninghatch run style:check