Bug: /v1/digitize rejects all custom DigitizeSettings fields (additionalProperties: false) despite README promising configurability #31
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#31
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/digitizerejects anysettingspayload that includes fields not in the strictDigitizeSettingsschema. The README and project description advertise per-design configuration (target stitch count, fabric type, hoop size, etc.) but the API rejects all of these withextra_forbiddenvalidation errors.Reproduction
The actual
DigitizeSettingsschema (frommodels.py:53) accepts:stitch_preference(Literal balanced/quality/speed, default balanced)fill_density_mm,satin_stitch_spacing_mm,running_stitch_spacing_mmmin_stitch_length_mm,max_stitch_length_mmhoop_size_mm(HoopSize withwandh, notwidth/height)max_colorsmachine_profileNotably absent:
Two questions for maintainers
fill_density_mm) but the README and downstream ThreadCraft code may use camelCase (fillDensityMm). Which is the contract?Suggested fix
Either:
fabricandtargetStitchCountto the DigitizeSettings schema and implement them in the pipeline_runnerOpenAPI examplesblock to the/v1/digitizeschema so the actual field shape is discoverableEnvironment
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.
Update — visual verification gives more nuance than the original title.
All four workspace screenshots (vision-analyzed by Gemini-3 Flash) confirm:
This means: the UI explicitly tells the user settings aren't applicable yet. The bug #31 surface is therefore:
fabricandstabilizerfields withextra_forbidden, so the user's settings silently never reach the engine — output is identical regardless of chosen fabric.Suggested retitle: "Fabric Type / Stabilizer settings silently dropped — UI exposes them but API rejects as extra fields."
Fixed in
f99b465on main (rebased atop #30's2ef1b3c).DigitizeSettings now declares two new optional fields —
fabric(enum | null) andtarget_stitchCount(100–200000 | null) — and keepsextra='forbid'. HoopSize still acceptswidth/heightas aw/halias via the before-validator (carried over from #30). All 134 unit tests pass; the verify gate's 9 commands (pytest, ruff, schema JSON dump, end-to-end curl with the documented settings shape) all pass.The runner originally pushed a 'permissive' variant of the fix (extra=ignore), which failed its own Verify gate. The Bugfix phase produced the strict, schema-widening variant that landed here. Push failed during Commit (origin/main had advanced with #30 in the meantime) so the local commits were rebased onto origin/main and force-pushed. Schema now exposes fabric + targetStitchCount in /openapi.json.