DebugMidBackendAuto-graded
Fix a test that fails randomly in CI
The suite fails on most runs in CI, and a re-run sometimes passes. Make it pass every run by fixing the code, without retries or skips.The contributor-leaderboard suite intest_app.py fails at random in CI, and re-running the job sometimes turns it green. The failures come from a real problem in the code under test, app.py. Find it and make the suite pass every time. Leave the tests as they are: no skips, no deleted or loosened assertions, no retries or other workarounds inside a test.25 min
python
You're done when
- The whole suite passes 50 consecutive runs.
- The non-determinism is fixed in
app.py, the code under test.
What it measures
Debugging intermittent failuresGetting from a failure that only shows up some of the time to the code that causes it.
Testing disciplineReading a flaky test as a sign of a real defect in the code.
Fixing the root causePutting the fix in the code and leaving the tests exactly as written.
Your environment
Terminal + editorA full shell in the browser
Coding agentAlready signed in, no API key to set up
Isolated workspaceOnly yours, wiped when you finish
Start this lab
25 min
Start labYou'll need to sign in to Anthropos first. The lab opens in a private cloud workspace with your coding agent ready to use.AI Labs is part of Anthropos Workforce. Not on your plan yet? Book a demo