Skip to content

Fix landing runtime provider crash and LogRocket CSP blocking#213

Merged
sirjamesgray merged 4 commits into
mainfrom
copilot/fix-use-demo-balance-error
May 16, 2026
Merged

Fix landing runtime provider crash and LogRocket CSP blocking#213
sirjamesgray merged 4 commits into
mainfrom
copilot/fix-use-demo-balance-error

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented May 16, 2026

Summary

Fix production runtime issues reported on welcome/landing by ensuring the demo balance context is always available where used, and by allowing LogRocket ingest host traffic in CSP.

Changes

  • Provider gating in /home/runner/work/WeWrite/WeWrite/app/providers/ConsolidatedProviders.tsx
    • Root path / is no longer treated as auth-only flow
    • Only /auth* routes bypass financial providers
    • This ensures landing/welcome components using useDemoBalance() are wrapped by DemoBalanceProvider
  • CSP connect-src in /home/runner/work/WeWrite/WeWrite/next.config.js
    • Added https://*.logr-in.com to allow LogRocket requests like https://r.logr-in.com/...

Notes

  • CSP font violation for frontend-cdn.perplexity.ai appears to be extension-injected and is correctly blocked by policy.
  • /api/auth/session 401 can be expected for anonymous sessions depending on flow.

Validation

  • Code review check passed
  • CodeQL returned no alerts (analysis skipped due to DB size)
  • Existing unrelated repo baseline issues remain (lint script invocation config, unrelated tests, sandbox build font fetch)

Copilot AI and others added 4 commits May 15, 2026 17:34
Agent-Logs-Url: https://github.com/WeWriteApp/WeWrite/sessions/8127f7df-0752-4275-b627-c4623eff2a66

Co-authored-by: sirjamesgray <16139439+sirjamesgray@users.noreply.github.com>
Agent-Logs-Url: https://github.com/WeWriteApp/WeWrite/sessions/ca86ddfd-60dd-4bd4-8984-fb27edd7ee19

Co-authored-by: sirjamesgray <16139439+sirjamesgray@users.noreply.github.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 16, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
wewrite Ready Ready Preview, Comment May 16, 2026 2:40pm

Request Review

@sirjamesgray sirjamesgray marked this pull request as ready for review May 16, 2026 14:44
@sirjamesgray sirjamesgray merged commit c72e10e into main May 16, 2026
6 checks passed
@sirjamesgray sirjamesgray deleted the copilot/fix-use-demo-balance-error branch May 16, 2026 14:44
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