Skip to content

Fix Cloudflare Pages deploy from the pnpm workspace root - #10

Merged
Blazenetic merged 3 commits into
mainfrom
cursor/cloudflare-pages-workspace-deploy-b0c4
Aug 30, 2026
Merged

Fix Cloudflare Pages deploy from the pnpm workspace root#10
Blazenetic merged 3 commits into
mainfrom
cursor/cloudflare-pages-workspace-deploy-b0c4

Conversation

@Blazenetic

@Blazenetic Blazenetic commented Aug 28, 2026

Copy link
Copy Markdown
Owner

What changed

The first Cloudflare Pages / Workers Builds deploy failed after a successful pnpm build. The host ran npx wrangler deploy from the repository root, and Wrangler 4.x refused to auto-detect a package inside a pnpm workspace.

This PR commits a repository-root wrangler.toml that names apps/observatory/dist and no Worker script, so the default dashboard deploy command has an explicit target. The static-release runbook now records the dashboard settings. The policy gate checks the Wrangler target. There is still no Worker script, Pages Function or application backend, and Wrangler is not added to the lockfile.

The branch was rebased onto current main (a63181c). That rewrite kept the Wrangler target but dropped ADR 0010 and the session handover while leaving links to both. Those files are restored; the coding-agent start pointer stays on the post-Phase-5 review.

Scientific-integrity check

  • Live, demo, derived, projected, probed and interventional outputs are clearly labelled.
  • No new copy anthropomorphises model behaviour or overstates causality.
  • Any new metric has a documented method, units and compatibility boundary.

No model path, sampler, evidence class or header contract changed. The Phase 5 source candidate is not rebound.

Verification

  • Local pnpm check on the original head; static-release policy re-checked after the restore
  • npx wrangler@4.127.1 deploy at a workspace root without config — reproduced the original detection error
  • npx wrangler@4.127.1 deploy --dry-run from / with the committed config — read apps/observatory/dist and exited 0
  • GitHub CI on current head 96fb6a1 — retriggered. The 9f9641f run completed every quality step, then the workflow was cancelled by concurrency while an older rebase SHA was still in flight. e2e did not finish on that SHA.
  • Keyboard and reduced-motion pass — no UI behaviour change
  • Responsive visual review — no UI behaviour change

Evidence

Cloudflare deploy log from 2026-08-28: build succeeded (pnpm run build / Vite), then:

✘ [ERROR] The Cloudflare application detection logic has been run in the root of a workspace instead of targeting a specific project.

Local reproduction with Wrangler 4.127.1 matched that error when no config was present. After this change, the same Wrangler version dry-ran from the workspace root and reported:

✨ Read 10 files from the assets directory /workspace/apps/observatory/dist
No bindings found.
--dry-run: exiting now.

Known limits / next slice

Redeploy the existing Cloudflare project after merge. The dashboard project name must match thinking-machine-observatory (or change wrangler.toml to match the dashboard name). A live URL, observed headers and candidate commit still have to be attached before a deployed-origin evidence record can pass. This branch does not claim a live Cloudflare deploy.

Do not set the Cloudflare root directory to apps/observatory; the workspace install has to run from /.

Open in Web Open in Cursor 

@Blazenetic
Blazenetic marked this pull request as ready for review August 28, 2026 16:24
@Blazenetic
Blazenetic force-pushed the cursor/cloudflare-pages-workspace-deploy-b0c4 branch from 8dc4e41 to c7d792d Compare August 30, 2026 10:19
cursoragent and others added 2 commits August 30, 2026 10:21
The rebase onto current main kept wrangler.toml but omitted ADR 0010 and
the session note while leaving links to both. Restore those files and
keep the coding-agent start pointer on the post-Phase-5 review.

Co-authored-by: Blazenetic <blazenetic@proton.me>
The previous 9f9641f workflow was cancelled by concurrency while an older
rebase SHA was still running. Empty commit so quality and e2e run on the
current documentation restore.

Co-authored-by: Blazenetic <blazenetic@proton.me>
@Blazenetic
Blazenetic merged commit 3037426 into main Aug 30, 2026
2 checks passed
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.

2 participants