Auto schema generation#13
Conversation
❌ Deploy Preview for m2on failed.
|
|
Hey @vincerubinetti, sorry for the huge delay. After finally squaring away the search optimizations and other issues, I found that the typing changes needed for this PR are actually pretty modest. I've pushed a few commits that add the annotations and re-ran the schema generation. It now completes with one warning: IMO it's fine to ignore that; basically, the cart view is exempt from CSRF verification because it uses an "unsafe" operation (POST) and having to send you a CSRF token to submit with the request is IMHO tedious and unnecessary. The CSRF exemption doesn't actually change the return type, but since it's not annotated OpenAPI doesn't know that and throws a warning. I've committed the updated AFAICT it's working now, so I'd be in favor of merging this. Once it's reconciled with |
|
Ready to merge when you are. If I understand correctly, this will also resolve the actual runtime differences which are currently causing e.g. the search, sample popup, etc. to error with schema validations? |
|
Actually, sorry, I missed the reference to
I presume so; I assume Orval will rewrite FWIW, I just ran the schema generation and it's unhappy about Apparently Spectacular chose not to emit type definitions for |
…artViewSet to be emitted by schema gen
…for types gen. Updates frontend path to /data/schema.yaml"
…ort container types gen, falling back to the original path for host types gen
…tend types accordingly. Search.tsx now comma-joins the list rather than displaying it verbatim.
No description provided.