refactor: remove the Supabase dependency surface from the repo - #26
Merged
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (31)
🔥 Files not summarized due to errors (1)
📝 WalkthroughWalkthroughThe repository removes Supabase configuration and SDK references, documents Better Auth with Neon Postgres and Cloudflare R2, updates deployment procedures and privacy policies, and regenerates the dependency graph report. ChangesProvider migration cleanup
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related issues
Possibly related PRs
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #8. Completes the Phase 12 migration — Supabase is now gone from every tracked file except two deliberate historical notes.
What changed
@supabase/supabase-jsremoved from both workspaces;backend/src/config/supabase.tsdeleted (it had zero importers — dead since Migrate cached GeoTIFF and imagery storage to Cloudflare R2 #5);supabase/directory deleted (7 tracked files: config, theprofilesmigration, and the 4 email templates already ported tobackend/src/emails/in Send verification and password-reset email directly via Resend #7). Lockfile shed 86 lines.SUPABASE_URL/SUPABASE_SERVICE_ROLE_KEYdropped from theenv.tsZod schema; the dead Supabase andSITE_URLblocks removed from.env.example.README.md,RUNBOOK.md, anddocs/trd.mdretargeted to Neon / Cloudflare R2 / Better Auth / Resend HTTP. RUNBOOK §6 ("Sync Supabase auth config") deleted and §7–§11 renumbered; every TOC anchor re-verified.Two fixes beyond the cleanup
A boot-breaking regression from #6.
env.tsrequiredBETTER_AUTH_SECRETandBETTER_AUTH_URL, but.env.examplenever listed them — a fresh clone following the documented setup could not start the backend. CI never catches this because CI never boots from.env.example. Now verified programmatically: every required Zod key is present.The PDPA privacy policy was legally wrong, not just stale. All three locales named Supabase as a data processor for Auth/Postgres/Storage and omitted Resend entirely — a processor that genuinely receives user email addresses. They also claimed row-level security protects user records; RLS no longer exists, authorization is enforced in the Express layer against the Better Auth session. Session storage was described as browser storage when it is now an HTTP-only cookie.
lastUpdatedbumped accordingly.Review found three defects in generated content
Implementation ran as four parallel Codex workers on disjoint scopes. Every mechanical deletion was correct; the one section written from scratch (RUNBOOK §3.2 Neon/R2) carried three defects, all fixed before commit:
config:setomittedconnect_timeout=15&pool_timeout=20— copy-pasting it would have redeployed the exact Neon cold-start 500 fixed earlier the same day.pool_timeout=20absent from the whole file, despite.env.exampledocumenting it as load-bearing (Prisma's 10 s pool default otherwise defeats the larger connect timeout).Deliberately not done
Heroku config vars untouched. The app holds 4 stale
SUPABASE_*vars plusSITE_URLand 2VITE_SUPABASE_*, and is missing every new required var — it cannot boot either way. Removing the dead ones alone fixes nothing, and setting the new ones presumes Heroku wins the hosting decision #9 exists to make. Deferred to #9 as one atomic cutover.GitHub Actions needed no change — only
HEROKU_API_KEYandHEROKU_APP_NAMEwere ever set. The issue assumed Supabase secrets that were never there.Two scope corrections to the issue text
frontend/vite.config.tsnever referenced Supabase — theVITE_SUPABASE_*lines live in the gitignoredvite.config.jsbuild artifact. And.github/workflows/ci-cd.ymlhad zero Supabase references.Verification
git ls-files -z | xargs -0 grep -il supabase→ onlybackend/src/config/auth.tsandprisma/schema.prisma, both deliberate historical notesprivacy.jsonlocales verified to have identical key structure (28 leaves each)https://claude.ai/code/session_01J6uoj2LBZBMeEkfyx3Bvn8
Summary by CodeRabbit
New Features
Documentation
Chores