Bug: /v1/digitize response always returns regions: [] (dead or broken field) #28
Labels
No labels
blocked:needs-attention
blocked:needs-decision
bug
feature-request
in-progress
needs-decompose
quickfix
triage-approved
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Mark/easystitch-service#28
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
POST /v1/digitizealways returns"regions": []regardless of input, even when the engine successfully producesstitchObjectsand reportscolorCount: 2. Theregionsfield is part of the documented response shape but appears to never be populated.Reproduction
Why this matters
ThreadCraft's UI relies on
regions[]to render overlay polygons on the Fabric.js canvas. Whenregions: [], the user gets the stitch objects (which is what gets exported) but no visible overlay of where the regions are. UX is degraded without obvious feedback.Likely root cause
Per the secondary finding in the 2026-09-01 shakedown (session
20260901_085043_f35d0513): "the grouping loop never flushing."pipeline_runner.pyproduces the StitchObject list but the regional grouping pass before it isn't producing output (or its output is dropped before serialization).Suggested fix
Either:
_group_stitches_into_objects(or equivalent) inpipeline_runner.pyto find where region results get dropped, orRelated
stitch_objectscame back empty while stats said 6572 stitches"UI verification follow-up (2026-09-10)
The file upload barrier is now cracked (DataTransfer + Object.defineProperty + dispatchEvent). Confirmed via BrowserOS MCP
snapshotthat ThreadCraft's settings panel unlocks after upload but:act click/act kind=select/ PointerEvent sequence closes the dropdown without updating React state. The next snapshot re-shows the original option as[selected]. Captured React props via__reactPropsconfirmedonClickexists but does not fire under synthetic dispatch.e12or inner-modal Confirm & Edite65) sets Redux state to'digitizing'then'digitized'with a hardcoded "Auto-digitize complete!" message but never firesrunAutoDigitize()→digitize()→ POST to/v1/digitize. BrowserOS MCPhook fetchconfirmed only/healthzGETs during the click sequence. Service log shows zero digitize POSTs across the entire 2026-09-09/10 verification session.This means the UI cannot drive a digitize or export at all in the current ThreadCraft build. The API bugs (#27-31) are still the canonical surface; the UI bugs are symptom-level and tracked separately as #32 (silent no-op), #33 (combobox click swallowed), #34 (false-complete message). Those three will be closed as duplicates of this issue family once the canonical root causes land.
Visual verification (2026-09-09): All four canvas screenshots show empty workspace ("Drop your image here" / dashed drop zone visible in 3 of 4, blank faint circular hoop outline visible in FINAL_workspace_full.png). The bug's surface symptom (no region polygons after digitize) cannot be visually confirmed without first uploading an image, which BrowserOS MCP cannot do for hidden file inputs. The curl probe in the original bug body (showing
regions: []in successful responses) is still the primary evidence.