gendesign/frontend/src/lib
lekss361 142ed95d36
fix(frontend): apiFetchWithStatus body stream double-read crash (#149)
Per user report 2026-05-14: 'Failed to execute text on Response: body stream
already read' при analyze с non-JSON error response.

apiFetchWithStatus делал .json() (consumes stream), потом .text() в catch
(FAILS — stream already consumed). Fetch API: body — ReadableStream,
consumable один раз.

Fix: read text() once → JSON.parse on string. На fail (HTML / non-JSON)
оборачиваем в {detail: rawText}. Никаких double-reads.

Site-finder cad search больше не крашится на error pages.

Co-authored-by: lekss361 <claudestars@proton.me>
2026-05-15 07:39:21 +03:00
..
api feat(site-finder): weight profile panel + analyze options (#114 sub-PR 4/4 FINAL) (#139) 2026-05-15 00:50:02 +03:00
adminStyles.ts refactor(frontend): extract SectionLabel + EmptyState + adminStyles shared (#132) 2026-05-14 23:55:38 +03:00
analytics-api.ts feat(analytics): buildings block + dynamic developer comparison 2026-05-11 16:03:16 +03:00
api-types.ts feat(admin): /admin/jobs/settings page — inline-edit Celery job config 2026-05-11 15:47:39 +03:00
api.ts fix(frontend): apiFetchWithStatus body stream double-read crash (#149) 2026-05-15 07:39:21 +03:00