After more digging than I expected (and planned), I'm 99% sure that the problem comes from `graphene_django`.

I found a [comment](16436f3751/django/db/models/fields/reverse_related.py (L4-L6)) in Django's source that refers to an attribute named `remote_field`, instead of `rel`.

It seamed to fix the problem for me without any other bugs (yet).
This commit is contained in:
eyal0803 2018-02-22 05:45:40 +02:00 committed by GitHub
parent dbd3957a9f
commit e51f6070df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,7 +57,7 @@ class GrapheneFilterSetMixin(BaseFilterSet):
Global IDs (the default implementation expects database
primary keys)
"""
rel = f.field.rel
rel = f.field.remote_field
default = {
'name': name,
'label': capfirst(rel.related_name)