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

Add compatibility with Django 4.0 and 4.1 #191

Merged
merged 10 commits into from
Jan 12, 2023
Merged

Conversation

washeck
Copy link
Contributor

@washeck washeck commented Dec 9, 2022

This PR is mainly based on #181 but I tried to make it in such a way that GitHub actions passes so it can be merge with no additional work.

washeck and others added 7 commits December 8, 2022 09:56
Commit b9423b74ca9d22d009a1a4633b38b2bcd06c604b in graphql-core
changed specified_directives from FrozenList to Tuple making
it impossible to concatenate with list.
- djangorestframework version specifier "^no" was not valid
- fix pytest error by upgrading to the latest version supporting
  python3.6
  (TypeError: required field "lineno" missing from alias)
as tox changed the naming.
and remove forgotten python 3.6 requirement as it conflicts
with the latest black.
and simplify tox environment configuration to be more maintenable.
@andrei-shabanski
Copy link

@washeck Thank you for your PR! Now it's the only way to use this package with django 4.

I think it's worth checking out the PR with python 3.11. Can you update tox and CI configs to run tests on python 3.11?

@washeck
Copy link
Contributor Author

washeck commented Jan 12, 2023

Actually, I thought it would be easier to add python 3.11 after it is added to graphene-django itself, see graphql-python/graphene-django#1365

@andrei-shabanski
Copy link

I didn't notice that. Agree with you

One more question about django-filter. graphene-django tests are run with django-filter>=22.1. However, graphene-django-extras still requires django-filter >=2.2.0, <3.

It seems that django-filter 22.1 doesn't have major changes since 2.2.0. Mainly, they removed outdated warnings and switched to a two-part versioning scheme. The latter doesn't allow to install the latest version django-filter with graphene-django-extras in the same project.

Does it make sense to upgrade django-filter version in pyproject.toml up to 22.1?

@eamigo86 eamigo86 merged commit 84ba26e into eamigo86:master Jan 12, 2023
@washeck washeck deleted the django40 branch January 12, 2023 10:57
@bernardopericacho
Copy link
Contributor

I didn't notice that. Agree with you

One more question about django-filter. graphene-django tests are run with django-filter>=22.1. However, graphene-django-extras still requires django-filter >=2.2.0, <3.

It seems that django-filter 22.1 doesn't have major changes since 2.2.0. Mainly, they removed outdated warnings and switched to a two-part versioning scheme. The latter doesn't allow to install the latest version django-filter with graphene-django-extras in the same project.

Does it make sense to upgrade django-filter version in pyproject.toml up to 22.1?

I hit this when trying to install from master branch

 poetry add git+ssh://[email protected]:eamigo86/graphene-django-extras.git#master 

Updating dependencies
Resolving dependencies... (8.1s)

  SolverProblemError

  Because graphene-django-extras (rev master) depends on django-filter (^2.2.0)
   and oddsjam-backend depends on django-filter (^21.1), graphene-django-extras is forbidden.
  So, because oddsjam-backend depends on graphene-django-extras (rev master), version solving failed.

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 this pull request may close these issues.

5 participants