Fix flaky test apps/api/tests/test_task_run_metrics.py::test_the_batch_issues_the_same_three_queries_for_one_row_and_for_many
The merge lane saw `apps/api/tests/test_task_run_metrics.py::test_the_batch_issues_the_same_three_queries_for_one_row_and_for_many` fail and then pass on a rerun of the same tree.
- Test: `apps/api/tests/test_task_run_metrics.py::test_the_batch_issues_the_same_three_queries_for_one_row_and_for_many`
- Tree: `aa2d4a1cb79630817862b0c47335df6c9c348f1f`
- Lane task: 7161
- Flake record: 01a15041-06a3-7b45-8f3c-27c39bf4f117
Make it deterministic; do not delete it unless it tests nothing.
Outcome
Deflaked the cost-load query-count test: _captured_sql now listens on every engine lane (_LanedSession moved sessions to background_engine → 0 counted). Repro failed before, passes after; quick gate green; PR #5894 merged (22e99e59). Follow-up draft #7254.
Artifacts
Activity
- Ready
- Runner started
- Runner ended (done)