Skip to content

ci(studio): run E2E against both Next + TanStack (stack 6/6, from #46424) - #47119

Merged
alaister merged 117 commits into
masterfrom
alaister/migration-s6-e2e-matrix
Jul 10, 2026
Merged

alaister merged 117 commits into
masterfrom
alaister/migration-s6-e2e-matrix

Conversation

@alaister

@alaister alaister commented Jun 19, 2026 •

Copy link
Copy Markdown
Member

Stack 6/6 (final) of the TanStack Start migration (#46424). The middle slices (#47107 → #47118) have all merged, so this now sits directly on master.

What's in this PR

One file: .github/workflows/studio-e2e-test.yml — adds framework: [next, tanstack] to the test/report matrices and sets STUDIO_FRAMEWORK (consumed by scripts/dispatch.js). Until now CI only built/tested Next. This flips on the dual-framework E2E matrix so the TanStack build gets exercised end-to-end on every run.

⚠️ Depends on #47657 (merge that first)

The tanstack shard needs the Monaco loader fix in #47657 to be on master. Quick version: master's #47182 re-nested the Monaco assets under public/monaco-editor/vs/ and the TanStack root was still pointing at the old flat path, so Monaco didn't mount anywhere in the TanStack build and every editor-backed test timed out (RLS, cron SQL, realtime JSON, db functions, GraphiQL). Kept that fix on its own branch rather than piling it onto this one.

Merge order:

  1. fix(studio): TanStack post-merge fixes — Monaco loader, fonts, CSP (from #46424) #47657 → master
  2. re-merge master into here (I'll cascade it)
  3. tanstack shard goes green → merge this

⚠️ Branch-protection note

This renames the E2E jobs (E2E tests → E2E tests (next|tanstack, shard)), so master's current required status checks (E2E tests (1, 2) / (2, 2)) stop being reported. The required-check list in branch protection needs updating to the new names when this merges.

Verification

Config-only, no app code. The real validation is this matrix running both shards green once #47657 lands — the next shards already pass here; the tanstack shards pass once the Monaco fix is on master.

Summary by CodeRabbit

  • New Features

    • Integration overview markdown can now be loaded more reliably from a synchronized on-disk registry (raw markdown support).
  • Bug Fixes

    • Navigation, redirects, and prefetch now preserve query strings and hash fragments more consistently using Next-like semantics (including repeated keys, empty clearing, and lossless encoding like newlines).
    • Improved internal-link/router compatibility for Next-style ?/# targets and base-path handling.
    • Edge Functions diff tab matching works correctly in the browser without Node-specific path utilities.

alaister added 7 commits June 19, 2026 15:33
…RAMEWORK flag (1/6, from #46424)

Foundation of the TanStack Start migration (#46424), split into a reviewable
stack. Next remains the default and only active framework after this PR — the
TanStack build pipeline is wired up but has no routes yet, so it isn't
functional or tested until later PRs flip the feature flag.

- package.json: dev/build/start now dispatch via scripts/dispatch.js (defaults
  to next); add :next/:tanstack variants, vite/tanstack deps.
- scripts: dispatch.js, serve.js, smoke-server.mjs, generateLocalEnv.js.
- vite.config.ts, turbo.jsonc, tsconfig.json (jsx: react-jsx, Bundler).
- next.config.ts + redirects.shared.ts (shared redirect rules with vercel.ts),
  proxy.ts/start.ts middleware + hosted-api-allowlist.ts.
- companion adaptations the tsconfig change requires to keep typecheck green
  (BufferSource casts, packages/ui unused-React import removals, etc.).

Verified: frozen install, studio typecheck, Next build, and lint ratchet all
green; Next stays the default build.
…46424)

Adds compat/next/* — drop-in shims for next/link, next/router, next/navigation,
next/head, next/image, next/script, next/dynamic, next/server, and a
toWebHandler (compat/next/api.ts) that lets pages-router API handlers run as
TanStack server routes. Under TanStack these are wired in via Vite aliases
(next/* -> @/compat/next/*); Next never imports them, so this is purely
additive. No routes consume them yet — that starts in the next stack PR.

Stacked on #47107. Verified: studio typecheck + lint (0 errors).
…outes (stack 3/6, from #46424)

Adds the TanStack Start app skeleton: routes/__root.tsx (root layout +
redirect beforeLoad), router.tsx, and the _auth (sign-in/up, forgot/reset
password, SSO/MFA/partner, CLI login) and _app (account, org/$slug, support)
route trees. These are thin wrappers that render the existing pages-router
page components via the compat shims from #47110.

routeTree.gen.ts is REGENERATED by the tanstackStart vite plugin for exactly
the routes present in this PR (not copied from the migration branch, whose
tree references all ~300 routes) — so it typechecks standalone. API routes and
project routes (and a full regenerated tree) land in the next stack PRs.

Stacked on #47110. Verified: studio typecheck + lint (0 errors). Next is
unaffected (it builds pages/, ignores routes/).
…outes (stack 4/6, from #46424)

Adds routes/api/** — ~104 thin TanStack server routes, each wrapping the
existing pages/api handler via toWebHandler (compat shim from S2). Mechanical
and homogeneous: createFileRoute(...).server.handlers = { METHOD: handler }.
Covers platform (pg-meta, auth, storage, integrations, telemetry, ...), ai,
v1, connect, content/mcp, and the standalone utility endpoints.

routeTree.gen.ts is REGENERATED for the routes now present (root + auth/app +
api). Project page routes + the full tree land in stack 5.

Stacked on #47112. Verified: studio typecheck + lint (0 errors). Next is
unaffected (builds pages/, ignores routes/).
…tack 5.1/6, from #46424)

First half of the project routes (split from the original S5 to stay under
CodeRabbit's 150-file review limit). Covers the data cluster — database,
editor, sql, storage, realtime, branches — plus the top-level/onboarding
routes (authorize, join, logout, redeem, verify-email, claim-project, vercel/
github integration entrypoints) and the _app/_auth layout shells + /org/_,
/project/_ catch-alls.

Supporting page edits: hoist BranchesPageWrapper out of getLayout,
ConnectStepsSection import.meta.glob, api/server.js.

routeTree.gen.ts regenerated for the routes present so far. Remaining product
surfaces (auth, logs, settings, observability, functions, advisors,
integrations) land in 5.2.

Stacked on #47113. Verified: studio typecheck, lint (0 errors), Next build
(181/181 pages).
…etc (stack 5.2/6, from #46424)

Second half of the project routes (split from S5 for CodeRabbit's 150-file
review cap). Covers the remaining product surfaces: auth, logs, settings,
observability, functions, advisors, and project-level integrations.

Supporting page edits: hoist EdgeFunctionsIndexPageWrapper out of getLayout
(functions), functions/secrets, and move DefaultLayout to the root for logs.

routeTree.gen.ts regenerated for the full route set — now byte-identical to the
migration branch. After this the TanStack app is structurally complete; stack 6
flips on the E2E matrix.

Stacked on #47117. Verified: studio typecheck, lint (0 errors), Next build
(181/181 pages).
… from #46424)

Final step of the migration stack. Adds a framework: [next, tanstack] matrix to
the Studio E2E workflow so every PR exercises both builds (STUDIO_FRAMEWORK is
consumed by scripts/dispatch.js). Until now only the Next build was tested.

⚠️ MERGE LAST. The tanstack E2E shard only passes once master has the whole
picture:
  - the route stack (S1-S5.2),
  - #47104 (lazy API-route clients — the TanStack server evaluates every route
    module at boot, so eager createClient crashes it),
  - #47106 (database E2E race fixes; #47077 already merged).
Merging this before those land will make the tanstack shard red on master.

Note: this renames the E2E jobs (E2E tests -> E2E tests (framework, shard)), so
master's required-status-check names need updating in branch protection.
@supabase

supabase Bot commented Jun 19, 2026

Copy link
Copy Markdown

This pull request has been ignored for the connected project xguihxuzqibwxjnimxev because there are no changes detected in supabase directory. You can change this behaviour in Project Integrations Settings ↗︎.


Preview Branches by Supabase.
Learn more about Supabase Branching ↗︎.

@vercel

vercel Bot commented Jun 19, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
docs Ready Ready Preview, Comment, Open in v0 Jul 10, 2026 10:05am
studio-self-hosted Ready Ready Preview, Comment Jul 10, 2026 10:05am
studio-staging Ready Ready Preview, Comment Jul 10, 2026 10:05am
4 Skipped Deployments
Project Deployment Actions Updated (UTC)
studio Ignored Ignored Jul 10, 2026 10:05am
design-system Skipped Skipped Jul 10, 2026 10:05am
ui-library Skipped Skipped Jul 10, 2026 10:05am
zone-www-dot-com Skipped Skipped Jul 10, 2026 10:05am

Request Review

@coderabbitai

coderabbitai Bot commented Jun 19, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

This PR updates studio E2E reporting for two frameworks, adds Next-compatible URL parsing and navigation helpers across router and redirect paths, replaces Node path basename usage in browser code, and switches integration markdown loading to a static registry with Vite compatibility changes.

Changes

Studio E2E Two-Framework Matrix

Layer / File(s) Summary
Framework matrix and env
.github/workflows/studio-e2e-test.yml
The test job matrix adds next and tanstack, sets STUDIO_FRAMEWORK, and adds build-step comments about MODE=test and NODE_ENV=test.
Framework-scoped reports
.github/workflows/studio-e2e-test.yml
Blob reports, merge jobs, merged artifacts, and PR comment titles are scoped by framework.

Studio URL Semantics and Router Wiring

Layer / File(s) Summary
Search codec and router config
apps/studio/lib/router-search-params.ts, apps/studio/lib/router-search-params.test.ts, apps/studio/router.tsx
New search parsing/stringifying helpers implement Next-style query semantics and are wired into the TanStack router.
Internal URL split helper and link wiring
apps/studio/lib/internal-url.ts, apps/studio/lib/internal-url.test.ts, apps/studio/compat/next/link.tsx
Internal URLs are split into to/search/hash with basePath handling, and Link now delegates to the shared helper.
Router navigation normalization
apps/studio/compat/next/router.ts, apps/studio/compat/next/router.test.ts, apps/studio/compat/next/navigation.ts
Navigation helpers normalize query/hash-only targets and missing pathnames, then pass split URL parts into TanStack Router.
Nuqs adapter and URL shape tests
apps/studio/lib/nuqs-tanstack-adapter.tsx, apps/studio/lib/nuqs-tanstack-adapter.test.ts, apps/studio/lib/router-url-shape.test.tsx
The custom nuqs adapter keeps pathname stable and preserves query/hash behavior, with unit and integration coverage.
Redirect query and hash preservation
apps/studio/redirects.shared.ts, apps/studio/redirects.shared.test.ts, apps/studio/routes/__root.tsx, apps/studio/routes/index.tsx
Redirect matching now merges query/hash values and root redirects carry location hash and serialized search params.

Browser-Safe Edge Function Diff Helpers

Layer / File(s) Summary
Browser-safe file keys
apps/studio/components/interfaces/BranchManagement/EdgeFunctionsDiffPanel.tsx, apps/studio/hooks/branches/useEdgeFunctionsDiff.ts
Both diff helpers replace path.basename with string-based last-segment extraction.

Markdown Loading and Vite Build Tooling

Layer / File(s) Summary
Integration overview markdown registry and loader
apps/studio/static-data/integrations/overviews.ts, apps/studio/static-data/integrations/overviews.test.ts, apps/studio/components/interfaces/Integrations/Integration/MarkdownContent.tsx, apps/studio/components/interfaces/Integrations/Integration/IntegrationOverviewTabV2/MarkdownContent.tsx, apps/studio/types/markdown.d.ts
A registry loads overview.md files through loadIntegrationOverview, both markdown components use it, and .md imports are typed as raw strings.
AMD guard and compatibility aliases
apps/studio/vite.config.ts, apps/studio/compat/sentry-nextjs.ts, apps/studio/TANSTACK_MIGRATION.md
Vite now uses a guarded AMD transform, adds the raw-markdown loader, and aliases next/constants and @sentry/nextjs to local compat modules with matching migration notes.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant AppRouter
  participant CompatRouter
  participant InternalUrlHelper
  participant TanStackRouter

  AppRouter->>CompatRouter: navigate(url) / push(href)
  CompatRouter->>CompatRouter: withDefaultPathname / resolveSearchOrHashOnlyTarget
  CompatRouter->>InternalUrlHelper: splitInternalUrl(resolvedUrl)
  InternalUrlHelper-->>CompatRouter: { to, search, hash }
  CompatRouter->>TanStackRouter: navigate({ to, search, hash })
Loading
sequenceDiagram
  participant Route
  participant RedirectsShared
  participant Location

  Route->>RedirectsShared: matchRedirect({ pathname, search, hash })
  RedirectsShared->>RedirectsShared: preserveQueryAndHash(destination, search, options)
  RedirectsShared-->>Route: destination with merged query/hash
  Route->>Location: redirect to computed href
Loading

Possibly related PRs

  • supabase/supabase#47117: Introduces/relies on STUDIO_FRAMEWORK for framework-specific studio behavior, which matches the workflow changes here.

Suggested reviewers: ivasilov, fsansalvadore, awaseem

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description covers the change, but it does not follow the required template and omits the CONTRIBUTING acknowledgment and current/new behavior sections. Rewrite it using the template headings and add YES/NO for CONTRIBUTING.md, current behavior with issue links, new behavior, and additional context.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the main change: running Studio E2E across both Next and TanStack frameworks.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch alaister/migration-s6-e2e-matrix

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

@github-actions

github-actions Bot commented Jun 19, 2026 •

Copy link
Copy Markdown
Contributor

🎭 Playwright Test Results (next)

passed  238 passed
skipped  5 skipped

Details

stats  243 tests across 28 suites
duration  4 minutes, 41 seconds
commit  6201f2e

Skipped tests

Features › auth-users.spec.ts › should show web3 users as enabled when the matching web3 provider is enabled
Features › sql-editor.spec.ts › SQL Editor › snippet favourite works as expected
Features › sql-editor.spec.ts › SQL Editor › share with team works as expected
Features › sql-editor.spec.ts › SQL Editor › folders works as expected
Features › sql-editor.spec.ts › SQL Editor › other SQL snippets actions work as expected

alaister added 5 commits June 19, 2026 16:54
Iterating response.headers and calling res.setHeader collapses duplicate
keys; for set-cookie the Headers iterator joins every cookie into one
comma-separated value, corrupting auth/session cookies. Pull cookies out
via getSetCookie() and set them as an array. Addresses PR review feedback.
The navigate() shim overloaded Next's `shallow` option as the
push-vs-replace signal, but the ternary was inverted so replace() did a
push. Inverting it naively would also break the 5 push(url, { shallow:
true }) call sites, since shallow is a real Next option (no-op here) and
has nothing to do with push vs replace. Use a dedicated internal
`_replace` flag instead, matching Next's pages-router where push always
pushes and replace always replaces regardless of shallow.

Addresses PR review feedback.
The Next pages pass inboundFlow to SignInLayout (sign-in -> 'sign-in',
sign-up -> 'sign-up'), which gates the focused-provider interstitial and
destination-branded heading for inbound auth links. The TanStack route
wrappers dropped it. sign-in-sso intentionally left unchanged — its Next
page doesn't pass inboundFlow either.

Addresses PR review feedback.
…backpressure

- mcp: stringify the non-Error throw in the 500 fallback instead of
  embedding the raw value, so a circular/non-serializable cause can't
  make JSON.stringify throw inside the catch.
- functions body: build the multipart stream from an async generator via
  Readable.from(...).toWeb() so file reads honour consumer backpressure
  and close the file handle on client disconnect, instead of eagerly
  buffering every file in ReadableStream.start().

Addresses PR review feedback.
The DatabaseLayout title read only the leaf match's staticData, so
trigger sub-routes (triggers/data, triggers/event, the index) that don't
define their own title rendered an empty title instead of inheriting
'Triggers' from the triggers.tsx section layout. Walk up the match chain
to the nearest databaseLayoutTitle. Still returns a string so the
select() memoization holds.

Addresses PR review feedback.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick comments (1)
.github/workflows/studio-e2e-test.yml (1)

14-21: Plan branch-protection required-check updates before merge.

With the new framework matrix, required check names will change from the prior shard-only naming. Update branch protection in the same rollout window to avoid merge blockage right after this lands.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/studio-e2e-test.yml around lines 14 - 21, The addition of
the framework matrix strategy in the E2E tests workflow will change the
generated check names in GitHub Actions. Prior to merging this change, update
the branch protection rules for the repository to reflect the new required check
names that will be generated by the expanded matrix combinations (framework:
[next, tanstack] and shardIndex: [1, 2]). The old shard-only check names will no
longer be generated, so updating branch protection settings in the same
deployment window will prevent merge blockage after this workflow change goes
live.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Nitpick comments:
In @.github/workflows/studio-e2e-test.yml:
- Around line 14-21: The addition of the framework matrix strategy in the E2E
tests workflow will change the generated check names in GitHub Actions. Prior to
merging this change, update the branch protection rules for the repository to
reflect the new required check names that will be generated by the expanded
matrix combinations (framework: [next, tanstack] and shardIndex: [1, 2]). The
old shard-only check names will no longer be generated, so updating branch
protection settings in the same deployment window will prevent merge blockage
after this workflow change goes live.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro

Run ID: 2c03551c-36ab-4fa2-a8b1-cd00b59f8d20

📥 Commits

Reviewing files that changed from the base of the PR and between e0c84df and 5abc54e.

📒 Files selected for processing (1)
  • .github/workflows/studio-e2e-test.yml

@blacksmith-sh

This comment has been minimized.

alaister added 4 commits June 23, 2026 22:38
Extract the .env parser into scripts/lib/env.js so dispatch.js and serve.js
use one implementation instead of duplicating the regex. dispatch.js now
reads .env as well as .env.local (matching serve.js / vite precedence:
shell > .env.local > .env), so STUDIO_FRAMEWORK set in .env is picked up —
previously only .env.local was read, which is why setting it in .env
silently did nothing.

Addresses PR review feedback.
alaister added 12 commits July 7, 2026 05:00
…anStack build

The built TanStack bundle (vite build) crashed at module load on the
table editor route (and any other lazy route whose chunk pulled in
Sentry) with "ReferenceError: process is not defined". The chain:
studio code does `import * as Sentry from '@sentry/nextjs'` in ~25
client files -> @sentry/nextjs's client entry imports
next/dist/shared/lib/constants -> its module scope evaluates
`...(process?.features?.typescript ? ['next.config.mts'] : [])`, and
optional chaining does not guard an undeclared `process` identifier in
the browser, so the whole chunk throws before any component runs. The
Vite dev server shims `process`, which is why this only surfaced in the
production/test build (caught by E2E).

Fix: alias the bare `@sentry/nextjs` id to compat/sentry-nextjs.ts in
vite.config.ts (TanStack build only -- the Next build doesn't read this
config). The shim re-exports @sentry/react (the same-version package
@sentry/nextjs wraps on the client; every API studio uses at runtime --
captureException, captureMessage, startSpan, withScope, setTag, setUser,
init, and the Event/Breadcrumb/StackFrame types -- exists there) and adds
explicit stand-ins for the Next-only APIs (captureRouterTransitionStart,
captureRequestError, withSentryConfig) so the alias can never surface an
"undefined is not a function".

The alias also obsoletes the previous @sentry/nextjs SSR workarounds
(ssr.noExternal entry + ssr.optimizeDeps.include) -- the id is rewritten
before SSR resolution ever sees it, and @sentry/react ships real ESM.

No dependency changes: @sentry/react is already a direct studio dep
resolving to 10.59.0, exactly matching @sentry/[email protected]'s own
dependency.

Verified: test-mode TanStack build passes (prerender + smoke), no built
client chunk contains process?.features / middleware-manifest.json /
PHASE_PRODUCTION_BUILD / next/dist / __NEXT_DATA__, and tsc is clean
apart from the known pre-existing ui-patterns InstructionBlocks error.

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
…k build

The routerPush helper reached for window.next.router, which only exists
under the Next runtime — on the TanStack build both coexistence tests
failed with 'Next router not available'. Fall back to History-API
pushState + popstate, which TanStack Router subscribes to, keeping the
client-side (chunk-preserving) navigation these tests depend on.

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
…ack build

AIEditor loaded Monaco's Deno extra libs via /* @vite-ignore */ dynamic
imports of @/public/deno/*.d.ts. Under Next/turbopack the raw-loader rule
serves them as text modules, but under Vite the ignored imports failed at
runtime (caught + console.error), so edge-function editors silently got no
Deno type hints in the TanStack build.

Extend the md raw loader in vite.config.ts into rawTextLoader, mirroring
both next.config.ts raw-loader rules. The two .d.ts files resolve through
an exact-specifier allowlist to \0-virtual ids served from a load hook:
Rolldown's native dep scanner skips JS plugin hooks and hard-fails parsing
TS declaration syntax (get stdin(): ...;) as runtime TS — which is why the
@vite-ignore hack existed — and the \0 id keeps the scanner externalizing
the module instead. The AIEditor imports stay literal (statically
analyzable by both bundlers) with the 'as string' cast keeping tsc from
resolving the .d.ts files as declaration files.

Verified: vite dev serves both modules as JS string modules and the dep
scan passes; vite build emits them as string chunks; next dev (turbopack)
still compiles /project/[ref]/functions/new; tsc --noEmit clean.

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
…he TanStack build

GraphiQLTab imports graphiql/setup-workers/webpack, whose
new Worker(new URL('monaco-editor/...', import.meta.url)) registrations
only work when the bundler rewrites the URLs. Vite doesn't rewrite bare
specifiers inside new URL(..., import.meta.url), so on
/project/[ref]/integrations/graphiql/graphiql the json /
editorWorkerService / graphql workers 404'd and Monaco fell back to the
main thread ('Could not create web worker(s)...' console warning).

Add a graphiqlViteWorkers plugin that resolves the import to graphiql's
own setup-workers/vite variant (same workers via ?worker imports) in
client builds, leaving SSR resolution and the Next build untouched — app
source keeps the .../webpack specifier. The setup-workers chain is also
excluded from optimizeDeps: the Rolldown dep optimizer can't load ?worker
ids (UNLOADABLE_DEPENDENCY), so the modules must go through the normal
transform pipeline where Vite's built-in worker plugin handles them.

Verified: vite dev serves the vite setup-workers module for GraphiQLTab
with each ?worker import transformed into a WorkerWrapper constructor;
vite build emits json.worker/editor.worker/graphql.worker chunks; next
dev (turbopack) still compiles the graphiql route; tsc --noEmit clean.

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
- X-Content-Type-Options: 'no-sniff' -> 'nosniff' in all three header
  paths (security-headers.ts, next.config.ts, scripts/serve.js) — the
  old value is invalid, so MIME-sniffing protection was silently off.
- Unquote Manrope in fonts.css (stylelint).
- eslint-disable the compat shim's export * (barrel-files rule) — the
  shim's whole job is to mirror @sentry/react's surface.
- Extract the Monaco loader config shared by pages/_app.tsx and
  routes/__root.tsx into lib/configure-monaco-loader.ts so the asset
  path can't drift between the two runtimes.
- Deduplicate fileKey between useEdgeFunctionsDiff and
  EdgeFunctionsDiffPanel (matching must stay behaviourally identical).
- Prettier over compat/next/router{,.test}.ts and TANSTACK_MIGRATION.md
  (CI format failure).

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
- Replace the as-any casts around router.navigate/preloadRoute/
  buildLocation in the compat shims, nuqs adapter, and URL-shape test
  with TanStack's own loose generics (<AnyRouter, string>), which relax
  `to`/`search` typing at the library boundary without casts, and
  document why the loose generics are needed.
- Name the SplitInternalUrlResult interface and reuse SearchRecord in
  lib/internal-url.ts.
- Rename the boolean param consumeNext -> shouldConsumeNext in
  routes/index.tsx.

No behavior changes; typecheck, eslint, prettier, and all PR unit
tests stay green.

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
…path

#47182 dropped CDN loading for Monaco in every environment and moved the
locally-served assets from a flat public/monaco-editor/ layout into
public/monaco-editor/vs/. The Next entry (pages/_app.tsx) was updated to
match, but the TanStack root (routes/__root.tsx) still pointed loader.config
at ${BASE_PATH}/monaco-editor, so after that landed the loader looked for
loader.js at /monaco-editor/loader.js (404) and no Monaco editor mounted.

Mirror the Next config: serve from ${origin}${BASE_PATH}/monaco-editor/vs
for all environments, window-guarded since __root.tsx is also evaluated
during SSR. Fixes the app-wide Monaco breakage that was failing the TanStack
E2E shard (RLS policy editor, cron SQL, realtime JSON payload, database
functions, GraphiQL coexistence).
#47306 renamed Tailwind's sans var from --font-custom to --font-sans and added
--font-heading (Manrope), setting both via next/font on the Next build. The
TanStack fonts.css was never updated — it still only set the now-ignored
--font-custom, so --font-sans was unset and resolved to theme.css's fallback
chain (Circular, custom-font, Helvetica Neue, ...) i.e. system fonts, and
--font-heading/Manrope was missing entirely. Body text rendered as Helvetica at
weight 450, which is why the Inter weights looked wrong.

- fonts.css: set --font-sans (vendored Inter) and --font-heading (Manrope) to
  match what next/font provides on Next; drop the dead --font-custom.
- __root.tsx: load Manrope over the same Google Fonts <link> already used for
  Source Code Pro (Inter stays vendored via @font-face).

Verified against the built CSS bundle in a browser: computed body font-family is
now Inter (was the Circular/system fallback) and headings resolve to Manrope.
The unlayered :root wins over theme.css's @layer theme self-referential
--font-sans, same as the Next inline-style approach.
Follow-up to the font fix: drop the Google Fonts <link> and self-host all three
families via @font-face in fonts.css, matching next/font (which self-hosts them
on the Next build). Keeps self-hosted / offline studio working — no runtime CDN
dependency.

- Inter + Source Code Pro reuse the woff2 fonts/index.ts already ships.
- Manrope: vendored latin + latin-ext subset variable woff2 (fonts/manrope/,
  from @fontsource-variable/manrope) with the standard Google unicode-ranges;
  no italic axis. Weight ranges mirror fonts/index.ts.
- __root.tsx: remove the googleapis/gstatic preconnects + stylesheet link.

Verified in a browser against the built bundle: Inter (body), Manrope (headings)
and Source Code Pro (mono) all load from local /assets/*.woff2, and no
fonts.googleapis/gstatic references remain in the client output.
The Next build sets X-Frame-Options / X-Content-Type-Options / HSTS /
Content-Security-Policy / Referrer-Policy via next.config.ts `headers()`. The
TanStack build never carried these over — vercel.ts only set cache-control, so
the deployed dashboard shipped with no CSP.

The TanStack deploy serves a static shell (no server to attach headers), so the
headers go in the Vercel config. Add security-headers.ts as the shared source of
truth (reuses getCSP(), env-gated exactly like next.config) and:
- vercel.ts: apply to every response (source '/(.*)'), all base-path prefixes —
  full getCSP() + HSTS on platform, the deployed surface that matters.
- scripts/serve.js: apply the non-platform set (frame-ancestors 'none') for the
  self-hosted server, matching next.config's non-platform branch.

Note: font-src in the CSP is 'self' + cloudflare + supabase-assets (no
fonts.gstatic.com), so vendoring the fonts locally in the previous commit is what
keeps them CSP-compliant. X-Content-Type-Options keeps next.config's 'no-sniff'
value verbatim for parity.
GraphiQL's bundled Monaco ships the codicon icon font as a data: URI, and
Stripe's payment element inlines its fonts the same way, but font-src didn't
allow data: — so those fonts were blocked once the CSP is enforced (surfaced
while testing the CSP on the TanStack build; would affect the Next build too).

Verified in a browser: with the CSP applied, the data: font violations
(37 of them on a cold load) drop to zero, and the SQL editor Monaco renders.
Applies the review-feedback hunks that were skipped when these files
didn't exist on this branch yet: X-Content-Type-Options nosniff,
unquoted Manrope, and the shared configureMonacoLoader() extraction.

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
@alaister
alaister requested a review from a team as a code owner July 7, 2026 02:40
alaister added 2 commits July 7, 2026 16:51
The TanStack __root.tsx hardcoded the prod favicon route, so local and
hosted staging showed the prod icon. pages/_app.tsx passes /favicon/staging
to MetaFaviconsPagesRouter for non-prod (per Joshen's review) — mirror that
with the same synchronous NEXT_PUBLIC_ENVIRONMENT signal already used by
IS_DEV_TOOLBAR_ENABLED (the head() route option can't run _app's async CLI
check, but the env signal covers the reported local/staging case).

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
- splitInternalUrl: compare against the parse base's origin unconditionally
  (not gated on window) so SSR no longer treats external absolute URLs like
  https://supabase.com/docs as internal paths; client behavior unchanged.
- internal-url.test.ts: add SSR-mode cases (window stubbed undefined) —
  external absolute URL passes through untouched, relative path still splits.
- __root.tsx: extract shared IS_NON_PROD_ENV const used by both
  IS_DEV_TOOLBAR_ENABLED and FAVICON_ROUTE (behavior identical).

Claude-Session: https://claude.ai/code/session_01MLH8WVg8zBJnmZTYTV3ooo
alaister added a commit that referenced this pull request Jul 8, 2026
…rom #46424) (#47657)

Post-merge fixes for the TanStack Start migration (#46424) — things that
broke on the TanStack build as master evolved under the migration
branches. Kept on their own branch off master rather than piling onto
the E2E-matrix PR (#47119); all land on master and cascade up to S6 +
the big PR.

Common theme: a master PR changed something the Next pipeline handles
via `next/font` / `pages/_app.tsx` / `next.config.ts`, but the
hand-rolled TanStack equivalent (`routes/__root.tsx`,
`styles/fonts.css`, `vercel.ts`) wasn't updated to match — invisible on
the Next deploy, broken only on TanStack.

---

## 1. Monaco loader path (#47182)

#47182 re-nested the served Monaco assets from a flat
`public/monaco-editor/` layout into `public/monaco-editor/vs/` and
updated `pages/_app.tsx`, but `routes/__root.tsx` still pointed
`loader.config` at the old path, so `loader.js` 404'd and **no Monaco
editor mounted anywhere in the TanStack build**. Now mirrors the Next
config (`${origin}${BASE_PATH}/monaco-editor/vs`, window-guarded for
SSR). Was failing the whole `tanstack` E2E shard on #47119.

## 2. Inter + Manrope fonts (#47306)

#47306 renamed Tailwind's sans var `--font-custom` → `--font-sans` and
added `--font-heading` (Manrope), set via `next/font` on Next.
`fonts.css` still only set the now-ignored `--font-custom`, so the body
fell back to the theme's system chain (`Circular, custom-font,
Helvetica…`) at weight 450 — that's the "Inter weights look wrong".
Manrope was missing entirely.

- Wire `--font-sans` (Inter) + `--font-heading` (Manrope) to match
`next/font`.
- **Vendor all three families** (Inter, Manrope, Source Code Pro) via
`@font-face` so nothing depends on the Google Fonts CDN — matches
`next/font` self-hosting, and (see below) `font-src` doesn't allow
`fonts.gstatic.com` anyway.

Verified in-browser: computed `body` → `Inter`, headings → `Manrope`,
all loading from local `/assets/*.woff2`.

## 3. Security headers / CSP (next.config.ts `headers()`)

The Next build sets X-Frame-Options / X-Content-Type-Options / HSTS /
**Content-Security-Policy** / Referrer-Policy via `next.config.ts`. The
TanStack build never carried these over — `vercel.ts` only set
cache-control, so **the deployed TanStack dashboard shipped with no CSP
at all**.

The TanStack deploy serves a static shell (no server to attach headers),
so they go in the Vercel config:
- `security-headers.ts` — shared source of truth, reuses `getCSP()`,
env-gated exactly like next.config.
- `vercel.ts` — apply to every response (all base-path prefixes): full
`getCSP()` + HSTS on platform.
- `scripts/serve.js` — the non-platform set (`frame-ancestors 'none'`)
for the self-hosted server.

**Tested the policy in a real browser** (temporarily enforced it on the
TanStack build via /test-supabase-local): everything passed except one
real gap — `font-src` was missing `data:`, so GraphiQL's bundled Monaco
codicon font and Stripe's payment-element fonts (both data: URIs) were
blocked (37 violations on a cold load). Added `data:` to `font-src` in
`csp.ts` → violations drop to zero, SQL editor Monaco renders clean.
That gap affects the Next build too.

---

## 4. `node:path` import crashing `/project/[ref]/merge`

Found by a full-site click-through of the TanStack build (all product
areas, ongoing — see below). `useEdgeFunctionsDiff.ts` +
`EdgeFunctionsDiffPanel.tsx` did `import { basename } from 'path'` in
client code. Webpack (Next) polyfills `path` in the browser; Vite
externalizes it, so the whole `/merge` route crashed with "Module
\"path\" has been externalized for browser compatibility". Replaced the
two `basename` call sites with a string helper. Verified in-browser:
`/merge` renders.

## 5. URL shape — Next-style search-param semantics + shim fixes

The dashboard produced malformed URLs vs the Next build (strange query
params, trailing slashes, `##` hashes). Root cause + audit verified
empirically against `@tanstack/[email protected]`; all fixed with
unit tests and browser-verified:

- **`createRouter` used TanStack's default JSON search codec** —
`?flag=true` became `?flag=%22true%22` via links, repeated
`?filter=…&filter=…` collapsed into a JSON array (breaking
multi-filter/sort table-editor URLs and the account-page round-trip,
which double-encoded), and search values arrived as numbers/booleans
where the app expects strings. New `lib/router-search-params.ts`
(Next-style: strings in, strings out, repeated keys → string[]) wired
into the router.
- **Link shim** (`compat/next/link.tsx`): `URL.hash` includes the
leading `#` while TanStack's `hash` prop adds its own → every
`href="…#section"` navigated to `##section` (hash-scroll broke);
`Object.fromEntries(searchParams)` dropped repeated query params. Both
fixed.
- **Trailing slash injected before the query** on every `?`-only
relative navigation (`/auth/providers/?provider=…`): fixed in the compat
router (prefix current pathname) and via a custom nuqs adapter
(`lib/nuqs-tanstack-adapter.tsx`) replacing the stock tanstack-router
adapter, whose `navigate({ to: '?…' })` writes hit the same TanStack
behavior (123 files use nuqs).
- **Pathname-less `router.push({ query })` leaked path params** — Next
re-consumes `ref`/`id` from `query` into the path pattern; the shim
didn't, yielding
`/editor/17597?schema=public&ref=<ref>&id=17597&filter=…` from
table-editor filter/sort, linter panels, and advisor shortcuts. The shim
now defaults the pathname to the current route pattern and backfills
omitted params.
- **Redirects dropped query + hash** (Next's `redirects()` preserves
them): `__root.tsx` `matchRedirect` and `routes/index.tsx` now carry
incoming params/hash through (consumed rule params excluded,
destination's own params win). `/?next=new-project&projectName=zzz` →
`/new/new-project?projectName=zzz`; `/sql/quickstarts?template=x#frag` →
`/sql/examples?template=x#frag`.

Browser-verified post-fix: advisors `?preset=WARN`, providers
`?provider=Google`, `?schema=auth` — all clean (no `/?`, no leaks);
repeated `filter` params survive hydration; `=true` unquoted; single
`#`.

## 6. TanStack `navigate` corrupting query values (Logs Explorer SQL
newline loss)

TanStack router-core treats a query string embedded in `navigate({ to
})` as part of the *path*: `decodePath` percent-decodes it and
`sanitizePathSegment` strips control characters, silently deleting every
`%0A`. Logs Explorer's SQL (`s` param) lost its newlines on Run/reload —
`order by timestamp desc` / `limit 5` glued into `desclimit 5`, which
then failed the LIMIT lint. Pre-existing on the TanStack build (the
stock nuqs adapter had the same shape); Next unaffected.

Fixed by never embedding query strings in `to`: the nuqs adapter and the
compat `router.push`/`replace`/`prefetch` (plus the `next/navigation`
shim) now pass search as an object through the app codec
(`splitInternalUrl` hoisted to `lib/internal-url.ts`). Guard test drives
a real `createRouter` with multi-line SQL through both producers.
Browser-verified: newlines survive the full Run → reload → re-Run cycle.

## 7. Integration overview markdown never loaded (all integrations)

`MarkdownContent` used a template-literal dynamic import
(``import(`@/static-data/integrations/${id}/overview.md`)``) — webpack
builds a context module for that, Vite can't analyze it, so every
integration detail page threw `Failed to resolve module specifier` and
rendered no overview text. Fixed with an explicit lazy registry of
literal imports (`static-data/integrations/overviews.ts`, drift-guarded
by a test) plus an `mdRawLoader()` Vite plugin mirroring next.config's
turbopack raw-loader rule. Both runtimes keep working; md stays out of
the main bundle.

## 8. GraphiQL editor never mounted (`exports is not defined`)

Our `umdAmdShortCircuit()` Vite plugin (which disarms Monaco's global
AMD loader for deps like papaparse) rewrote `typeof define ===
'function' && define.amd` to `false` inside `monaco-editor`'s bundled
copy of marked — whose UMD relies on its own *local* `define` shim — so
the whole optimized monaco chunk failed to evaluate and GraphiQL's
editor pane stayed blank. The check now only short-circuits when
`define` is the global AMD loader. Browser-verified: all four GraphiQL
Monaco panes mount, queries execute. (Known follow-up: GraphiQL's Monaco
workers fall back to the main thread under Vite — functional, worker
wiring is Next-specific `setup-workers/webpack`.)

## 9. `@sentry/nextjs` bundling Next internals — built TanStack bundle
crashed (caught by E2E)

The E2E suite against the **built** TanStack bundle (not the dev server)
found lazy chunks like `table-editor-*.js` dead on arrival:
`@sentry/nextjs` (imported by ~25 client files) drags in
`next/dist/shared/lib/constants`, whose module scope evaluates
`process?.features?.typescript` — optional chaining doesn't guard an
undeclared `process` in the browser, so the whole chunk failed at load
with `ReferenceError: process is not defined`. Dev shims `process`,
which is why weeks of dev-server testing never saw it.

Fixed by aliasing `@sentry/nextjs` → `compat/sentry-nextjs.ts`
(re-exports `@sentry/react`, same deduped 10.59.0, plus explicit
stand-ins for the three Next-only APIs) in the Vite build only.
Verified: fresh build has zero Next-internals markers in any chunk;
table editor loads clean; full E2E suite run against the built bundle.

Note for the stack: `alaister/tanstack-start` / the E2E-matrix branch
already carried a different fix for the same crash (a `next/constants`
shim) that never made it to master — the cherry-pick onto those branches
keeps **both** (the shim covers any other transitive importer; the alias
keeps Next internals out of the client bundle entirely).

**Follow-up found while fixing:** Sentry is never *initialized* in the
TanStack runtime — `instrumentation-client.ts` /
`sentry.server.config.ts` are Next-convention files nothing imports
under TanStack, so `captureException` calls are silent no-ops. Needs an
`@sentry/react` init (+ `tanstackRouterBrowserTracingIntegration`) wired
into the TanStack client entry as its own PR.

## 10. GraphiQL Monaco workers + edge-function Deno typings (Vite-only
gaps)

- **GraphiQL's Monaco workers ran on the main thread** under Vite
("Could not create web worker(s)…" — `setup-workers/webpack`'s `new
URL(...)` form isn't rewritten by Vite). A `graphiqlViteWorkers()`
plugin resolves the import to graphiql's own `setup-workers/vite`
variant for client builds (SSR untouched, Next untouched); the
setup-workers chain is `optimizeDeps.exclude`d because the Rolldown
optimizer can't load `?worker` ids.
- **Edge-function editors silently lost their Deno typings** —
`AIEditor` loaded `public/deno/*.d.ts` via `/* @vite-ignore */` imports
that always failed at runtime under Vite. The `.md` raw loader is
generalized into `rawTextLoader` (exact-path allowlist for the two
typings files, served as virtual string modules so the dep scanner never
parses `.d.ts` syntax), and the imports are now static-analyzable
literals that both bundlers handle (turbopack's raw-loader rules match
them on the Next side).

## Split out for reviewability

App-level fixes that reproduce on the Next build too (DOM-nesting
hydration errors, the ghost deleted-snippet nav, the recurring pg-meta
`migrations` 400) moved to their own PR: #47667. Sentry initialization
for the TanStack runtime (captures were silent no-ops) is #47666,
stacked on this PR.

## Full-site test campaign

Drove every dashboard product area on the local TanStack build
(Playwright, human-style) hunting migration regressions:
redirects/404/catch-alls, org, account, project home/branches/merge,
table editor CRUD, SQL editor (Monaco/run/save/templates/AI), all
database pages, all auth pages, storage CRUD, edge functions + realtime,
logs/observability, advisors, settings, integrations hub incl. nested
routes, global UI (palette/connect/switchers/theme/fonts), and a
cross-cutting sweep (document titles, back/forward chain, hard-refresh
hydration on deep URLs, trailing-slash active state). Every failure
found is fixed above and re-verified in-browser; remaining console
quirks were cross-checked against the deployed Next build and are
pre-existing (tracked separately).

## To test

Most fixes are already browser-verified + covered by unit tests and the
self-hosted E2E suite; the last two landed after the final browser pass
and still need an in-browser check:

1. **GraphiQL Monaco workers** — restart the dev server (clear
`apps/studio/node_modules/.vite` once first — the optimizer cache may
hold a stale prebundle of the worker chain). Open
`/project/<ref>/integrations/graphiql/graphiql` with the console open:
the `Could not create web worker(s). Falling back to loading web worker
code in main thread` warning must be gone, and DevTools → Sources →
Threads shows the three workers (json, editor, graphql). Autocomplete in
the query editor stays responsive.
2. **Edge-function Deno typings** — `/project/<ref>/functions/new`: no
"Failed to load … typings" console error, and typing `Deno.` in the
editor offers typed completions (e.g. `Deno.env`).

Spot-checks for the rest (all previously verified):
- `/project/<ref>/merge` renders (no "Module path" crash).
- Multi-line SQL in Logs Explorer survives Run → reload (no `desclimit`
gluing, no LIMIT-lint false failure); `s` param keeps `%0A`.
- `/auth/providers` → open a provider → `?provider=…` with no trailing
slash before `?`; table-editor filter/sort URLs carry no leaked
`ref`/`id` params; `/?next=new-project&projectName=x` lands on
`/new/new-project?projectName=x`.
- Integration detail pages (cron/queues/vault/data_api) show their
overview prose; GraphiQL query editor mounts.
- Built bundle (`MODE=test vite build` + `start:tanstack`): table editor
loads with no `process is not defined`.
- `curl -sI` any page on a platform deploy: `X-Content-Type-Options:
nosniff` (was the invalid `no-sniff`).


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Centralized integration overview markdown loading with registry-based
lookup.
* Improved Monaco loading/asset path handling for smoother editor
startup.
* **Bug Fixes**
* Next-style navigation/search handling now preserves pathname, hash,
repeated query keys, and special characters (including newlines).
* Redirects now reliably carry over query and hash with correct
precedence.
* **Security/Configuration**
* Updated CSP font sourcing and unified security headers delivery across
environments; conditional HSTS behavior.
* Refreshed font CSS variables and font-face definitions to match the
theme.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->


---

### Review feedback: non-prod favicon (Joshen)

The TanStack `__root.tsx` hardcoded the prod favicon; local + hosted
staging now use the white staging favicon (`/favicon/staging`), matching
what `pages/_app.tsx` passes to `MetaFaviconsPagesRouter` for non-prod.
Rather than pull the pages-router component into the TanStack head, it
reuses the same synchronous `NEXT_PUBLIC_ENVIRONMENT` signal the file
already uses for `IS_DEV_TOOLBAR_ENABLED` (the `head()` route option
isn't a React component, so it can't run `_app`'s async CLI check — but
the env signal covers the reported local/staging case).

---------

Co-authored-by: Alaister Young <[email protected]>
Co-authored-by: Joshen Lim <[email protected]>
…s6-e2e-matrix

Resolve vite.config.ts: drop the stack-only next/constants alias + its
compat shim (master fixes the Next-internals crash via the @sentry/nextjs
alias alone, which both sides have).
@alaister
alaister enabled auto-merge (squash) July 10, 2026 10:09
@alaister
alaister merged commit 55f5676 into master Jul 10, 2026
35 checks passed
@alaister
alaister deleted the alaister/migration-s6-e2e-matrix branch July 10, 2026 10:09
@github-actions

github-actions Bot commented Jul 10, 2026 •

Copy link
Copy Markdown
Contributor

Braintrust eval report

Assistant (master-1783678330)

Score Average Improvements Regressions
Knowledge Usage 97.4% (+5pp) 2 🟢 -
SQL Identifier Quoting 100% (+0pp) - -
SQL Validity 100% (+0pp) - -
Tool Usage 74.5% (+2pp) 2 🟢 1 🔴
Time_to_first_token 2.94tok (-0.61tok) 13 🟢 16 🔴
Llm_calls 3.07 (-0.24) 7 🟢 17 🔴
Tool_calls 2.97 (+0.03) 9 🟢 10 🔴
Errors 5.28 (+0.05) 2 🟢 4 🔴
Llm_errors 0 (+0) - -
Tool_errors 0 (+0) - -
Prompt_tokens 24646.49tok (+2977.08tok) 11 🟢 14 🔴
Prompt_cached_tokens 8515.68tok (+1041.66tok) 9 🟢 18 🔴
Prompt_cache_creation_tokens 0tok (+0tok) - -
Prompt_cache_creation_5m_tokens 0tok (+0tok) - -
Prompt_cache_creation_1h_tokens 0tok (+0tok) - -
Completion_tokens 616.74tok (+19.25tok) 15 🟢 14 🔴
Completion_reasoning_tokens 94.52tok (-10.23tok) 18 🟢 9 🔴
Total_tokens 25263.23tok (+2996.33tok) 13 🟢 16 🔴
Estimated_cost 0$ (+0$) 10 🟢 19 🔴
Duration 16.82s (-0.75s) 17 🟢 12 🔴
Llm_duration 11.68s (-1.11s) 18 🟢 11 🔴

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.

4 participants