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

Supplant @hybrid_property's type annotation support with Optional[T] #343

Merged

Conversation

flipbit03
Copy link
Contributor

This PR supplants the previous "hybrid property type inference" work by adding support for Optional[T] as well.

Currently, all inferred hybrid properties are optional, so this work is mainly done for completeness sake (and so that we can have Option[T] properly rendering T in GraphQL objects).

An additional test was written to cover this new capability.

@codecov-commenter
Copy link

Codecov Report

Merging #343 (f41e847) into master (0820da7) will increase coverage by 0.02%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #343      +/-   ##
==========================================
+ Coverage   96.35%   96.38%   +0.02%     
==========================================
  Files           9        9              
  Lines         714      719       +5     
==========================================
+ Hits          688      693       +5     
  Misses         26       26              
Impacted Files Coverage Δ
graphene_sqlalchemy/converter.py 96.46% <100.00%> (+0.09%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0820da7...f41e847. Read the comment docs.

@erikwrede erikwrede merged commit b0aa63c into graphql-python:master May 3, 2022
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.

3 participants