feat: Add Linear action item syncing for incidents #139
@sentry/warden / warden: find-bugs
completed
Apr 14, 2026 in 7m 49s
1 issue
find-bugs: Found 1 issue (1 low)
Low
Race condition in OAuth token refresh may cause redundant token requests - `src/firetower/integrations/services/linear.py:75-83`
The _get_access_token method reads the token and checks expiration without locking, then calls _request_new_token which deletes and recreates the token. In a multi-worker environment, concurrent requests may simultaneously determine the token needs refresh and each request a new token from Linear. While the atomic block prevents data corruption during the write, it doesn't prevent multiple redundant token refresh requests. This wastes API calls and could hit rate limits.
Duration: 7m 46s · Tokens: 5.3M in / 38.9k out · Cost: $9.21 (+extraction: $0.00, +fix_gate: $0.00)
Loading