Public: anyone can read this; the crew can change it.

People's nudge line reads without colour, and the fresh-boot test pins its whole sentence #238

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

Each nudge line on /people now starts with a "Nudge" badge, so it reads without colour. The sentence after the badge and nudgeFor's rule are unchanged. Badge: src/pages/people.ts adds Nudge before the escaped sentence, reusing the soon/amber .badge variant the clock uses.

Notes

shipped production is serving it deploy d2eada7

opened this

Each nudge line on /people now starts with a "Nudge" badge, so it reads without colour. The sentence after the badge and nudgeFor's rule are unchanged.

  • Badge: src/pages/people.ts adds <span class="badge" data-u="soon">Nudge</span> before the escaped sentence, reusing the soon/amber .badge variant the clock uses. No new class and no CSS change; the .person-nudge entry in docs/design/areas/people.md now mentions the badge.
  • Test: the fresh-boot test in src/lastsent.test.ts now also checks that the first .person card is nudged. It checks that the card's line is the badge followed by a sentence matching Owes <label> on <address> (today|tomorrow|in N days) · nothing sent (yet|in N days) in full. It also checks that a card without a nudge has no person-nudge and no "Nudge". The "un-nudged card renders as on main" criterion is only covered by that "no Nudge" check, not a byte-for-byte comparison with main. I did not run the new test against main to confirm it fails there; it should, since the badge doesn't exist on main.
  • Terminal People view: not touched.

bun test src/lastsent.test.ts and the people tests pass (9 tests). I could not run three checks here:

  • bun scripts/design-lint.ts and scripts/fast.ts don't exist in this clone.
  • bun x tsc --noEmit printed only tsc's help text, so it did not type-check.

The forge's check will run the full suite on this push.

Closes #232

3 earlier comments · 1 event
commented

Each nudge line on /people now starts with a "Nudge" badge, so it reads without colour. The sentence after the badge and nudgeFor's rule are unchanged.

  • Badge: src/pages/people.ts adds <span class="badge" data-u="soon">Nudge</span> before the escaped sentence, reusing the soon/amber .badge variant the clock uses. No new class and no CSS change; the .person-nudge entry in docs/design/areas/people.md now mentions the badge.
  • Test: the fresh-boot test in src/lastsent.test.ts now also checks that the first .person card is nudged. It checks that the card's line is the badge followed by a sentence matching Owes <label> on <address> (today|tomorrow|in N days) · nothing sent (yet|in N days) in full. It also checks that a card without a nudge has no person-nudge and no "Nudge". The "un-nudged card renders as on main" criterion is only covered by that "no Nudge" check, not a byte-for-byte comparison with main. I did not run the new test against main to confirm it fails there; it should, since the badge doesn't exist on main.
  • Terminal People view: not touched.

bun test src/lastsent.test.ts and the people tests pass (9 tests). I could not run three checks here:

  • bun scripts/design-lint.ts and scripts/fast.ts don't exist in this clone.
  • bun x tsc --noEmit printed only tsc's help text, so it did not type-check.

The forge's check will run the full suite on this push.

commented

I changed nothing and pushed nothing for this failure. The same seven tests fail on cec063e, the commit before my change, so they aren't caused by the Nudge badge.

I re-ran them here on both commits:

  • Speed tests: on cec063e, six of src/speed.test.ts fail: "answers in under 50 ms with 200 deals" for the reminder review and for people, plus "first time after a deal changes" for the clock, the reminder review, people and the clock with closed deals. On my branch, bun test over src/speed.test.ts and src/terminal.test.ts shows two of the "first time after a deal changes" tests failing.
  • Terminal timeout: "the deal view says which other closing the same day is less than two hours away" in src/terminal.test.ts times out at 5 s on both cec063e and my branch. It also failed in the deploy log.

All seven are timing budgets: the speed tests allow 50 ms for a cold request, and my sandbox takes about 350–1500 ms. My change adds one <span> to the people page and touches no timing or terminal code, so those budgets are most likely being missed by a loaded or slow runner. I didn't confirm that. I didn't loosen the budgets or skip the tests, because that would hide a real regression.

The Nudge test in src/lastsent.test.ts and the people tests pass.

A person should decide whether the runner is the problem or whether main's speed budgets need attention. The branch is otherwise ready as pushed.

commented

I merged main into this branch and pushed it. The full suite passes after the merge (773 tests, 0 failures).

src/pages/people.ts was the only conflict. Both sides edited the person card, so I kept both changes:

  • From main: the reach line, reachLine(p.reach), in a muted paragraph.
  • From this branch: the nudge line opening with the Nudge badge (<span class="badge" data-u="soon">).
  • Order: the reach line comes first, then the nudge line, as on main.

I couldn't run the type check. The repository has no tsconfig.json, so bun x tsc --noEmit only printed tsc's help text. I didn't run scripts/gate.ts or scripts/design-lint.ts.

My first bun scripts/fast.ts call also printed nothing, so the bun test line that followed ran with no file list and covered the whole suite. That's why the number above is the full 773.

Approved

Small, safe change: the badge is a static span, the sentence is still escaped, no new class, no contract cell touched, terminal untouched. The fresh-boot test checks the first card in full. Minor gap: the un-nudged check only asserts there is no Nudge text, not that the card is unchanged.

commented

Left #232 open: 1 unticked item remain (A person with no nudge renders exactly as on main (a test compares one un-nudged card).).

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs