Editor blocks (M27) are blank when the app and block sites are different sites #69

Closed
opened 2026-10-02 20:31:08 +00:00 by jhgaylor · 1 comment
Owner

Found on geek with 0.6.0. The app is https://geek..ts.net and block sites are https://b-N.illogical.widgets.wtf:7443, so they are different sites. An editor block's iframe shows white, then an empty workbench ("No Folder Opened", or the file tab open with no content).

What we know:

  • The same block URL loaded as a top-level page works: folder, git branch and the file at its line, with no console errors.
  • In the iframe, the workbench loads, Creating a socket … successful for both Management and ExtensionHost, and the illogical extension joins (editor joined in the daemon log). But reads like vscode-remote://…/.vscode/settings.json and the workspace file never complete (still pending after 20 s; Canceled on unload).
  • No cookies are involved (code-server runs with --auth none and sets none). The sites.rs check refuses cross-site requests that aren't navigations, and does not log refusals.
  • The e2e tests use 127.0.0.1/localhost for both the app and the blocks (same site), so they don't cover this.

Done when: a Playwright spec with the app and the block site on different sites (e.g. app on 127.0.0.1 and blocks on *.localhost, or two hostnames) shows the editor block's file at its line inside the page; the root cause is fixed; and refusals in sites.rs are logged at debug.

Found on geek with 0.6.0. The app is https://geek.<tailnet>.ts.net and block sites are https://b-N.illogical.widgets.wtf:7443, so they are different sites. An editor block's iframe shows white, then an empty workbench ("No Folder Opened", or the file tab open with no content). What we know: - The same block URL loaded as a top-level page works: folder, git branch and the file at its line, with no console errors. - In the iframe, the workbench loads, `Creating a socket … successful` for both Management and ExtensionHost, and the illogical extension joins (`editor joined` in the daemon log). But reads like `vscode-remote://…/.vscode/settings.json` and the workspace file never complete (still pending after 20 s; Canceled on unload). - No cookies are involved (code-server runs with --auth none and sets none). The sites.rs `check` refuses cross-site requests that aren't navigations, and does not log refusals. - The e2e tests use 127.0.0.1/localhost for both the app and the blocks (same site), so they don't cover this. Done when: a Playwright spec with the app and the block site on different sites (e.g. app on 127.0.0.1 and blocks on *.localhost, or two hostnames) shows the editor block's file at its line inside the page; the root cause is fixed; and refusals in sites.rs are logged at debug.
jhgaylor referenced this issue from a commit 2026-10-02 21:28:40 +00:00
jhgaylor referenced this issue from a commit 2026-10-02 22:06:34 +00:00
Author
Owner

Confirmed fixed by Jake on control's page with 0.6.2. Two causes:

  1. The block site's frame-ancestors didn't include control's origin. It does now while the daemon is enrolled.
  2. Control's own CSP had no frame-src. It now has frame-src 'self' https:.
    0.6.1 also added the storage stand-in for browsers that block third-party cookies, and frame-ancestors 'self' for VS Code's own frames.
Confirmed fixed by Jake on control's page with 0.6.2. Two causes: 1. The block site's frame-ancestors didn't include control's origin. It does now while the daemon is enrolled. 2. Control's own CSP had no frame-src. It now has frame-src 'self' https:. 0.6.1 also added the storage stand-in for browsers that block third-party cookies, and frame-ancestors 'self' for VS Code's own frames.
Commenting is not possible because the repository is archived.
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
jhgaylor/illogical#69
No description provided.