toga-ai 1.0.368 → 1.0.370
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -8,5 +8,5 @@
|
|
|
8
8
|
| [Rate SAML SSO](features/saml-sso.md) | 2.0 | Rate uses Azure AD as its IdP (`login.rate.com`). | _underscore/Model/Rate/ClientAuthentication.php, saml/Controller/Index.php, toga2-view/src/hooks/useAuthenticationFlow.ts |
|
|
9
9
|
| [Service Card Entitlement Display](features/service-card-entitlements.md) | 2.0 | Rate's home and services pages display one service card per purchased entitlement. | src/components/ServiceCard/ServiceCard.tsx, src/components/ServiceCard/index.ts, src/hooks/useBundleServices.ts, src/pages/Home/api/homeApi.ts, src/pages/Home/view/HomePage.tsx, src/pages/Home/viewModels/useHomePageViewModel.ts, src/pages/Services/view/ServicesPage.tsx, src/pages/Services/viewModels/useServicePageViewModel.ts |
|
|
10
10
|
| [Rate Service-Purchase Confirmation Emails (Tech / Warranty)](features/service-purchase-emails.md) | 2.0 | When a Rate customer purchases a service, a confirmation email is sent. | _underscore/Model/Rate/Entitlement.php, worker2/Worker/Notification/EmailTemplate.php, dbchanges2/Client_Rate/2026-06-30a - Rate purchase email templates.sql |
|
|
11
|
-
| [Rate Whole Home Warranty Per-Address Purchase Guard](features/whole-home-warranty-purchase-guard.md) | 2.0 |
|
|
11
|
+
| [Rate Whole Home Warranty Per-Address Purchase Guard](features/whole-home-warranty-purchase-guard.md) | 2.0 | > **⚠ BETA-VERIFIED, NOT IN PRODUCTION (as of 2026-07-17).** TRUE-79533 is now merged to > `_beta` (both `_underscore` and `dbchanges2`), applied to the beta `C | _underscore/Model/Rate/Entitlement.php, _underscore/Model/Client/Address.php, dbchanges2/Client_Rate/2026-07-07a - WholeHomeWarrantyPerAddressGuard.sql, test/@Mark/Rate/verify_wholehome_per_address_guard.php |
|
|
12
12
|
| [Rate](profile.md) | 2.0 | Rate is a mortgage/lending client. | |
|
|
@@ -6,7 +6,7 @@ project: _Underscore
|
|
|
6
6
|
client: rate
|
|
7
7
|
type: client-feature
|
|
8
8
|
status: active
|
|
9
|
-
updated: 2026-
|
|
9
|
+
updated: 2026-07-17
|
|
10
10
|
owners: [mhammontree]
|
|
11
11
|
files:
|
|
12
12
|
- _underscore/Model/Rate/Entitlement.php
|
|
@@ -118,6 +118,15 @@ Email web-font reality: Gmail/Outlook strip web fonts and fall back; Apple Mail/
|
|
|
118
118
|
|
|
119
119
|
## Gotchas / known issues
|
|
120
120
|
|
|
121
|
+
- **Shared interceptor with TRUE-79533 (WH per-address guard) — same `prePost`/`postPost`.** This
|
|
122
|
+
workflow's `postPost` trigger + helpers live in the **same** `_Model_Rate_Entitlement`
|
|
123
|
+
interceptors that the [Whole Home Warranty per-address guard](whole-home-warranty-purchase-guard.md)
|
|
124
|
+
edits, and TRUE-79251 also adds the passThrough `const PASSTHROUGH_KEY_FULFILLMENT_PREFERENCE` +
|
|
125
|
+
the contractFulfillmentPreference (EV-8) fix inside `prePost`. A bad `_production`→`_beta` merge
|
|
126
|
+
already mis-resolved this once and fatally broke every Rate purchase save. When merging either
|
|
127
|
+
ticket across branches, hand-merge into ONE `prePost()` keeping both features' logic — see the
|
|
128
|
+
**shared-interceptor merge hazard** gotcha on that doc for the correct resolution and why `php -l`
|
|
129
|
+
is not a sufficient gate.
|
|
121
130
|
- **`border-radius` on a `<td>` renders SQUARE in many clients (Outlook).** Use an `<img>` for
|
|
122
131
|
circular badges/icons (e.g. the green circle-check) instead of a CSS-rounded table cell.
|
|
123
132
|
- **ASCII-only subjects (mojibake workaround).** `_Email::send()` does not set PHPMailer
|
|
@@ -150,6 +159,9 @@ Remaining items are **optional / separate, not go-live blockers**:
|
|
|
150
159
|
|
|
151
160
|
## Change history
|
|
152
161
|
|
|
162
|
+
- 2026-07-17 — Added a cross-reference to the [WH per-address guard](whole-home-warranty-purchase-guard.md):
|
|
163
|
+
both tickets edit the same `_Model_Rate_Entitlement` `prePost`/`postPost` interceptors, a
|
|
164
|
+
shared-interceptor merge hazard that already broke `_beta` once. No behavior change here. (mhammontree)
|
|
153
165
|
- 2026-06-30 — Built the Rate service-purchase confirmation email workflow (TRUE-79251):
|
|
154
166
|
`postPost` trigger + helpers in `_Model_Rate_Entitlement`, two DB-stored `Client_Rate`
|
|
155
167
|
templates (tech / warranty) dispatched off-thread via
|
|
@@ -5,8 +5,8 @@ repo: _underscore
|
|
|
5
5
|
project: _Underscore
|
|
6
6
|
client: rate
|
|
7
7
|
type: client-feature
|
|
8
|
-
status:
|
|
9
|
-
updated: 2026-07-
|
|
8
|
+
status: draft
|
|
9
|
+
updated: 2026-07-17
|
|
10
10
|
owners: [mhammontree]
|
|
11
11
|
files:
|
|
12
12
|
- _underscore/Model/Rate/Entitlement.php
|
|
@@ -19,6 +19,15 @@ related:
|
|
|
19
19
|
- ../../../2.0/apps/_underscore/features/address-validation.md
|
|
20
20
|
---
|
|
21
21
|
|
|
22
|
+
> **⚠ BETA-VERIFIED, NOT IN PRODUCTION (as of 2026-07-17).** TRUE-79533 is now merged to
|
|
23
|
+
> `_beta` (both `_underscore` and `dbchanges2`), applied to the beta `Client_Rate` DB, deployed,
|
|
24
|
+
> and **PM Paulina successfully tested the Whole Home Warranty purchase flow on beta — it works.**
|
|
25
|
+
> It is still **not** merged to `_production`: the `_underscore` + `dbchanges2` `TRUE-79533` PRs to
|
|
26
|
+
> `_production` remain the open path, and the deliberate production promotion is the only remaining
|
|
27
|
+
> step. An earlier belief that it "shipped weeks ago" is incorrect — TRUE-79251 (purchase emails)
|
|
28
|
+
> shipped, this guard did not. See the **shared-interceptor merge hazard** gotcha below and the
|
|
29
|
+
> **beta unblock procedure** note before merging to `_production`.
|
|
30
|
+
|
|
22
31
|
## Summary
|
|
23
32
|
|
|
24
33
|
A customer may hold **one active Whole Home Warranty (WH) per validated address, globally**
|
|
@@ -127,6 +136,47 @@ live carrier waterfall is opt-in via `RUN_LIVE=1` (defaults off). Verified **18/
|
|
|
127
136
|
|
|
128
137
|
## Gotchas / known issues
|
|
129
138
|
|
|
139
|
+
- **Shared-interceptor merge hazard — TRUE-79533 and TRUE-79251 edit the SAME methods.** Both
|
|
140
|
+
this guard and the [purchase-email workflow](service-purchase-emails.md) (TRUE-79251) modify the
|
|
141
|
+
**same** `prePost`/`postPost` interceptors on `_Model_Rate_Entitlement`, and TRUE-79251 also adds
|
|
142
|
+
the passThrough `const PASSTHROUGH_KEY_FULFILLMENT_PREFERENCE` + the contractFulfillmentPreference
|
|
143
|
+
(EV-8) fix inside `prePost`. This makes the file a merge landmine:
|
|
144
|
+
- **What already went wrong (on `_beta`):** a later `Merge branch '_production' into _beta`
|
|
145
|
+
mis-resolved the conflict — it reverted `prePost` to production's version and **deleted** the
|
|
146
|
+
private helpers `isWholeHomeWarranty()`, `normalizedField()`, `hasActiveWarrantyAtAddress()`,
|
|
147
|
+
while leaving the caller `persistWarrantyServiceAddress()` (a separate hunk). Result:
|
|
148
|
+
`postPost` → `persistWarrantyServiceAddress()` → `self::isWholeHomeWarranty()` = fatal
|
|
149
|
+
`Error: Call to undefined method`, thrown **before** the method's own try/catch (so it is NOT
|
|
150
|
+
swallowed). This breaks the entitlement save for **every** Rate purchase (tech + warranty).
|
|
151
|
+
Because the crash happens **after** `sendPurchaseEmail()` was enqueued and the record saved, the
|
|
152
|
+
symptom is: record created + email sent, yet the API returns an error → user retries →
|
|
153
|
+
**duplicate entitlements / emails / AIG contracts**.
|
|
154
|
+
- **Correct conflict resolution is NEITHER side alone, and NOT "accept both".** The conflict is a
|
|
155
|
+
single block where HEAD (TRUE-79533) defines the WH-guard `prePost()` + 3 helpers and
|
|
156
|
+
`_production` defines the passThrough `prePost()` + `PASSTHROUGH_KEY_FULFILLMENT_PREFERENCE`.
|
|
157
|
+
Both sides define `prePost()`. accept-HEAD drops the constant (→ undefined-constant fatal in
|
|
158
|
+
`postPost`, and regresses the EV-8 contractFulfillment fix); accept-theirs reproduces the
|
|
159
|
+
`isWholeHomeWarranty` undefined-method crash; accept-both yields a fatal duplicate `prePost()`
|
|
160
|
+
redeclare. **Hand-merge into ONE `prePost()`** that (1) strips `contractFulfillmentPreference`
|
|
161
|
+
→ `$api->passThrough` for every purchase, then (2) runs the WH guard for warranty purchases —
|
|
162
|
+
keeping the constant AND all three private helpers. The common `postPost` below the conflict
|
|
163
|
+
references **both** symbols (the constant at the AIG-contract build, and `isWholeHomeWarranty()`
|
|
164
|
+
in `persistWarrantyServiceAddress`), so both must survive.
|
|
165
|
+
- **`php -l` is NOT a sufficient gate here.** Lint passes on the broken accept-HEAD state — the
|
|
166
|
+
two failures (undefined class constant, EV-8 regression) are runtime, not syntax. Verify with
|
|
167
|
+
`test/@Mark/Rate/verify_wholehome_per_address_guard.php` (18/18 against `Client_Rate`,
|
|
168
|
+
carrier calls off).
|
|
169
|
+
- **Beta unblock procedure (how the broken `_beta` was fixed — 2026-07-17).** To repair the
|
|
170
|
+
partially-merged/broken `_beta` state (the mis-resolved `_production`→`_beta` merge above): merge
|
|
171
|
+
`TRUE-79533` → `_beta` resolving `Entitlement.php` by taking the TRUE-79533 version wholesale
|
|
172
|
+
(`git checkout TRUE-79533 -- Model/Rate/Entitlement.php`); do the same on `dbchanges2` to bring
|
|
173
|
+
the `2026-07-07a` migration onto `_beta`; apply that migration to the beta `Client_Rate` schema
|
|
174
|
+
(its **step-4 `ApiPayloadInterceptors` PRE/POST row** is the load-bearing part that makes
|
|
175
|
+
`prePost` fire — the `POST/POST → postPost` row already existed on beta); then redeploy the beta
|
|
176
|
+
env (api2 beta pulls `_underscore` at deploy). Note the `git checkout <branch> -- <file>`
|
|
177
|
+
wholesale-take shortcut is only safe here because the *other* interceptor concerns (TRUE-79251
|
|
178
|
+
passThrough / EV-8) already live on `TRUE-79533`; a straight `_production` conflict still needs
|
|
179
|
+
the hand-merge described above.
|
|
130
180
|
- **TOCTOU on the uniqueness check (accepted).** The check-then-persist dedup is **not**
|
|
131
181
|
lock-guarded. Two truly concurrent same-address WH purchases could both pass. Accepted for
|
|
132
182
|
sequential purchases; documented in code.
|
|
@@ -143,6 +193,20 @@ live carrier waterfall is opt-in via `RUN_LIVE=1` (defaults off). Verified **18/
|
|
|
143
193
|
|
|
144
194
|
## Change history
|
|
145
195
|
|
|
196
|
+
- 2026-07-17 — **Beta-verified** (TRUE-79533): corrected code merged to `_beta` (`_underscore` +
|
|
197
|
+
`dbchanges2`), `2026-07-07a` migration applied to the beta `Client_Rate` DB, beta redeployed, and
|
|
198
|
+
**PM Paulina successfully tested the WH purchase flow on beta.** Recorded the **beta unblock
|
|
199
|
+
procedure** (take the TRUE-79533 `Entitlement.php` wholesale via `git checkout`, apply the
|
|
200
|
+
migration whose step-4 PRE/POST interceptor row makes `prePost` fire, redeploy). Status remains
|
|
201
|
+
pre-production — the `_underscore` + `dbchanges2` PRs to `_production` are still the open path.
|
|
202
|
+
(mhammontree)
|
|
203
|
+
- 2026-07-17 — **Status corrected to `draft` / not-in-production** (TRUE-79533): git-verified the
|
|
204
|
+
guard was never merged to `_production` (PRs open / back-end review), contrary to a belief it had
|
|
205
|
+
shipped. Documented the **shared-interceptor merge hazard** with TRUE-79251 and the correct
|
|
206
|
+
hand-merge of the dual `prePost()` — a bad `_production`→`_beta` merge had deleted the WH helpers
|
|
207
|
+
(`isWholeHomeWarranty()` et al.) while keeping the caller, fatally breaking every Rate purchase
|
|
208
|
+
save and causing duplicate entitlements/emails/AIG contracts. Resolved the catch-up merge;
|
|
209
|
+
`php -l` clean and 18/18 verify against `Client_Rate`. (mhammontree)
|
|
146
210
|
- 2026-07-08 — Added a backend verification script
|
|
147
211
|
(`test/@Mark/Rate/verify_wholehome_per_address_guard.php`, 18/18 pass against the migrated
|
|
148
212
|
`Client_Rate` schema) and a Verification pointer. (mhammontree)
|
package/package.json
CHANGED