Skip to content
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

Optional Marshmallow integration raises import error #50

Closed
devdupont opened this issue Jan 28, 2021 · 4 comments · Fixed by #51
Closed

Optional Marshmallow integration raises import error #50

devdupont opened this issue Jan 28, 2021 · 4 comments · Fixed by #51

Comments

@devdupont
Copy link

The swagger.py file is raising a missing import error when importing the optional Marshmallow support.

from .marshmallow import MARSHMALLOW, schema_to_json

The issue is that schema_to_json is not available when the marshmallow and marshmallow_jsonschema libs raise an ImportError:

except ImportError:
    Schema = None
    JSONSchema = None
    MarshmallowValidationError = None
    MARSHMALLOW = False
    # No replacement for schema_to_json
@devdupont
Copy link
Author

Tested with:

Quart                  0.14.1
quart-openapi          1.7.0

@iron-road-dev
Copy link

I get the same ImportError when using quart==0.14.1 and quart-openapi==1.7.0

Downgrading to quart==0.13.0 and quart-openapi==1.6.0 fixed the issue

@zeroshade
Copy link
Contributor

@flyinactor91 @iron-road-dev once version 1.7.1 is finished deploying to pypi, please give that a try to fix this issue.

@iron-road-dev
Copy link

@zeroshade All is well with 1.7.1; thank you for the quick turn around.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants