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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError on Django 2.1 #956

Closed
vannitotaro opened this issue Aug 2, 2018 · 5 comments
Closed

ImportError on Django 2.1 #956

vannitotaro opened this issue Aug 2, 2018 · 5 comments

Comments

@vannitotaro
Copy link

Hi there, I know that at present only Django 1.11 and 2.0 are supported, anyway I think that you'd like to make it working on 2.1 too sooner or later 馃槂 so:

File ".../lib/python3.5/site-packages/django_filters/__init__.py", line 4, in <module>
    from .filterset import FilterSet
  File ".../lib/python3.5/site-packages/django_filters/filterset.py", line 16, in <module>
    from .filters import (Filter, CharFilter, BooleanFilter, BaseInFilter, BaseRangeFilter,
  File ".../lib/python3.5/site-packages/django_filters/filters.py", line 9, in <module>
    from django.db.models.sql.constants import QUERY_TERMS
ImportError: cannot import name 'QUERY_TERMS'
@vannitotaro
Copy link
Author

This is the "offending" commit:

django/django@244cc40#diff-112486a821c7f63d1ab955c6bb2b4db8

@rpkilby
Copy link
Collaborator

rpkilby commented Aug 2, 2018

Hi @vannitotaro, have you installed the latest 2.x release for django-filter? It should be compatible with Django 2.1

@vannitotaro
Copy link
Author

Great! Thank you @rpkilby, django-filter 2.0.0 from pypi works great with Django 2.1.
Time to update README with supported Django versions! 馃巻

@vannitotaro
Copy link
Author

DRF-related (just for other people search reference): philipn/django-rest-framework-filters#226

@rpkilby
Copy link
Collaborator

rpkilby commented Aug 2, 2018

Right - the 1.0 milestone for django-rest-framework-filters is basically ready. I'm just working on updating documentation. It's grown to the point where it no longer fits comfortably in the readme.

The master branch is effectively stable, although I'd pin at a specific commit until 1.0 is released.

dimidd added a commit to dimidd/doccano that referenced this issue Oct 11, 2018
Solves the import error
carltongibson/django-filter#956

Signed-off-by: Dimid Duchovny <dimidd@gmail.com>
talmago pushed a commit to talmago/doccano that referenced this issue Nov 12, 2018
Solves the import error
carltongibson/django-filter#956

Signed-off-by: Dimid Duchovny <dimidd@gmail.com>
jieter pushed a commit to jieter/django-tables2 that referenced this issue Feb 14, 2019
* Update requirements.txt

Update required version of django-filter to 2.1.0 to work with Django 2.1,
see: carltongibson/django-filter#956

* Fix README.md to correctly describe example setup
AppleJin512 pushed a commit to AppleJin512/django-tables2 that referenced this issue Feb 21, 2023
* Update requirements.txt

Update required version of django-filter to 2.1.0 to work with Django 2.1,
see: carltongibson/django-filter#956

* Fix README.md to correctly describe example setup
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

No branches or pull requests

2 participants