You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Tests: replace fixed sleeps with a polling wait_for helper #512
Tests contain about 27 non-zero asyncio.sleep / time.sleep calls, mostly in background_tasks. Examples:
test_bg_invalidation_redis.py:148,197: sleep(0.3)
test_bg_outbox_retry_policy.py:135: sleep(0.6)
test_bg_invalidation_degraded.py:114: sleep(0.2)
test_events.py:110
test_file_storage_thumbnail_hardening.py:186
Some are deliberate "block forever" stubs (30 s, 5 s), and those are fine. The fixed 0.2-0.6 s waits are bets on timing. They flake on a loaded CI runner and make the suite slower than it needs to be on a fast one.
Fix
Add wait_for(predicate, timeout=2.0, interval=0.01) (async and sync versions) to simple_module_test.
Replace each fixed wait that stands in for "until X happened".
Optionally add a lint script that flags new sleep(<float>) in tests/ without an # intentional-sleep: marker.
Activity
Tenancy walk perf + WHERE-only leak fix, PermissionDenied, TenantDele…