torchbox / wagtail-grapple

A Wagtail app that makes building GraphQL endpoints a breeze!
https://wagtail-grapple.readthedocs.io/en/latest/
Other
152 stars 57 forks source link

ImportError: cannot import name 'get_document_model' from 'wagtail.documents.models' #93

Closed shanewilson closed 4 years ago

shanewilson commented 4 years ago

related to #46

wagtail==2.10 wagtail-grapple==0.5.5

 File "/usr/local/lib/python3.8/site-packages/grapple/types/search.py", line 3, in <module>
api_1  |     from wagtail.documents.models import get_document_model
api_1  | ImportError: cannot import name 'get_document_model' from 'wagtail.documents.models' (/usr/local/lib/python3.8/site-packages/wagtail/documents/models.py)
...
 ImportError: Could not import 'grapple.schema.schema' for Graphene setting 'SCHEMA'. ImportError: cannot import name 'get_document_model' from 'wagtail.documents.models'

It looks like only one of the two get_document_model imports was updated: https://github.com/GrappleGQL/wagtail-grapple/search?q=get_document_model&unscoped_q=get_document_model

zerolab commented 4 years ago

Thank you for this @shanewilson Fixed in 569b05d

zerolab commented 4 years ago

I've pushed v 0.5.6 to pypi