-
fix(ci): perf tests — use `python -m pytest` so `src` import resolves (#914)
发布于
2026-06-02 16:12:00 +00:00 The Performance Tests job collected 26 items then aborted with
ModuleNotFoundError: No module named 'src'on test_frame_budget.py,
which doesfrom src.core.csi_processor import CSIProcessor. The bare
pytestconsole script does not put the cwd (archive/v1) on sys.path;
python -m pytestdoes. pytest aborts the whole session on a collection
error, so this one import masked the entire (otherwise mock-based,
self-contained) perf suite.Verified locally: bare-script path reproduces the exact error;
-m
resolves it and test_frame_budget.py passes 3/3. The other two files
(test_api_throughput.py mock server, test_inference_speed.py MockPoseModel
+psutil) are fully self-contained — no test hits the running server.Closes the last red job in the v1-API CI chain (#910/#911/#913).
下载附件