Skip to content

Conversation

@mhsnook
Copy link
Owner

@mhsnook mhsnook commented Nov 12, 2025

Testing checklist:

Test rpc forms:

  • new phrase / card / translation
  • bulk add phrases
  • insert card review
  • update card review
  • fulfill_phrase_request

Collections based on views where we insert rows after create:

  • decksCollection: DeckMetaSchema parse a new row from user_deck and match a user_deck_plus
  • phrasesCollection: PhraseFullSchema parse a new row from phrase and match a meta_phrase_info(*, translations)
  • cardsCollection: CardMetaSchema parse a new row from user_card and match a user_card_plus
  • friendSummariesCollection: FriendSummarySchema parse a new row from friend_request_action and match a friend_summary

Mutations to check:

  • add-tags.tsx: 57: addTagsMutation 🏗️
  • add-translations-dialog.tsx: 51: addTranslation
  • card-status-dropdown: 107: useCardStatusMutation
  • password-reset-form.tsx: 24: changeMutation
  • send-phrase-to-friend-button.tsx: 34: sendPhraseToFriendMutation
  • send-request-to-friend-dialog.tsx: 30: sendRequestToFriendMutation
  • use-friends.ts: 62: useFriendRequestAction
  • use-reviews: 151: useReviewMutation
  • hooks.ts: 23: useSignOut
  • mutate-deck.ts: 28: useNewDeckMutation
  • forgot-password.tsx: 31: recoveryMutation
  • login.tsx: 45: loginMutation
  • signup.tsx: 56: signupMutation
  • accept-invite.tsx: 51: acceptOrDeclineMutation
  • getting-started.tsx: 90: mainForm
  • chats.$friendUid.recommend.tsx: 42: sendMessageMutation
  • -archive-deck-button.tsx: 36: mutation
  • $lang.add-phrase.tsx: 101: addPhraseMutation
  • $lang.bulk-add-tsx: 96: bulkAddMutation – works with multiple phrases with multiple translations (and shows the results below)
  • $lang.deck-settings: 114: updateDailyGoalMutation
  • $lang.deck-settings: 226: updateDailyGoalMutation
  • $lang.requests.$id.tsx: 81: fulfillMutation
  • $lang.requests.new.tsx: 61: createRequestMutation
  • $lang.review.index.tsx: 186: in ReviewPageSetup
  • -avatar-editor-field.tsx: 53: sendImage
  • -update-profile-form.tsx: 40: updateProfile
  • change-email.tsx: 31: changeMutation

Funny Auth/Loading issues to check:

  • SignIn never shows an un-auth'd or no-profile FOUC or redirect
  • Cannot manage to trigger an infinite-loader even with different cache states and conx throttling
  • Route loaders suspend until loaded (No flashes of empty content; useProfile checks in Route components never return false)
  • Logout removes profile and other user data
  • Login fetches new profile and user data

Checking logic under the hood:

  • Reviews can be edited (without creating new reviews)
  • Second reviews get marked with new records but with the prev values and day_first_review=false

We should remove these before merging to main, but will keep them during QA
because these hanging bugs are a little difficult to predict and reproduce.
Sometimes when submitting a form, the form goes into "submitting" (disabled)
state, but there's no network request and no Zod error. Refreshing often
fixes it, but we really want to get rid of these errors before we ship.
This should be a distinction without a difference, but just to be safe, we
are now mirroring this structure directly:
https://tanstack.com/router/v1/docs/framework/react/how-to/setup-auth-providers#4-update-app-configuration
Merge the `tanstack/db` branch, converting everything to live queries
* Add Playwright for e2e testing
* Add super basic test for the login to ensure auth guard and redirect are working
* Add spec for add-phrase & bulk-add-phrases
* Add stubs for specs for all mutations across the app
* Add proper types to the db-helpers file
* Add working cards spec to test card status dropdown and heart icon
* Document the pattern to check results in both the DB and UI
* Add requests spec
* Always put toasts last so we can use them to await interactions
* Write up some ideas for ideal testing framework
* Add spec for decks
* Add reviews.spec, and both-helpers to compare db to local
* Make everything less flakey
@mhsnook mhsnook changed the title Merge big tanstack/db changes Merge of Tanstack/DB replacing Query, and Playwright tests Dec 1, 2025
@mhsnook
Copy link
Owner Author

mhsnook commented Dec 1, 2025

As of now, we've got 17 out of 43 of these items covered by the test suite.

Of the un-covered, all but two have been confirmed from human observation.

  • There's still some concerns about the race condition possibilities in the supabase client's global lock.
  • There's a concern about whether review edits are editing correctly from the RPC.

The first one I think we may just have to ship it and see. The second one I want to check prod -- if the bug exists there then we actually may not bother to solve it today and just ship this, and fix it first thing after (with a new test).

Update: The bug is not present in production (phew)

@mhsnook mhsnook closed this Dec 1, 2025
@mhsnook mhsnook reopened this Dec 1, 2025
@supabase
Copy link

supabase bot commented Dec 1, 2025

Updates to Preview Branch (next) ↗︎

Deployments Status Updated
Database Fri, 05 Dec 2025 20:30:11 UTC
Services Fri, 05 Dec 2025 20:30:11 UTC
APIs Fri, 05 Dec 2025 20:30:11 UTC

Tasks are run on every commit but only new migration files are pushed.
Close and reopen this PR if you want to apply changes from existing seed or migration files.

Tasks Status Updated
Configurations Fri, 05 Dec 2025 20:30:12 UTC
Migrations Fri, 05 Dec 2025 20:30:41 UTC
Seeding Fri, 05 Dec 2025 20:30:55 UTC
Edge Functions Fri, 05 Dec 2025 20:30:57 UTC

View logs for this Workflow Run ↗︎.
Learn more about Supabase for Git ↗︎.

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.

Possible bug in "most_recent_review_at" Refactor useDeckPidsAndRecs / filteredPhrasesMap to use smarter derived state

2 participants