Skip to content

fix(extension): retry server detection, report refusals and wait for the page id - #195

Draft
erkamyaman wants to merge 1 commit into
santoshyadavdev:mainfrom
erkamyaman:fix/extension-retry-page-id
Draft

erkamyaman wants to merge 1 commit into
santoshyadavdev:mainfrom
erkamyaman:fix/extension-retry-page-id

Conversation

@erkamyaman

Copy link
Copy Markdown
Collaborator

Two fixes in the Chrome extension panel's server detection.

#103: retry, and a 403 is not "no answer"

  • Each tried URL shows its status: (404), (403) or (no answer).
  • A 401 or 403 now reads "The devtools server on refused the request (403). It said: ...", with a link to the "answers only your machine" docs instead of the setup link.
  • Both failure views have a Try again button that runs detection again without a page reload.

#104: the panel waits for the inspected tab's page id

  • The overlay sets window.__ngDevtoolsPageId once it claims its id, and removes it on dispose only if it still holds that id.
  • The panel reads it from the inspected tab every 250 ms for up to 5 s before loading, so a slow overlay no longer leaves it on another tab's data. Overlays from published versions without the global fall back to the stored id after 5 s.

Docs: the Chrome extension getting started and contributing pages (statuses, the refused message, Try again, the page id wait, two FAQ items).

Fixes #103
Fixes #104

Checks

  • 8 new tests in extension-panel-bridge.test.ts and overlay-dispose.test.ts; all fail with the fix reverted
  • pnpm test:devtools (1072), pnpm test:panel, pnpm typecheck, pnpm format:check, pnpm skills:check and the docs build pass

Not checked yet

  • Manual test in real Chrome: retry after starting the server, the 403 message on a LAN IP, and the page id with two tabs and a throttled reload

…the page id

The panel dropped each probe's status, so a 403 from the devtools
server looked like no answer, and the only way to try again was a
reload. It now lists each probe with its status, says when the server
refused the request and why, and has a Try again button. It also read
the page id from sessionStorage once and loaded without it, so a slow
overlay left the panel on another tab's data. The overlay now exposes
its page id and the panel waits up to 5 s for it.

Fixes santoshyadavdev#103
Fixes santoshyadavdev#104
@coderabbitai

coderabbitai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added area: package The ng-devtools package (packages/ng-devtools) area: extension The Chrome extension area: docs The documentation site labels Oct 1, 2026
@nx-cloud

nx-cloud Bot commented Oct 1, 2026

Copy link
Copy Markdown

View your CI Pipeline Execution ↗ for commit c6f8698

Command Status Duration Result
nx affected -t test build ✅ Succeeded 1m 52s View ↗

💡 Verify your cache is correct by running tasks in a sandbox. Read docs ↗


☁️ Nx Cloud last updated this comment at 2026-10-01 10:29:16 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: docs The documentation site area: extension The Chrome extension area: package The ng-devtools package (packages/ng-devtools)

Projects

None yet

1 participant