You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Testing modified files in CI breaks warn_external and relative imports in tests #8166
It seems that whatever happens if the --installed flag is passed to spin test, warn_external breaks. I suspect because the paths passed to skip_file_prefixes don't match the actual install paths at runtime. I don't yet understand where or how this happens in .spin/cmds.py.
Also, I think the fact that --test-modified passes subdirs of the test directory to pytest also breaks relative imports in the test suite that work if invoked normally. For example see this run:
ERROR tests/skimage/feature/test_util.py - ModuleNotFoundError: No module named 'tests.dependency_checks'; 'tests' is not a package
ERROR tests/skimage/filters/test_thresholding.py - ModuleNotFoundError: No module named 'tests.dependency_checks'; 'tests' is not a package
ERROR tests/skimage/transform/test_radon_transform.py - ModuleNotFoundError: No module named 'tests.dependency_checks'; 'tests' is not a package
And third, are we sure that the run-all-tests label is picked up by the process-labels workflow correctly?
This process-labels job still sets HAS_LABEL: false for some reason. I thought that adding the label and requesting a rerun would be enough.
Might also be useful to look into keeping the invocation of spin test and the test configuration reasonably similar to the local setup. I think that was the reason for using spin test in the CI in the first place? Creating a significantly different test environment with the --installed --test-modified flags defeats that purpose somewhat.
I have a branch that verifies a fix for #8069, as a PR to my fork: blink1073#8. I'm going to make it a standalone fix, and add the ability to run --test-modified and --installed locally to make it easier to reproduce what is going on in CI.
Activity
lagru commentedon May 16, 2026
Might also be useful to look into keeping the invocation of
spin testand the test configuration reasonably similar to the local setup. I think that was the reason for usingspin testin the CI in the first place? Creating a significantly different test environment with the--installed --test-modifiedflags defeats that purpose somewhat.blink1073 commentedon May 17, 2026
Ah, no, that would require more complicated logic, to get the label from the PR instead of the event.
blink1073 commentedon May 17, 2026
Here's a better label handler: #8169
blink1073 commentedon May 18, 2026
I have a branch that verifies a fix for #8069, as a PR to my fork: blink1073#8. I'm going to make it a standalone fix, and add the ability to run
--test-modifiedand--installedlocally to make it easier to reproduce what is going on in CI.blink1073 commentedon May 18, 2026
PR: #8173
ci: improve handling of pr labels (#8169)
blink1073 commentedon May 22, 2026
Closing as completed by #8169 and #8173