Skip to content

fix: drop chrome.alarms permission (0.0.30 release)#64

Merged
BitHighlander merged 1 commit intomasterfrom
fix/drop-alarms-permission
May 1, 2026
Merged

fix: drop chrome.alarms permission (0.0.30 release)#64
BitHighlander merged 1 commit intomasterfrom
fix/drop-alarms-permission

Conversation

@BitHighlander
Copy link
Copy Markdown
Collaborator

Why

Chrome Web Store update gates on permission additions — `alarms` was added in #55 to keep the 45s post-broadcast drop-check firing across MV3 service-worker idle eviction. The drop-check is diagnostic UX, not load-bearing for tx safety:

  • 8s check still uses `setTimeout` (< 30s — always fires while SW is warm from broadcast)
  • 45s check fires during active dApp interaction (block polling / eth_chainId pings keep SW alive)
  • When the SW idles immediately after broadcast, we just miss the 45s warning. The tx outcome is unchanged.

Trading a rare diagnostic warning for not gating Chrome Web Store rollout on user re-consent.

What's removed

  • `alarms` permission from `chrome-extension/manifest.js`
  • `chrome.alarms.create` call in `scheduleDropCheck`
  • `chrome.alarms.onAlarm` listener registered at module load
  • `DROP_CHECK_ALARM_PREFIX` constant + name-encoded delay parsing

`scheduleDropCheck` becomes a one-liner: `setTimeout(performDropCheck, delayMs)`.

Version

Bumps to 0.0.30 (since 0.0.29 merge already landed on master). This is the version that ships to the Web Store.

Files

  • `chrome-extension/manifest.js`
  • `chrome-extension/src/background/chains/ethereumHandler.ts`
  • 20 × `package.json` version bumps via `make bump VERSION=0.0.30`

Test plan

  • Build clean
  • `dist/manifest.json` permissions field no longer contains `alarms`
  • Trigger a tx broadcast; verify `[DROP-CHECK]` line still logs at 8s
  • During active dApp use (Uniswap polling), verify 45s check still fires (SW kept warm)

🤖 Generated with Claude Code

Chrome Web Store update prompts users on permission additions, and `alarms`
was added in #55 just to keep the 45s post-broadcast drop-check firing across
service-worker idle eviction. The drop-check is diagnostic UX (warns the
user when a tx isn't propagating), not load-bearing for tx safety — the
8s check still uses setTimeout (< 30s, always fires), and during active
dApp interaction the SW is kept warm by block-polling so 45s setTimeout
fires in the common case anyway. When the SW idles immediately after
broadcast, we miss the 45s warning; the tx outcome is unchanged.

Removes:
  - alarms permission from chrome-extension/manifest.js
  - chrome.alarms.create + onAlarm listener in ethereumHandler
  - DROP_CHECK_ALARM_PREFIX constant + name-encoded delay parsing

Bumps to 0.0.30.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@BitHighlander BitHighlander changed the base branch from develop to master May 1, 2026 03:07
@BitHighlander BitHighlander merged commit d0b6994 into master May 1, 2026
3 of 5 checks passed
@BitHighlander BitHighlander deleted the fix/drop-alarms-permission branch May 1, 2026 03:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant