MOB-12 — Staging integration — real API, edge states, performance
Switch both apps from the mock to staging, walk every flow, fix contract mismatches, cold-start and list performance on a mid-range Android.
| Field | Details |
|---|---|
| Task code | MOB-12 |
| Phase | P1 — V1 build & integration |
| Product scope | V1 |
| Status | Planned |
| Start | Tue 15 Dec 2026 |
| Due | Thu 17 Dec 2026 |
| Responsible | Imad — Mobile developer (Flutter) |
| Co-responsible | Anis |
| Effort | 2 person-day(s) planned · 5 from scratch · size M |
| Area · app | Mobile quality · mobile |
| Depends on | MDA-12, SRV-23, SRV-18, SRV-19, SRV-24, SRV-26 |
| Unblocks | MOB-13, QA-03 |
| Milestones | — |
Summary
Switch both apps from the mock to staging, walk every flow, fix contract mismatches, cold-start and list performance on a mid-range Android.
Description
Until now both apps ran against the Prism mock; this task proves them against the real staging server and fixes every mismatch before acceptance testing (NFR-01, NFR-04). Scope: point the staging flavor at api-staging.hoco.dz, walk every RA and DA flow on seeded data, log and fix contract mismatches on both sides, verify edge states (forced update, maintenance, pending, suspended, out-of-tolerance, offline replay, SSE live updates, push) and measure cold start and list performance on a mid-range Android. Anis contributes seeded accounts, server fixes and SSE/proxy configuration; Imad owns the walkthrough and the app fixes. It depends on SRV-23 (sync), SRV-18 (billing), SRV-19 (promotions), SRV-24 (support) and SRV-26 (SSE) being on staging. QA-03 and MOB-13 start from the build produced here.
Subtasks
| # | Subtask | Owner |
|---|---|---|
| 1 | Staging flavor on https://api-staging.hoco.dz/v1, contract re-pinned to the deployed openapi.json and client regenerated | Imad |
| 2 | Seed staging with test accounts: guest-ready catalog with attributes, resellers of each customer type (SUPER_GROS, DEMI_GROS, DETAIL), pending and suspended resellers, two delegates with today's tours, promotions, invoices, a delivered order for returns and claims | Anis |
| 3 | Flow walkthrough checklist over RA-01…RA-41 and DA-01…DA-28, each screen checked against the real API with results recorded | Imad |
| 4 | Contract mismatch log as GitHub issues labelled contract with the op id, payload sample and requestId; fixes on the app side | Imad |
| 5 | Server-side fixes for mismatches and missing fields found during the walkthrough | Anis |
| 6 | Edge states on staging: AppVersionPolicy forced update and maintenance, ACCOUNT_SUSPENDED, ACCOUNT_PENDING_VALIDATION, GPS_OUT_OF_TOLERANCE, VISIT_LOCKED, IDEMPOTENCY_KEY_REUSED, OCCURRED_AT_OUT_OF_RANGE | Imad |
| 7 | SSE through the staging reverse proxy (buffering off, timeouts) verified with the reseller app; push end-to-end from staging events | Anis |
| 8 | Performance on a mid-range Android (profile mode): cold start, catalog first page and facets, orders list, tour programme with 30 stops; image caching and list jank fixes | Imad |
| 9 | Offline replay against the real SRV-23: 30 queued mutations including photos, replayed twice, zero duplicates | Imad |
Deliverables
- Firebase App Distribution build 0.9.0 (staging) of both apps
- Walkthrough checklist with per-screen status (docs/integration-checklist.md in hoco-mobile)
- Closed contract-mismatch issues in hoco-mobile and AnisBetehi/hoco
- Performance measurements (cold start, first catalog page, list frame times) recorded in the repo
Acceptance criteria
- Every V1 screen of both apps works against staging with no open contract mismatch
- Cold start to an interactive home is under 3 s and catalog/filter results under 3 s on a mid-range Android on 4G (NFR-01)
- Lists scroll without dropped frames visible in DevTools on the catalog grid and tour programme
- Order status changed in the dashboard reaches the open reseller app live via SSE and the backgrounded app via push
- A replayed offline batch produces no duplicate visit, photo, prospect or note
Requirements covered
| Requirement | Title | Release |
|---|---|---|
| NFR-01 | Performance: app opens and search/filter results in under 3 s on a normal mobile connection; API p95 targets | V1 |
| NFR-04 | Android first on mid-range phones; iOS on client decision | V1 |
Test measures
- Manual walkthrough checklist executed on two devices (mid-range Android 10 and Android 14)
- integration_test suites (auth, checkout, visit) pointed at staging
- Profile-mode performance traces saved for cold start and lists
Risks
- Staging data not representative (few products, no attributes) hides performance issues — seed at production scale (catalog import from SRV-27 data)
- Late server changes reopen mismatches — freeze the contract version for the walkthrough window
KPI
- Delivered by Thu 17 Dec 2026 within 2 person-day(s).
- Every acceptance criterion above demonstrated before hand-off; linked requirements' acceptance criteria pass.
- Zero open critical defects, permission gaps or data-integrity regressions at sign-off.
Generated from content/plan/tasks.json by scripts/generate-team-tasks.mjs. Dates are computed by the scheduler (Sunday–Thursday weeks, holidays excluded) — change the plan, not this page.
MDA-12 — Delegate app — location sampling during tours
Policy-driven sampling only while a tour is in progress, batching, battery-friendly settings, foreground-service notice on Android.
MOB-13 — Field test with a delegate — GPS, weak network, offline
A real tour in Oran-like conditions: tolerance, airplane-mode visits and sync recovery, photo queue, battery drain measured.