Keming
Keming
Please fix the lint with `make envd-fmt`
It has a global `before` function which will be called in `validate > before() > endpoint func > after() > response`. ```py spec = SpecTree(before=your_func_to_modify_the_error_model) ``` Check the example: https://github.com/0b01001001/spectree/blob/bb96e101b10bc02daffa75a1b910a104811476e0/tests/test_plugin_flask.py#L26-L28...
> Technically it is possible if I add the validation error response to every endpoint, but this is a lot of redundant work, so overriding the standard error model globally...
This is global: > ```python > spec = SpecTree(before=your_func_to_modify_the_error_model) > ``` This is a specific function: ```python spec.validate(before=your_func_to_modify_the_error_model) ```
Thanks for asking. I think it's possible if we package the related frontend source code into the Python package. Does that mean you can access internal PyPI but cannot access...
Hi, @dfkki123508 thanks for your feedback. I think the `parse_comments` function doesn't support single newlines. There are two parts. https://github.com/0b01001001/spectree/blob/f04c9b79927cf4bc39eaf3ae2694297e611af2ef/spectree/utils.py#L41 This line ensures that users can write long descriptions in...
> Thanks for the quick answer! I think a workaround is probably to use html tags, but have to try it out :) HTML should work. BTW, for this kind...
I guess what you want is to show a different ValidationError in the swagger/redoc page. But the triggered error is still `pydantic.ValidationError` instead of the customized one. May I know...
> Have you found any workaround @kemingy? I've tried to play with groups without success. It's like if the root middlewares are always applied... I guess currently the only way...