Treat OpenAPI path parameters as required in v4 import This tracks unresolved feedback…
- User
Treat OpenAPI path parameters as required in v4 import This tracks unresolved feedback identified by cubic on PR #1149: https://github.com/withcoral/coral/pull/1149#discussion_r3347190640
Context: This appears to be pre-existing DSL v4 behavior surfaced by the refactor review, not a regression from the module split.
Problem: OpenAPI path parameters are imported as optional when
requiredis omitted, even though path parameters are required by OpenAPI. This can misclassify required path inputs as optional SQL filters.Acceptance criteria: Import path parameters as required regardless of an omitted
requiredfield, preserve explicit behavior for non-path parameters, and add focused importer/projection coverage.Interface
No new interfaces are introduced.
- Assistant
I’ll trace the v4 OpenAPI importer and projection tests, patch the requiredness rule at the import boundary, then run focused tests and the repository Rust gate.
- Assistant
rgisn’t installed in this workspace, so I’m using targetedfind/grepsearches instead. - Assistant
The importer currently defaults every parameter location to
required: false. I’m changing that normalization sopathalways wins as required, while query/header/cookie parameters still honor their explicit boolean and otherwise remain optional. Because this changes materialized semantic IR, I’m also advancing the importer version so stale v4 artifacts fail with the existing re-add guidance. - Assistant
The code formats cleanly. The first focused test command used Cargo’s filter syntax incorrectly; I’ve corrected it and the v4 test suite is compiling now.
- Assistant
Both new focused cases pass, along with all 221
coral-specunit tests and its doctest. The diff is clean; I’m running the required all-features Rust gate now. - Assistant
The Rust gate caught one test-only lint (
operations[0]can panic). I’m switching that assertion setup to the repository’s preferred checked access, then rerunning the full gate. - Assistant
Formatting and all-features Clippy now pass. The gate then stopped because this image lacks the
cargo-nextestexecutable; I won’t fetch tooling externally. I’m running the equivalent workspace test fallback and will also run the remaining docs command from the Makefile. - Assistant
The workspace fallback completed all unit suites, but two unrelated filesystem-permission integration tests fail because the container runs as root (their read-only cleanup/config fixtures remain writable). The changed
coral-specsuite and 185coral-appunit tests passed. I’m finishing the required warnings-as-errors docs check and then doing a final diff/status review.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.