Repository navigation
fix(growth): stop misreporting unlock_click as a dead event in the funnel - #81
Merged
Merged
Conversation
…nnel FUNNEL_STEPS's own header claimed unlock_click "is emitted by no code since the subscription pivot" -- false: SectionRenderer.tsx and LockedReviewer.tsx both still fire it live, at /unlock, where the price is first quoted. lib/adminFunnel.ts already treats it as live (removed from DEAD_EVENT_TYPES, charted as "Reached Unlock"); the growth funnel's own dead-event check was the only place still misreporting it. Adds unlock_click to FUNNEL_STEPS between paywall_teaser_click and subscribe_click (the live path's own order), corrects the header, and adds a matching windowed count to growth_funnel_agg's steps CTE via a new migration -- same signature, same permissions, no new grant. Closes #32.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This branch was successfully deployed
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.
Summary
Fixes #32. `lib/reports/funnel.ts`'s own header claimed `unlock_click` "is emitted by no code since the subscription pivot" — false: `SectionRenderer.tsx` and `LockedReviewer.tsx` both still fire it live, at `/unlock`, where the price is first quoted. `lib/adminFunnel.ts` already treats it as live (removed from `DEAD_EVENT_TYPES`, charted as "Reached Unlock"); the growth funnel's own dead-event check was the only place still misreporting it.
This repo has no `supabase db push` workflow — every `growth_`/`admin_` aggregate is applied by hand in the Supabase Studio SQL editor. Merging this PR does not apply the migration. A verification checklist is included (`20260904000000_growth_funnel_agg_unlock_click.test.md`, mirroring the original migration's own checklist) for whoever applies it to run through, including re-confirming the anon-role permission check still rejects (the single most load-bearing check on any `growth_*` aggregate, per the original migration's own `.test.md`).
Test plan