Skip to content

chore(dev/journey): mirror lifecycle v2 spec — step ladder, win_back, finish_setup removal - #2731

Merged
Hugo0 merged 1 commit into
devfrom
journey-lifecycle-v2
Aug 18, 2026
Merged

chore(dev/journey): mirror lifecycle v2 spec — step ladder, win_back, finish_setup removal#2731
Hugo0 merged 1 commit into
devfrom
journey-lifecycle-v2

Conversation

@Hugo0

@Hugo0 Hugo0 commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Companion to peanutprotocol/peanut-api-ts#1360 (lifecycle machine v2). The /__dev/journey-spec response changed shape and the dev journey board must mirror it:

  • SpecRules.stepAfterDays (array) replaces step1AfterDays/step2AfterDays — stages now carry 2 or 3 steps; RulesLegend maps over the ladder and shows the new dormancyDays and maxSendsPerDay rules.
  • win_back stage mapped to the (renamed) "Spent → dormant" column — going quiet for 6 weeks re-enters the machine.
  • finish_setup removed: its column documents why the machine is silent there by design; its settled kill-or-keep decision flag is retired.

Task

Notion: Activation machine — reach the users it cannot see (Sprint 156)

Risks / breaking changes

Dev-only surface (/dev/journey); no production UI touched. useJourneySpec degrades gracefully against an old API, so merge order with api#1360 is not load-bearing — but the board only renders the new rules once both are deployed.

QA

Typecheck clean · full suite 3,110 passed (journey suites 24/24) · prettier applied.

Screenshots: N/A (dev-only tooling board; no customer-visible change)

…sh_setup gone

Companion to peanut-api-ts#1360, which changed the /__dev/journey-spec shape:
rules.stepAfterDays replaces the two fixed step fields (stages now carry 2 or
3 steps), dormancyDays and maxSendsPerDay are new, finish_setup no longer
exists, and win_back does. The board maps win_back to the spent column (going
quiet for 6 weeks re-enters the machine), the application-in-flight column
documents why it is silent by design, and the settled finish_setup
kill-or-keep decision flag is retired.
@vercel

vercel Bot commented Aug 18, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
peanut-wallet Ready Ready Preview Aug 18, 2026 3:07pm

Request Review

@coderabbitai

coderabbitai Bot commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: fc718975-a290-4309-aebd-4d9b7f31e83f

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

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

@github-actions

Copy link
Copy Markdown
Contributor

Code-analysis diff

Painscore total: 7161.25 → 7161.85 (+0.6)
Findings: 0 net (+1 new, -1 resolved)

🆕 New findings (1)

  • medium complexity — src/app/(mobile-ui)/dev/journey/emailReview.ts — CC 15, MI 66.61, SLOC 60

✅ Resolved (1)

  • src/app/(mobile-ui)/dev/journey/emailReview.ts — CC 15, MI 65.52, SLOC 66

@github-actions

Copy link
Copy Markdown
Contributor

🧪 UI test report — ✅ all green

Suites

  • unit: 3113 ran, 0 failed, 0 skipped, 56.4s

📊 Coverage (unit)

metric %
statements 67.2%
branches 52.2%
functions 57.7%
lines 68.0%
⏱ 10 slowest test cases
time test
4.1s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › never places two stickers in heavy overlap (broad seed sweep)
1.1s src/utils/__tests__/demo-api.test.ts › isDemoMode() is false when not running under Capacitor
0.4s src/components/Card/share-asset/__tests__/shareAssetLayout.test.ts › every sticker stays within canvas at any count
0.4s src/app/actions/__tests__/api-headers.test.ts › should include Content-Type in validateInviteCode
0.3s src/utils/__tests__/sentry.utils.test.ts › defaults to the client budget under a browser global
0.3s src/utils/__tests__/auth-token.test.ts › ignores the guarded marker and falls back to the plain token
0.3s src/utils/__tests__/auth-token.test.ts › is none — never guarded — when only the guarded marker is present
0.3s src/app/(mobile-ui)/withdraw/__tests__/withdraw-states.test.tsx › Bank withdrawal keeps the $1 minimum for sub-$1 amounts
0.3s src/hooks/__tests__/useCrispTokenId.test.ts › retries then stays undefined when the endpoint keeps failing (no fallback token)
0.3s src/utils/__tests__/auth-token.test.ts › authReady does not park — hydrates the plain token without an unlock
📍 Inline annotations are in the **Unit test report** check above. Coverage artifact: `coverage-unit`. Generated by `.github/workflows/tests.yml`.

@Hugo0
Hugo0 marked this pull request as ready for review August 18, 2026 16:50
@Hugo0
Hugo0 merged commit 1c6c727 into dev Aug 18, 2026
20 checks passed
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.

1 participant