You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This can't be solved by changing the parent of FilesBinder to BodyBinder because FilesBinder will conflict with FromFromBinder when they are used together. BlackSheep allows to have only one body binder for a handler.
I found the only way to see the file upload button in UI is to use the Pydantic model with the bytes field.
There is a solution for objects like dataclasses and Pytdantic models to see multi-file upload. OpenAPIHandler should resolve a schema for bytes simple type in _try_get_schema_for_simple_type method.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
I found that BlackSheep can't generate proper OAS for a multi-part body if a handler uses
BodyBinderviaFromFilestype binder.I've expected to have something like this.
This can't be solved by changing the parent of
FilesBindertoBodyBinderbecauseFilesBinderwill conflict withFromFromBinderwhen they are used together. BlackSheep allows to have only one body binder for a handler.I found the only way to see the file upload button in UI is to use the Pydantic model with the
bytesfield.There is a solution for objects like dataclasses and Pytdantic models to see multi-file upload.
OpenAPIHandlershould resolve a schema forbytessimple type in_try_get_schema_for_simple_typemethod.Then, those classes will look like in the image below.
Have I missed something? Any other workarounds?
All reactions