Summary
spec/openapi.json publishes two component schemas that nothing references:
ListEnrichmentProvenanceQuery and ListOfflineBundlesQuery. Both describe
query parameters rather than request or response bodies, so no operation points
at them and no client generator has a use for them.
Redocly's no-unused-components rule reports both. They are warnings, not
errors, so make lint-openapi passes with them present:
[1] spec/openapi.json:259:7 at #/components/schemas/ListEnrichmentProvenanceQuery
Component: "ListEnrichmentProvenanceQuery" is never used.
[2] spec/openapi.json:301:7 at #/components/schemas/ListOfflineBundlesQuery
Component: "ListOfflineBundlesQuery" is never used.
spec/openapi.json: validated in 93ms
Woohoo! Your API description is valid. 🎉
You have 2 warnings.
Proposed change
Drop the ToSchema derive from both structs and remove them from ApiDoc's
component list:
backend/src/inbound/http/admin_enrichment.rs, ListEnrichmentProvenanceQuery
backend/src/inbound/http/offline.rs, ListOfflineBundlesQuery
backend/src/doc.rs, the two entries in the registered components
spec/openapi.json, regenerated by make openapi
Both types stay Deserialize and Serialize, and both remain in use through
web::Query<...> in their handlers. Only the OpenAPI registration goes.
Why this is not part of the TypeDoc gate
The change arrived on the typedoc-rollout branch (#436) inside the commit
"Repair gate-discovered validation failures", which grouped several unrelated
repairs found during a full gate run. Everything else in that commit has since
landed on main independently. This part had not, and it is a change to the
published API specification rather than a repair of a failing gate: the gate it
was attributed to passes either way. #436 restores these files to match main
and leaves the cleanup to this issue, so the specification change gets reviewed
on its own terms.
Acceptance
make lint-openapi reports zero warnings.
make openapi regenerates spec/openapi.json with no diff afterwards.
- No behavioural change to either handler.
Summary
spec/openapi.jsonpublishes two component schemas that nothing references:ListEnrichmentProvenanceQueryandListOfflineBundlesQuery. Both describequery parameters rather than request or response bodies, so no operation points
at them and no client generator has a use for them.
Redocly's
no-unused-componentsrule reports both. They are warnings, noterrors, so
make lint-openapipasses with them present:Proposed change
Drop the
ToSchemaderive from both structs and remove them fromApiDoc'scomponent list:
backend/src/inbound/http/admin_enrichment.rs,ListEnrichmentProvenanceQuerybackend/src/inbound/http/offline.rs,ListOfflineBundlesQuerybackend/src/doc.rs, the two entries in the registered componentsspec/openapi.json, regenerated bymake openapiBoth types stay
DeserializeandSerialize, and both remain in use throughweb::Query<...>in their handlers. Only the OpenAPI registration goes.Why this is not part of the TypeDoc gate
The change arrived on the
typedoc-rolloutbranch (#436) inside the commit"Repair gate-discovered validation failures", which grouped several unrelated
repairs found during a full gate run. Everything else in that commit has since
landed on
mainindependently. This part had not, and it is a change to thepublished API specification rather than a repair of a failing gate: the gate it
was attributed to passes either way. #436 restores these files to match
mainand leaves the cleanup to this issue, so the specification change gets reviewed
on its own terms.
Acceptance
make lint-openapireports zero warnings.make openapiregeneratesspec/openapi.jsonwith no diff afterwards.