|
| 1 | +# PR_26167_185-dev-creator-identity-seed-sync |
| 2 | + |
| 3 | +## Overall Result |
| 4 | + |
| 5 | +FAIL / blocked. |
| 6 | + |
| 7 | +The implementation was prepared and targeted validation passed, but the live DEV seed/sync could not complete because Supabase Auth rejected the requested User 1/User 2/User 3 password values as shorter than the project minimum password length. Supabase returned HTTP 422: password must be at least 6 characters. Supabase settings were not changed. |
| 8 | + |
| 9 | +## Branch Validation |
| 10 | + |
| 11 | +PASS - current branch was `main` before changes. |
| 12 | + |
| 13 | +## Requirement Checklist |
| 14 | + |
| 15 | +- PASS - Read `docs_build/dev/PROJECT_INSTRUCTIONS.md` first. |
| 16 | +- PASS - Hard stop branch check passed on `main`. |
| 17 | +- PASS - DEV-only sync path added under server-side scripts/runtime testing code. |
| 18 | +- FAIL - Requested User 1/User 2/User 3 passwords could not be applied; Supabase Auth rejected the requested short values. |
| 19 | +- PASS - DavidQ seed name is `DavidQ`, not `DavidQ admin`. |
| 20 | +- PASS - DavidQ is not statically seeded as admin; explicit existing admin assignments are preserved when present. |
| 21 | +- FAIL - Extra codex/qbytes DEV accounts were identified but not deleted because the live sync hard-stopped before cleanup. |
| 22 | +- FAIL - Auth users and `public.users` were not fully synced in DEV because the live sync failed. |
| 23 | +- PASS - `authProvider="supabase-auth"` and real `auth.users.id` sync behavior is implemented in the server-side sync path. |
| 24 | +- PASS - `creator` is the default authenticated Creator role in seed data and create-account provisioning. |
| 25 | +- PASS - `guest` remains available for unauthenticated browsing. |
| 26 | +- PASS - `admin` is retained only as an explicit assignment. |
| 27 | +- PASS - `roleSlug=user` is marked inactive/deprecated in seed data. |
| 28 | +- PASS - Dev-static seed docs/data and server-side seed/setup scripts were updated. |
| 29 | +- PASS - Seeding remains server-side only. |
| 30 | +- PASS - No SQLite/local-db fallback was added. |
| 31 | +- PASS - No browser-owned user records were added. |
| 32 | +- PASS - Startup wording reports configured account/product-data connections; script name retained as legacy command naming only. |
| 33 | + |
| 34 | +## Before/After Identity Counts |
| 35 | + |
| 36 | +Live sync hard-stopped before mutation. A dry-run snapshot after the failed attempt reported: |
| 37 | + |
| 38 | +| Count | Before | After Dry Run | |
| 39 | +| --- | ---: | ---: | |
| 40 | +| Supabase Auth users | 12 | 12 | |
| 41 | +| `public.users` rows | 12 | 12 | |
| 42 | +| Canonical Auth identities | 2 | 2 | |
| 43 | +| Canonical `public.users` identities | 3 | 3 | |
| 44 | +| Managed extra Auth identities | 10 | 10 | |
| 45 | +| Managed extra `public.users` identities | 8 | 8 | |
| 46 | + |
| 47 | +Actual created records: 0. |
| 48 | + |
| 49 | +Actual deleted records: 0. |
| 50 | + |
| 51 | +## Deleted DEV Account List |
| 52 | + |
| 53 | +No live deletions were performed because the sync failed before cleanup. |
| 54 | + |
| 55 | +Dry-run cleanup candidates identified: |
| 56 | + |
| 57 | +- `codex-pr162-1781561056924-35f5412b0f339@example.com` |
| 58 | +- `codex-pr162-1781561106580-fe3f2462707fc@example.com` |
| 59 | +- `codex-pr163-repeat-1781562780241-ccbc9d07d9f97@example.com` |
| 60 | +- `codex-pr163-success-1781562780241-ccbc9d07d9f97@example.com` |
| 61 | +- `codex-pr156-missing-identity-1781555713293-c32794@example.test` |
| 62 | +- `codex-pr156-admin-probe-1781554902135-23gra6@example.com` |
| 63 | +- `qbytes.dq1@gmail.com` |
| 64 | +- `qbytes.dq2@gmail.com` |
| 65 | +- `qbytes.dq3@gmail.com` |
| 66 | +- `qbytes.dq4@gmail.com` |
| 67 | + |
| 68 | +## Auth/Public Users Sync Evidence |
| 69 | + |
| 70 | +Dry-run verification, with Auth IDs omitted: |
| 71 | + |
| 72 | +- `user1@example.invalid`: Auth present, `public.users` present, not synced to real Auth ID yet. |
| 73 | +- `user2@example.invalid`: Auth missing, `public.users` present. |
| 74 | +- `user3@example.invalid`: Auth missing, `public.users` present. |
| 75 | +- `qbytes.dq@gmail.com`: Auth present, `public.users` missing. |
| 76 | + |
| 77 | +Creator role assignments were not present for the four canonical identities in live DEV at dry-run time. |
| 78 | + |
| 79 | +## Validation Lane Report |
| 80 | + |
| 81 | +- PASS - `node --check` for changed JS/MJS files. |
| 82 | +- FAIL - `node .\scripts\validate-supabase-dev.mjs`; local TLS trust failed with `UNABLE_TO_VERIFY_LEAF_SIGNATURE` / `SELF_SIGNED_CERT_IN_CHAIN`. |
| 83 | +- PASS - `npm run validate:supabase-dev`; REST/API readiness passed, direct PostgreSQL TLS warning remained advisory. |
| 84 | +- FAIL - `node --use-system-ca .\scripts\sync-supabase-dev-creator-identities.mjs --json`; Supabase Auth HTTP 422 for requested short passwords. |
| 85 | +- PASS - `node --use-system-ca .\scripts\sync-supabase-dev-creator-identities.mjs --dry-run --json`. |
| 86 | +- PASS - `node --test tests/dev-runtime/SupabaseDevCreatorIdentitySeedSync.test.mjs`. |
| 87 | +- PASS - `node --test tests/dev-runtime/SupabaseProductDataCutover.test.mjs`. |
| 88 | +- PASS - Targeted provider contract tests for Auth admin methods, auth routes, create-account provisioning, and Supabase session/product read path. |
| 89 | +- TIMEOUT - Full `node --test tests/dev-runtime/SupabaseProviderContractStub.test.mjs` did not complete within 240 seconds; targeted changed cases passed. |
| 90 | +- PASS - `npm run dev:local-api` startup check on port 55185 returned HTTP 200 for `/api/auth/status`; startup logs contained no SQLite/local-db/provider-selection wording. |
| 91 | +- PASS - `npx playwright test tests/playwright/account/SupabaseSignInSession.spec.mjs --project=playwright --workers=1 --reporter=list`. |
| 92 | +- PASS - `npm run test:workspace-v2`. |
| 93 | + |
| 94 | +Playwright V8 coverage report: `docs_build/dev/reports/playwright_v8_coverage_report.txt`. |
| 95 | + |
| 96 | +## Manual Validation Notes |
| 97 | + |
| 98 | +- Live DEV sign-in with the requested canonical short passwords was not validated because Supabase Auth rejected those passwords before sync completed. |
| 99 | +- No UAT/PROD resources were touched. |
| 100 | +- No `.env.local` or secret files were changed. |
| 101 | +- No password values are recorded in this report. |
| 102 | +- Startup command remains `scripts/start-local-api-server.mjs`; report and logs treat that as legacy command naming only. |
0 commit comments