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 copy function for GrapheneGraphQLType #1463

Merged
merged 2 commits into from
Oct 24, 2022

Conversation

keu210
Copy link
Contributor

@keu210 keu210 commented Sep 30, 2022

Fixes #1333

First found in a Django project while upgrading to graphene 3. Django's setUpTestData tries to create a copy of a GrapheneGraphQLType and raises a KeyError: 'graphene_type'. This doesn't happen in graphene 2.1.8

Fixes graphql-python#1333

First found when using  with a Django project. Django's  tries to create a copy of a GrapheneGraphQLType and raises this KeyError
@codecov
Copy link

codecov bot commented Oct 23, 2022

Codecov Report

Base: 95.88% // Head: 95.87% // Decreases project coverage by -0.00% ⚠️

Coverage data is based on head (f98da8f) compared to base (ee1ff97).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1463      +/-   ##
==========================================
- Coverage   95.88%   95.87%   -0.01%     
==========================================
  Files          51       50       -1     
  Lines        1726     1722       -4     
==========================================
- Hits         1655     1651       -4     
  Misses         71       71              
Impacted Files Coverage Δ
graphene/types/definitions.py 100.00% <100.00%> (ø)
graphene/__init__.py

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@erikwrede
Copy link
Member

Sorry for the long wait, thank you for the PR!
Can you please install & execute the pre-commit hooks to fix the linter?

@keu210
Copy link
Contributor Author

keu210 commented Oct 24, 2022

Sorry for the long wait, thank you for the PR! Can you please install & execute the pre-commit hooks to fix the linter?

sg. thanks!

@erikwrede
Copy link
Member

Thank you for the contribution 🙂.
Expect release in next patch!

@erikwrede erikwrede merged commit 6969023 into graphql-python:master Oct 24, 2022
@keu210 keu210 deleted the copy-graphene-graphql-type branch October 24, 2022 21:45
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.

KeyError when making shallow copy of GrapheneObjectType
2 participants