toga-ai 1.0.439 → 1.0.441

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.
@@ -14,60 +14,60 @@ updated: 2026-07-27
14
14
  # Session: true-79533-pin-depth
15
15
  **Date:** 2026-07-27
16
16
  **Project/Repo:** _underscore / dbchanges2 / toga2-view (2.0, client Rate)
17
- **Task:** Get the validated Whole Home Warranty service address to pin (`Entitlements.serviceAddressId`) and render on beta. Backend is done and correct; the live blocker is that the beta purchase POST sends `depth=-1`, which starves the `postPost` interceptor of the just-created address id.
17
+ **Task:** Get the validated Whole Home Warranty service address to pin (`Entitlements.serviceAddressId`) and render on beta. Backend is done and correct; the blocker was the beta purchase POST sending `depth=-1`, which starved the `postPost` interceptor of the just-created address id. **FIX CHOSEN: front-end drops `depth`; deploying to beta now — awaiting verification.**
18
18
 
19
19
  ---
20
20
 
21
21
  ## What WORKED
22
22
  <!-- Include specific file paths and evidence -->
23
- - **Backend pin implemented** in `_underscore/Model/Rate/Entitlement.php` `postPost` → `persistWarrantyServiceAddress`: reads the created address id from the in-memory hydrated payload (`$payload->contact->primaryContactAddress->address->id`), then `UPDATE Addresses SET isValidated=1` + `UPDATE Entitlements SET serviceAddressId=… WHERE uuid=…`. Committed `dff1fb5e`. **Proven working**: a no-`depth` (deep-payload) purchase ET100057, made from the local FE against the beta backend — pinned `serviceAddressId=56` with `Addresses.id 56` (STE 400) `isValidated=1`.
24
- - **`serviceAddressId` is a STANDARD field** on base `_underscore/Model/Client/Entitlement.php:20` (`FIELD_FOREIGNKEY` → `_Model_Client_Address`), inherited by the Rate model. Verified in the model file. So V2 persists/reads it; the postPost UPDATE and the FE read both rely on this.
25
- - **Display EZ-2 fixed**: `dbchanges2/Client_Rate/2026-07-24a - AddressIdFieldPermission.sql` grants READ on `Addresses.id` for roles 1/2/3 (isWritable 0). Committed `ea1e0fb`. Applied on beta manually and verified (`AclFieldPermissions` field 41 → roles 1,2,3). This fixes the FE `GET /v2/addresses?fields=id,…` 403.
26
- - **Hard-blocks now return HTTP 400** via `_Exception_Validation` (the 3 prePost throws: missing address, unverifiable address, duplicate WH). Committed `41a5dc1a`. Verified against `api2/Controller/Index.php:204-222` — it catches `_Exception_Validation` → `DEFINED_MESSAGE_ERROR_BAD_REQUEST` (400 + clean message); all other exceptions → 500 + stack trace. This is what makes the FE blocked-purchase toaster work.
27
- - **Dedup** `hasActiveWarrantyAtAddress` forces the WRITE host + disables the query cache for a fresh read (committed). `COALESCE(serviceAddressId, ContactAddresses.addressId)` fallback so unpinned WHs are still deduped.
28
- - **Root cause proven via `Logs_Rate.Api`** (beta, MCP env `dev-sandbox`): the local-FE and beta-FE purchases hit the SAME beta backend instance (`i-0ce5624547cfecc93`, `api.beta.togahub.com`). The ONLY difference is the request query string — local: `transactionId=…` (no depth) → 64,650-byte deep response → **pinned**; beta: `depth=-1&transactionId=…` → 644-byte shallow response **starved** (no address node in the payload postPost receives).
29
- - **`-1` source confirmed = front-end**: `toga2-view/src/pages/CheckOut/api/checkoutApi.ts:21` (`createService` passes `{ 'depth': -1 }`), serialized to `?depth=-1`. Confirmed in the logged query string.
30
- - **Beta interceptor config read** (`ApiPayloadInterceptors` join `Core.Records`): entitlements `postPost` = id **2**, active, **minDepth 5**; entitlements `prePost` = id 4, active, minDepth **null default 3**; sales-orders `postPost` = id 3, null→3.
23
+ - **Backend pin implemented** in `_underscore/Model/Rate/Entitlement.php` `postPost` → `persistWarrantyServiceAddress`: reads the created address id from the in-memory hydrated payload (`$payload->contact->primaryContactAddress->address->id`), then `UPDATE Addresses SET isValidated=1` + `UPDATE Entitlements SET serviceAddressId=… WHERE uuid=…`. Committed `dff1fb5e`. **Proven working AND already on the beta backend**: ET100057 a purchase whose request had **no `depth` param** (query string `transactionId=…`, 64,650-byte deep response) — pinned `serviceAddressId=56`, address 56 (STE 400) `isValidated=1`, on the same beta instance that fails for `depth=-1` calls. This is the exact config the FE fix reproduces.
24
+ - **`serviceAddressId` is a STANDARD field** on base `_underscore/Model/Client/Entitlement.php:20` (`FIELD_FOREIGNKEY` → `_Model_Client_Address`), inherited by the Rate model.
25
+ - **Display EZ-2 fixed**: `dbchanges2/Client_Rate/2026-07-24a - AddressIdFieldPermission.sql` grants READ on `Addresses.id` for roles 1/2/3. Committed `ea1e0fb`. Applied on beta manually and verified.
26
+ - **Hard-blocks return HTTP 400** via `_Exception_Validation` (committed `41a5dc1a`) mapped by `api2/Controller/Index.php:204-222`. (NOT yet on beta see blockers.)
27
+ - **Dedup** `hasActiveWarrantyAtAddress` forces WRITE host + disables query cache; `COALESCE(serviceAddressId, ContactAddresses.addressId)` fallback.
28
+ - **Root cause proven via `Logs_Rate.Api`** (MCP env `dev-sandbox`): local-FE and beta-FE purchases hit the SAME beta instance (`i-0ce5624547cfecc93`). Only difference = request query string depth: no-depth → 64 KB deep → **pins**; `depth=-1` → 644 B shallow (`meta.calcDepth: 1`, no `address` node) **starved**.
29
+ - **`-1` source = front-end**: `toga2-view/src/pages/CheckOut/api/checkoutApi.ts:21` (`createService` passed `{ 'depth': -1 }`). Confirmed in the logged query string.
30
+ - **Interceptor config (Rohan-confirmed):** `ApiPayloadInterceptors` `minDepth` defaults to **3** when null; entitlements `postPost` (id 2) is explicitly **5**; `prePost` (id 4) & sales-orders (id 3) are null→3. Omitting the request `depth` yields a full/deep build that clears the 5 floor and includes the `address` node.
31
31
 
32
32
  ## What did NOT work — DO NOT RETRY THESE
33
33
  <!-- Exact failure reasons — do not vague-ify -->
34
- - **Forcing the write host inside `persistWarrantyServiceAddress`** (commit `7b63955d`, later removed in `dff1fb5e`): NO EFFECT. V2 already globally disables the read host for the entire create block (`api2/.../V2.php:5024`), so the lookup was ALREADY on the write connection — forcing it again was a no-op. Confirmed by a genuinely post-deploy purchase (ET100051/52/53) still returning null.
35
- - **The original 3-table JOIN lookup** in postPost (`Entitlement → Contacts.primaryContactAddressId → ContactAddresses → addressId`): returned 0 rows *in-request* on beta even on the write connection. The identical query resolves correctly *post-commit*. Superseded by the payload approach.
36
- - **The payload-based pin (`$address->id`) still returned null on beta** — NOT because the code is wrong, but because with `depth=-1` the payload built for `postPost` is shallow (`meta.calcDepth: 1`) and does **not contain the `contact.primaryContactAddress.address` node at all**, so `$address->id` (and the `uuid` fallback) find nothing. Root cause is the depth, not the pin code.
37
- - **Merging `_underscore` to `_beta` did NOT deploy to beta.** The beta EB env **API-Sandbox-Dev** pulls `_underscore` from branch **`_sandbox-dev`** via `api2/.platform/hooks/prebuild/git.sh` + `api2/.ebextensions/git.sandbox-dev.json` (the prebuild hook `rm -Rf`s and re-clones that branch, overwriting the pipeline copy). Deploying anything not on `_sandbox-dev` runs old code.
38
- - **"Removing `depth=-1` from the beta curl" (Fri/earlier)**: the edited curl STILL had `depth=-1` in the query string (it wasn't actually removed) — confirmed via the logged `queryString`. So that test never proved anything.
39
- - **The single-host-vs-multi-host connection theory** (an earlier hypothesis): DISPROVEN. Both local-FE and beta-FE requests run on the SAME beta backend instance. The difference is purely the request's `depth` param, not connection topology.
34
+ - **Forcing the write host inside `persistWarrantyServiceAddress`** (commit `7b63955d`, removed in `dff1fb5e`): NO EFFECT. V2 already disables the read host for the whole create block (`V2.php:5024`) the lookup was already on the writer.
35
+ - **The 3-table JOIN lookup** (`Entitlement → Contacts.primaryContactAddressId → ContactAddresses → addressId`) in postPost: returns 0 rows *in-request* even on the writer; resolves only *post-commit*. Superseded by the payload approach.
36
+ - **Payload-based `$address->id` on beta with `depth=-1`**: null the shallow payload (`calcDepth 1`) has NO `contact.primaryContactAddress.address` node at all, so there's nothing to read. Code is correct; depth is the cause.
37
+ - **Merging `_underscore` to `_beta` did NOT deploy to beta.** API-Sandbox-Dev EB pulls `_underscore` from **`_sandbox-dev`** via `api2/.platform/hooks/prebuild/git.sh` + `.ebextensions/git.sandbox-dev.json`.
38
+ - **"Removed depth" curl test (earlier)**: the edited curl STILL had `depth=-1` (per logged `queryString`) proved nothing.
39
+ - **Single-host vs multi-host connection theory**: DISPROVEN same beta instance both ways; the variable is the request `depth`, not topology.
40
40
 
41
41
  ## Not tried yet (candidates for next session)
42
- - **THE decisive test (do this first):** on beta `Client_Rate`, `UPDATE ApiPayloadInterceptors SET minDepth = 10 WHERE id = 2;` then fire one fresh WH purchase (FE still sends `depth=-1`) and check `meta.calcDepth` + whether the new entitlement pins (`serviceAddressId` set, its address `isValidated=1`). Open question for Rohan: does the `minDepth` clamp engage for the `-1` sentinel at all? It's already 5 yet the build came through at `calcDepth 1` — so either it needs > 5 or `-1` bypasses the clamp.
43
- - **FE fix (alternative/parallel):** drop `{ 'depth': -1 }` at `toga2-view/src/pages/CheckOut/api/checkoutApi.ts:21` (or set minDepth), deploy `toga2-view`. This is the FE-side lever; it's owned by Tanner/Alex and the repo is currently on `_beta`.
44
- - Merge `_underscore` `TRUE-79533` → `_sandbox-dev` + deploy (ships the pin + 400 fix; backend is NOT yet on beta).
45
- - Merge `dbchanges2` `TRUE-79533` to its deploy branch for prod parity (beta already has the migrations, applied manually).
42
+ - **PRIMARY (in flight):** Tanner removed `depth` from `checkoutApi.ts:21` on the front-end; the `toga2-view` change is **deploying to beta now**. Verify a fresh beta purchase pins (see Exact next step). This reproduces the proven-good ET100057 config.
43
+ - **FALLBACK if the FE fix somehow doesn't take:** on beta `Client_Rate`, `UPDATE ApiPayloadInterceptors SET minDepth = 10 WHERE id = 2;`, fire a purchase, check whether `calcDepth` rises and it pins. (Open Q: does the `minDepth` clamp engage for the `-1` sentinel? It's 5 yet built at `calcDepth 1`.)
44
+ - Merge `_underscore` `TRUE-79533` → `_sandbox-dev` + deploy (ships the `_Exception_Validation` 400 fix + full backend; pin itself is already on beta).
45
+ - Merge `dbchanges2` `TRUE-79533` for prod parity (beta already has the migrations).
46
46
  - Run `/capture`.
47
- - File side tickets: (1) framework `minDepth`-clamp appears to be a no-op for `depth=-1` (starves ALL payload interceptors); (2) AIG contract block (`postPost`) has the SAME `depth` starvation — silently skipped for beta-FE purchases; (3) SECURITY: plaintext GitHub PAT committed in `api2/.ebextensions/git.*.json` — rotate + move to env config.
47
+ - File side tickets: (1) framework `minDepth`-clamp no-op for low/`-1` depth (starves ALL payload interceptors); (2) AIG contract block has the SAME `depth` starvation — silently skipped for beta-FE purchases; (3) SECURITY: plaintext GitHub PAT committed in `api2/.ebextensions/git.*.json` — rotate + move to env config.
48
48
 
49
49
  ## Current file state
50
50
  | File | Status | Notes |
51
51
  |------|--------|-------|
52
- | `_underscore/Model/Rate/Entitlement.php` | Committed on `TRUE-79533` (HEAD `41a5dc1a`) | payload-based pin (`dff1fb5e`), dedup write-host, `_Exception_Validation` hard-blocks (`41a5dc1a`). NOT merged to `_sandbox-dev`. |
53
- | `_underscore/Model/Client/Entitlement.php` | Committed | `serviceAddressId` standard FK field (line 20). |
54
- | `dbchanges2/Client_Rate/2026-07-24a - AddressIdFieldPermission.sql` | Committed (`ea1e0fb`) | `Addresses.id` read ACL. Applied on beta manually. |
52
+ | `_underscore/Model/Rate/Entitlement.php` | Committed on `TRUE-79533` (HEAD `41a5dc1a`) | payload pin (`dff1fb5e`) + dedup write-host + `_Exception_Validation` (`41a5dc1a`). Pin already on beta; the 400-fix is NOT (needs `_sandbox-dev` merge). |
53
+ | `_underscore/Model/Client/Entitlement.php` | Committed | `serviceAddressId` standard FK (line 20). |
54
+ | `dbchanges2/Client_Rate/2026-07-24a - AddressIdFieldPermission.sql` | Committed (`ea1e0fb`) | `Addresses.id` read ACL. Applied on beta. |
55
55
  | `dbchanges2` serviceAddressId col + `Core` field + ACL migrations | Committed on `TRUE-79533` | Applied on beta manually; branch needs merge for prod. |
56
- | `toga2-view/src/pages/CheckOut/api/checkoutApi.ts` | UNCHANGED (on `_beta`) | Line 21 still `'depth': -1` the FE fix is pending. |
57
- | `test/@Mark/Rate/verify_wholehome_per_address_guard.php` | Updated (personal, not in a repo) | `c_serviceAddressId` → `serviceAddressId`; documents the multi-host/depth caveat. |
56
+ | `toga2-view/src/pages/CheckOut/api/checkoutApi.ts` | **Tanner removed `depth` — DEPLOYING to beta now** | Line 21 `{ 'depth': -1 }` dropped so `postPost` gets a deep payload. THE unblocker. |
57
+ | `test/@Mark/Rate/verify_wholehome_per_address_guard.php` | Updated (personal, not in a repo) | `c_serviceAddressId` → `serviceAddressId`; documents the depth caveat. |
58
58
 
59
59
  ## Decisions made
60
- - **Pin from the in-memory hydrated payload, not a DB read-back.** Rationale: in-request DB SELECTs can't reliably see the transaction's own uncommitted nested writes; V2's `getFullModelData` hydrates the payload before `postPost`. Rejected: the JOIN lookup (0 rows in-request) and an async post-commit worker (more surface; unnecessary once depth is fixed).
61
- - **`serviceAddressId` = STANDARD field** (per Jeff), not the old Rate-custom `c_serviceAddressId`.
62
- - **Hard-blocks throw `_Exception_Validation`** so they map to HTTP 400 with the message surfaced (the FE checkout expects 400). Rejected: plain `_Exception` → 500 + stack trace.
63
- - **Preferred depth fix = raise the `postPost` interceptor `minDepth`** (Rohan's lever) over the FE change: config-only, FE-independent, and also un-breaks the AIG block. Pending the beta test to confirm the clamp actually deepens the build for a `depth=-1` request.
60
+ - **Fix depth on the FRONT-END (drop the `depth` param)** rather than bumping the interceptor `minDepth`. Rationale: it reproduces the already-proven ET100057 (no-depth) config that pinned on beta, needs no DB config change, and un-starves the AIG block for free. The `minDepth` bump remains the fallback / the proper systemic guardrail. (Rohan confirmed minDepth 3-default / 5 on postPost.)
61
+ - **Pin from the in-memory hydrated payload, not a DB read-back** (in-request reads can't see uncommitted nested writes; `getFullModelData` hydrates the payload before `postPost`).
62
+ - **`serviceAddressId` = STANDARD field** (per Jeff), not `c_serviceAddressId`.
63
+ - **Hard-blocks throw `_Exception_Validation`** HTTP 400 + surfaced message (FE checkout expects 400).
64
64
 
65
65
  ## Blockers
66
- - Pin cannot fire on beta until the `depth` collision is resolved: FE sends `depth=-1`, and the `postPost` interceptor `minDepth 5` floor is NOT producing a deep-enough payload (`calcDepth 1`). Open question to Rohan: does the `minDepth` clamp engage for `depth=-1`, and what target value? Needs the beta `UPDATE` test to settle.
67
- - Backend (`TRUE-79533`) is not yet on beta it lives on `TRUE-79533`, but beta deploys `_underscore` from `_sandbox-dev`.
66
+ - **Verification pending** the front-end `depth` removal is mid-deploy to beta; can't confirm the pin until it lands and a fresh purchase is made.
67
+ - The `_Exception_Validation` 400-fix (`41a5dc1a`) and the rest of `TRUE-79533` are on `TRUE-79533` but NOT yet on beta (beta deploys `_underscore` from `_sandbox-dev`). Does NOT block the pin test (the pin code is already on beta), but needs merging for the 400/toaster behavior + prod.
68
68
 
69
69
  ## Exact next step
70
- > On beta (`dev-sandbox`, `Client_Rate`) run `UPDATE ApiPayloadInterceptors SET minDepth = 10 WHERE id = 2;`, then make one fresh WH purchase (FE unchanged, still sends `depth=-1`) and check the create response `meta.calcDepth` plus the new entitlement's `serviceAddressId` and its `Addresses.isValidated`. If it pins → the clamp works and 5 was too low; dial in the minimal value and ship it as a `dbchanges2 Client_Rate` migration (no FE change). If still null / `calcDepth` stays 1 the clamp doesn't engage for `-1`; fix the FE (`checkoutApi.ts:21` drop `depth:-1`) instead. Confirm the intended target value with Rohan first.
70
+ > As soon as Tanner's `toga2-view` deploy lands, make ONE fresh WH purchase on beta and verify in the DB (MCP `dev-sandbox`, `Client_Rate`): the newest WH entitlement has `serviceAddressId` populated AND its `Addresses.isValidated = 1`, with NO manual backfill. Also confirm the create response no longer shows the `WO-1` depth warning (and `meta.calcDepth` is higher), and that AIG outbound calls resume in `Logs_Rate.Api`. If it pins → success; then merge `_underscore TRUE-79533` `_sandbox-dev` (for the 400 fix), merge `dbchanges2`, and run `/capture`. If it still returns null → apply the FALLBACK (`UPDATE ApiPayloadInterceptors SET minDepth=10 WHERE id=2` on beta) and re-test.
71
71
 
72
72
  ---
73
73
  _Saved by /session-save on 2026-07-27_
@@ -0,0 +1,66 @@
1
+ ---
2
+ type: session
3
+ slug: true-79533-pin-depth
4
+ title: TRUE-79533 depth=-1 root-caused to beta-only FE commit — removed, pushed to _beta
5
+ author: tcox
6
+ repos: [toga2-view]
7
+ framework: "2.0"
8
+ client: rate
9
+ status: active
10
+ created: 2026-07-27
11
+ updated: 2026-07-27
12
+ ---
13
+
14
+ # Session: true-79533-pin-depth
15
+ **Date:** 2026-07-27
16
+ **Project/Repo:** toga2-view (2.0, client Rate) — continues mhammontree's 2026-07-27 session of the same slug
17
+ **Task:** Resolve the beta `depth=-1` starvation blocking the WH service-address pin (TRUE-79533): root-caused it to a beta-only FE commit and removed it — committed `e4c0ead` and pushed to `toga2-view` `origin/_beta`. Backend merge + deploys deliberately deferred.
18
+
19
+ ---
20
+
21
+ ## What WORKED
22
+ <!-- Include specific file paths and evidence -->
23
+ - **Root cause of the depth param found**: `depth=-1` in `createService` was added by a SINGLE commit `0b1ed0f` (rgirish97, 2026-02-24, "Send depth:-1 option when creating service") made **directly and only on `_beta`**. Verified three ways: `git log -S "depth" --all -- src/pages/CheckOut/api/checkoutApi.ts` (only that commit), `git branch -r --contains 0b1ed0f` (only `origin/_beta`), and `git show origin/_production:src/pages/CheckOut/api/checkoutApi.ts` (production sends NO depth).
24
+ - **Therefore the starvation is beta-only.** Production FE is already clean — once the backend guard reaches production, production pins as-is with no FE change. Also explains the prior session's evidence: local-FE purchases (built from `rate-active-development`, which never had the commit) always pinned (ET100057), beta-FE purchases starved.
25
+ - **Merge-topology insight**: merges from `rate-active-development` / `_production` into `_beta` can NEVER remove the param (neither source contains a removal change) — it survived merges `ee2f6ab` and `fcb1996`. Only an explicit change on `_beta` kills it.
26
+ - **Fix applied and shipped to git**: removed the third options arg `{ 'depth': -1 }` from `createService` in `toga2-view/src/pages/CheckOut/api/checkoutApi.ts` on `_beta` (fast-forwarded to `fcb1996` first). Commit `e4c0ead` "fix: remove depth=-1 from entitlement create request", pushed `fcb1996..e4c0ead` to `origin/_beta`. Diff: 1 insertion, 3 deletions.
27
+ - **Confirmed the mechanism before editing**: `apiPost`'s third arg is serialized into the query string via `assembleOptions` (`toga2-view/src/api/apiFunctions.ts:21-35`) — removing the arg removes `?depth=-1` entirely, which is exactly the request shape that pinned ET100057. Checkout viewmodel reads only top-level `isSuccess`/`status`/`error` from the create response (`useCheckoutPageViewModel.ts:471-474`), so the deeper ~64KB response is safe for the FE.
28
+ - Session was resumed from mhammontree's same-day save via `/session-resume true-79533-pin-depth` — the handoff worked; all their DO-NOT-RETRY items were honored.
29
+
30
+ ## What did NOT work — DO NOT RETRY THESE
31
+ <!-- Exact failure reasons — do not vague-ify -->
32
+ - **First commit attempt returned "nothing to commit, working tree clean"** — the working-tree edit had been silently reverted back to HEAD (depth restored), almost certainly an IDE source-control discard / editor-buffer overwrite while the developer had `checkoutApi.ts` open in VS Code; the file then flip-flopped again when the editor buffer (holding the fixed version) auto-saved. Resolution: re-read the on-disk file, confirmed it held the fix, staged + committed in the same command. Lesson: when editing a file the developer has open in the IDE, expect buffer/discard races — verify `git diff --stat` is non-empty at commit time and have the developer reload the file after.
33
+ - Carried over from mhammontree's 2026-07-27 session (still binding): do NOT force the write host inside `persistWarrantyServiceAddress` (V2 already disables the read host for the create block, `V2.php:5024`); do NOT use the 3-table JOIN lookup in postPost (0 rows in-request); do NOT merge `_underscore` to `_beta` expecting beta deploy (beta EB env API-Sandbox-Dev clones `_underscore` from `_sandbox-dev` via the api2 prebuild hook); the single-host-vs-multi-host connection theory is DISPROVEN; the payload pin code is CORRECT — its beta nulls were purely the depth starvation, now root-caused here.
34
+
35
+ ## Not tried yet (candidates for next session)
36
+ - **Beta FE rebuild/deploy from `_beta`** (now at `e4c0ead`) — until deployed, the live beta site still sends `depth=-1`.
37
+ - **Merge `_underscore` `TRUE-79533` → `_sandbox-dev` + redeploy API-Sandbox-Dev** — ships the pin + `_Exception_Validation` 400 code; beta currently has neither. Developer explicitly deferred ("wait on 2 and 3").
38
+ - **End-to-end verification purchase on beta** (after BOTH deploys): fresh WH purchase → check new entitlement `serviceAddressId` set, its `Addresses.isValidated=1`, card renders the address, duplicate purchase gets the 400 toaster. Note: the TOGa DB MCP connector was not authenticated this session — authorize it (claude.ai connector settings) or verify via other means.
39
+ - Merge `dbchanges2` `TRUE-79533` to its deploy branch for prod parity (beta already patched manually).
40
+ - The `minDepth=10` interceptor UPDATE experiment is now MOOT for this ticket (FE no longer sends -1) — keep only as input to the framework side ticket.
41
+ - Side tickets to file: (1) framework `minDepth` clamp appears to be a no-op for the `depth=-1` sentinel (starves ALL payload interceptors, including the AIG contract block, for any -1 caller); (2) SECURITY: plaintext GitHub PAT committed in `api2/.ebextensions/git.*.json` — rotate + move to env config.
42
+ - Optional cleanup on `_beta` `checkoutApi.ts`: unused `Options` import + missing trailing newline (left deliberately for a minimal diff).
43
+ - Run `/capture` (not yet run this session).
44
+
45
+ ## Current file state
46
+ | File | Status | Notes |
47
+ |------|--------|-------|
48
+ | `toga2-view/src/pages/CheckOut/api/checkoutApi.ts` | Committed `e4c0ead` on `_beta`, PUSHED to `origin/_beta` | depth option removed; unused `Options` import intentionally left |
49
+ | `toga2-view` local checkout | On `_beta` (clean, in sync with origin) | was on `rate-active-development` at session start — switch back if needed |
50
+ | `_underscore` `Model/Rate/Entitlement.php` etc. | UNTOUCHED this session | still on branch `TRUE-79533` (HEAD `41a5dc1a`), NOT on `_sandbox-dev` |
51
+ | `dbchanges2` TRUE-79533 migrations | UNTOUCHED this session | applied on beta manually; branch merge for prod still pending |
52
+
53
+ ## Decisions made
54
+ - **Fix the FE (remove `depth=-1`) instead of the interceptor `minDepth` DB experiment** — developer's explicit choice ("start with the FE fix… we will see about the database afterwards"). Rationale: fully local, no beta DB write needed, and — decisive, discovered this session — production already behaves this way, so the removal merely restores prod parity on beta. Rejected/deferred: `UPDATE ApiPayloadInterceptors SET minDepth=10 WHERE id=2` beta test (now moot for the ticket).
55
+ - **Direct edit + commit on `_beta`, no ticket branch, no `git revert`** — developer chose "edit only, no commit" for review first, then approved the commit. Justified because `0b1ed0f` was itself a beta-only direct commit and neither `_production` nor `rate-active-development` needs any change.
56
+ - **Minimal diff discipline** — did not remove the pre-existing unused `Options` import or add the missing trailing newline, so the commit is purely the depth removal.
57
+
58
+ ## Blockers
59
+ - Pin still cannot fire on beta until BOTH: (a) beta FE is rebuilt/deployed from `_beta@e4c0ead`, and (b) `_underscore` `TRUE-79533` is merged to `_sandbox-dev` and the API-Sandbox-Dev env redeployed. Developer explicitly said to wait on these.
60
+ - TOGa DB MCP connector unauthenticated in this session — needed for the eventual beta DB verification queries (or run them another way).
61
+
62
+ ## Exact next step
63
+ > Merge `_underscore` branch `TRUE-79533` (HEAD `41a5dc1a`) into `_sandbox-dev` and redeploy the API-Sandbox-Dev EB environment; confirm the beta FE has been rebuilt from `_beta@e4c0ead`. Then make ONE fresh WH purchase on beta and verify: response `meta.calcDepth` is deep, the new entitlement's `serviceAddressId` is set, its address has `isValidated=1`, and the card shows the address. (Both deploys are prerequisites — either alone changes nothing.)
64
+
65
+ ---
66
+ _Saved by /session-save on 2026-07-27_
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "toga-ai",
3
- "version": "1.0.439",
3
+ "version": "1.0.441",
4
4
  "description": "TOGA Technology Team Claude Knowledge System — shared AI coding harness with skills, knowledge base CLI, and project installer for Claude Code.",
5
5
  "keywords": [
6
6
  "claude",