Problem: `_submit_sync` was a deeply nested closure containing `_solve_turnstile` and the browser-install block as further nesting. Status events went to stderr, which `run_scraper()` silently discards. Solution: Extract `_TURNSTILE_JS`, `_solve_turnstile`, `_ensure_browser`, and `_submit_headless` to module level. Status events (`installing_browser`, `checking_login`, `logging_in`, `submitting`) now print to stdout as NDJSON. `submit()` delegates to `asyncio.to_thread(_submit_headless, ...)`. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| atcoder.py | ||
| base.py | ||
| codechef.py | ||
| codeforces.py | ||
| cses.py | ||
| kattis.py | ||
| language_ids.py | ||
| models.py | ||
| usaco.py | ||