f21a400c82e42a2a62904c62be2b3f35bd71d406
Server timeouts caused orphaned fetchActivityData calls to fire clearCookieCache() asynchronously, destroying cookies for all concurrent callers. Three fixes: 1. Replace Promise.race timeout with AbortController to properly cancel orphaned fetches and prevent delayed clearCookieCache() calls 2. Add cookie backup/restore — backupCookies() before clearCookieCache(), restoreCookieBackup() if re-login fails, so cookies are never lost 3. Add 15s auth failure throttle to block thundering herd re-logins when server slowdowns generate many 500 errors simultaneously
How to Run
copy example.env
cp example.env .env
edit .env
API_USERNAME is your engage username in URL-encode.
API_PASSWORD is your engage password in URL-encode.
Description
Languages
TypeScript
98.1%
Dockerfile
1.1%
Shell
0.8%