Robin Fernandes
2a94ca80e7
fix(free-tier): review round 2 — route-gate the allowance verdict, keep policy/billing 403s, pool the provision RPC, guard the retry race
...
Should-fix
- _is_genuine_nous_rate_limit: the structured rate_limited verdict counts only
on the welcome host; a paid-host 429 keeps main's exhausted-bucket rule.
- _nous_welcome_tier: the route-keyed dark-tier 403 applies only to a 403 that
matches neither the content-policy nor the billing patterns, so a safety
refusal or billing wall on the welcome host keeps its own recovery.
- free_tier.provision joins _LONG_HANDLERS (a forced mint + lock waits +
re-inventory no longer block the RPC reader).
- retry_bootstrap_mint: under the lock, a build that found no identity never
overwrites a record that has one (the loop racing the user's click).
Simplifications from the review
- _raise_for_anon_status is a (status, error) table; retryable derives from
ANON_TERMINAL_CODES once (a bare 401 on sign-up now rides the ladder
instead of dying for the process).
- classify_mint_exception is public and pure; the hand-built failure dict in
free_tier.provision is gone (the memo is the one source).
- SetupRecord carries the memo payload as one `failure` dict instead of three
unpacked fields.
- _welcome_surface_kind is a closed table with a "refused" default;
_welcome_outage_copy excludes the classifier's `unknown` catch-all.
- FREE_TIER_RATE_LIMIT_CHAT is CARD + the sign-in tail, not a slice.
- Copy tests assert the contract (model named, tail present/absent) instead
of freezing whole sentences.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com >
2026-09-15 20:44:42 +05:30
..
2026-09-12 05:09:11 -07:00
2026-09-13 05:07:50 -07:00
2026-09-03 17:13:22 -07:00
2026-09-13 05:07:11 -07:00
2026-09-13 05:07:11 -07:00
2026-09-15 05:42:35 -07:00
2026-09-15 04:56:01 -07:00
2026-09-06 20:50:02 +05:30
2026-09-02 13:29:48 -07:00
2026-09-15 04:53:38 -07:00
2026-09-02 18:56:06 -07:00
2026-09-13 09:18:02 -07:00
2026-09-15 03:34:20 -07:00
2026-09-15 04:51:15 -07:00
2026-09-13 05:20:26 -07:00
2026-09-14 20:01:19 +05:30
2026-09-13 05:07:11 -07:00
2026-09-06 05:37:03 -07:00
2026-09-06 05:37:03 -07:00
2026-09-14 20:01:19 +05:30
2026-09-02 20:10:26 -07:00
2026-09-02 21:38:20 -07:00
2026-09-03 17:13:22 -07:00
2026-09-15 04:52:47 -07:00
2026-09-11 19:39:12 -07:00
2026-09-07 06:02:22 -07:00
2026-09-13 05:19:48 -07:00
2026-09-07 07:06:58 -07:00
2026-09-14 06:55:54 -07:00
2026-09-02 18:18:18 -07:00
2026-09-15 04:45:33 -07:00
2026-09-02 18:49:57 -07:00
2026-09-02 18:49:57 -07:00
2026-09-02 18:49:57 -07:00
2026-09-03 17:13:22 -07:00
2026-09-03 17:13:22 -07:00
2026-09-04 00:15:16 -07:00
2026-09-15 03:39:07 -07:00
2026-09-15 04:12:13 -07:00
2026-09-07 05:24:15 -07:00
2026-09-07 05:24:15 -07:00
2026-09-15 20:44:42 +05:30
2026-09-02 18:47:54 -07:00
2026-09-15 04:49:47 -07:00
2026-09-15 03:39:07 -07:00
2026-09-06 22:45:31 +05:30
2026-09-15 03:47:15 -07:00
2026-09-03 09:44:26 -07:00
2026-09-03 09:44:26 -07:00
2026-09-13 05:09:43 -07:00
2026-09-07 05:59:08 -07:00
2026-09-13 05:09:43 -07:00
2026-09-11 02:07:48 -07:00
2026-09-15 03:37:49 -07:00
2026-09-15 04:17:31 -07:00
2026-09-13 05:20:26 -07:00
2026-09-15 05:19:57 -07:00
2026-09-15 04:12:13 -07:00
2026-09-15 04:17:31 -07:00
2026-09-02 18:57:14 -07:00
2026-09-07 08:06:48 -07:00
2026-09-13 05:09:43 -07:00
2026-09-03 22:00:01 -07:00
2026-09-11 03:45:33 +05:30
2026-09-03 09:44:26 -07:00
2026-09-12 05:56:15 -07:00
2026-09-07 08:19:32 -07:00
2026-09-15 06:08:20 -07:00
2026-09-15 04:12:13 -07:00
2026-09-03 04:31:46 -07:00
2026-09-15 20:44:42 +05:30
2026-09-15 20:44:42 +05:30
2026-09-02 13:29:48 -07:00
2026-09-03 17:13:22 -07:00
2026-09-09 11:29:56 -07:00
2026-09-02 18:22:13 -07:00
2026-09-15 06:20:15 -07:00
2026-09-15 03:54:01 -07:00
2026-09-14 06:44:54 -07:00
2026-09-11 15:26:46 -07:00
2026-09-03 17:13:22 -07:00
2026-09-04 00:15:16 -07:00
2026-09-07 08:08:04 -07:00
2026-09-12 01:35:05 -07:00
2026-09-15 03:58:05 -07:00
2026-09-12 08:23:13 -07:00
2026-09-02 18:53:53 -07:00
2026-09-09 13:08:25 +05:30
2026-09-09 10:58:16 -07:00
2026-09-07 08:28:43 -07:00
2026-09-02 18:22:13 -07:00
2026-09-02 18:58:42 -07:00
2026-09-02 18:22:13 -07:00
2026-09-11 11:54:49 -07:00
2026-09-03 22:00:01 -07:00
2026-09-15 05:38:31 -07:00
2026-09-03 09:44:26 -07:00
2026-09-02 18:22:13 -07:00
2026-09-02 18:29:05 -07:00
2026-09-02 22:21:06 -07:00
2026-09-13 05:19:48 -07:00
2026-09-15 03:47:15 -07:00
2026-09-02 18:28:38 -07:00
2026-09-02 18:28:38 -07:00
2026-09-14 20:35:28 +05:30
2026-09-03 09:44:26 -07:00
2026-09-15 06:29:50 -07:00
2026-09-02 19:10:21 -07:00
2026-09-15 03:54:58 -07:00
2026-09-11 16:50:20 -07:00
2026-09-02 18:33:06 -07:00
2026-09-13 05:09:43 -07:00
2026-09-15 20:44:42 +05:30
2026-09-06 09:11:04 -07:00
2026-09-13 05:09:06 -07:00
2026-09-02 19:05:15 -07:00
2026-09-03 09:44:26 -07:00
2026-09-11 15:26:46 -07:00
2026-09-09 12:17:57 +05:30
2026-09-03 09:44:26 -07:00
2026-09-03 15:07:39 -07:00
2026-09-02 19:10:21 -07:00
2026-09-02 18:22:01 -07:00
2026-09-13 05:09:43 -07:00
2026-09-15 06:29:50 -07:00
2026-09-03 17:13:22 -07:00
2026-09-14 06:55:54 -07:00
2026-09-03 09:44:26 -07:00
2026-09-02 18:33:06 -07:00
2026-09-12 13:44:52 -07:00
2026-09-02 18:44:36 -07:00
2026-09-02 19:10:21 -07:00
2026-09-15 06:16:38 -07:00
2026-09-11 03:45:33 +05:30
2026-09-02 19:18:18 -07:00
2026-09-02 18:51:24 -07:00
2026-09-13 05:19:48 -07:00
2026-09-14 20:35:28 +05:30
2026-09-13 21:27:35 -07:00
2026-09-10 09:22:31 -07:00
2026-09-15 06:26:29 -07:00
2026-09-03 17:13:22 -07:00
2026-09-15 03:44:36 -07:00
2026-09-03 17:13:22 -07:00
2026-09-03 09:44:26 -07:00
2026-09-13 19:23:09 +05:30
2026-09-13 05:09:43 -07:00
2026-09-08 04:38:47 -07:00
2026-09-03 17:13:22 -07:00
2026-09-02 19:18:18 -07:00
2026-09-03 04:56:59 +05:30
2026-09-15 04:56:40 -07:00
2026-09-06 05:35:12 -07:00
2026-09-15 04:18:34 -07:00
2026-09-13 05:07:11 -07:00
2026-09-02 19:19:44 -07:00
2026-09-03 17:13:22 -07:00
2026-09-15 03:34:20 -07:00
2026-09-07 07:10:28 -07:00
2026-09-15 06:29:50 -07:00
2026-09-03 17:13:22 -07:00
2026-09-03 03:31:03 -07:00
2026-09-03 10:40:25 -07:00
2026-09-03 12:29:52 -07:00
2026-09-03 13:29:35 -07:00
2026-09-02 19:42:28 -07:00
2026-09-03 03:31:03 -07:00
2026-09-12 08:34:07 -07:00
2026-09-02 19:36:47 -07:00
2026-09-09 10:31:26 +05:30
2026-09-15 04:13:13 -07:00
2026-09-03 13:24:04 -07:00
2026-09-04 00:15:16 -07:00
2026-09-13 05:20:26 -07:00
2026-09-15 04:12:13 -07:00
2026-09-02 19:42:28 -07:00
2026-09-15 06:08:20 -07:00
2026-09-10 02:21:16 +05:30
2026-09-15 04:17:31 -07:00
2026-09-12 21:07:46 -07:00
2026-09-06 22:56:51 +05:30
2026-09-12 08:25:14 -07:00
2026-09-03 17:13:22 -07:00
2026-09-04 00:15:16 -07:00
2026-09-04 00:15:16 -07:00
2026-09-03 09:44:26 -07:00
2026-09-04 00:15:16 -07:00
2026-09-15 20:44:42 +05:30
2026-09-15 20:44:42 +05:30
2026-09-14 20:35:28 +05:30
2026-09-10 10:45:57 -07:00
2026-09-06 13:21:17 -07:00
2026-09-15 04:18:34 -07:00
2026-09-15 04:12:13 -07:00
2026-09-15 04:12:13 -07:00
2026-09-15 04:18:34 -07:00
2026-09-15 04:18:34 -07:00
2026-09-15 04:12:13 -07:00
2026-09-13 14:46:42 -07:00
2026-09-15 04:12:13 -07:00
2026-09-15 04:12:13 -07:00
2026-09-09 12:17:57 +05:30
2026-09-15 04:12:13 -07:00
2026-09-15 04:12:13 -07:00
2026-09-06 13:21:17 -07:00
2026-09-06 13:21:17 -07:00
2026-09-15 20:44:42 +05:30
2026-09-07 06:15:43 -07:00
2026-09-15 04:12:13 -07:00
2026-09-02 18:40:01 -07:00
2026-09-15 20:44:42 +05:30
2026-09-02 19:30:27 -07:00
2026-09-02 19:26:50 -07:00
2026-09-03 09:44:26 -07:00
2026-09-15 04:12:13 -07:00
2026-09-15 04:12:13 -07:00
2026-09-06 14:19:42 -07:00
2026-09-06 13:21:17 -07:00
2026-09-10 02:44:26 -07:00
2026-09-10 11:48:01 -07:00
2026-09-15 04:56:01 -07:00
2026-09-13 05:08:29 -07:00
2026-09-02 19:19:54 -07:00
2026-09-02 18:29:10 -07:00
2026-09-02 19:07:07 -07:00
2026-09-12 13:44:52 -07:00
2026-09-04 00:15:16 -07:00
2026-09-15 04:48:20 -07:00
2026-09-03 17:13:22 -07:00
2026-09-04 07:17:00 -07:00