A minimal, dependency-free example of turning a reproducible CSV parsing failure into a tested repair.
This is a self-produced demonstration, not paid client work. It supports the Python & Browser Automation Rescue — 6-Hour Sprint.
The legacy parser converts every row directly to an integer. A blank row therefore raises ValueError and stops the workflow.
return [int(row) for row in text.splitlines()]The corrected parser trims each row, skips only blank rows, and still raises an error for non-empty invalid input. This avoids hiding real data problems.
Run from this directory with Python 3.9 or newer:
python -m unittest -v test_csv_repair.pyExpected result: three tests pass. The first test preserves the original crash as expected evidence; the second verifies the repair; the third confirms that non-empty invalid input is not silently discarded.
Ran 3 tests
OK
csv_repair.py: failing legacy implementation and repaired implementationtest_csv_repair.py: regression tests for the failure, repair, and invalid-input boundary
The fixed-price rescue sprint covers one reproducible Python or permitted browser-automation failure, including diagnosis, the agreed change, repeatable verification, and concise handoff notes. See the scope before ordering.