-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Flask plugin does not gracefully fail when view is None #133
Comments
IIRC, this exception is made for methods that are not implemented in a
plugin. I wouldn't use that.
apispec is not really meant to handle multiple plugins having a
path_helper method. It uses the last value that is not None.
Therefore, I'm not sure it would be a good idea to do that.
Still, I guess the method could return None rather than crash.
Would you like to submit a PR?
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I cannot use
spec.path
without providingview
.In
flask.py
:The assert statement completely fails, this means that if someone was to define multiple plugins for apispec, then because this one fails any time view is not defined, there is no way forward.
Inside
core.py
inside theapispec
, library, they handle anyPluginMethodNotImplementedErrors
, and move on. I would suggest raising that exception instead.The text was updated successfully, but these errors were encountered: