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 support for validation rules #83

Merged
merged 5 commits into from
Aug 10, 2021
Merged

add support for validation rules #83

merged 5 commits into from
Aug 10, 2021

Conversation

aryaniyaps
Copy link
Contributor

@aryaniyaps aryaniyaps commented Aug 9, 2021

allows passing validation rules as an argument to the graphqlview.
also updated docs regarding the same. fixes #82

(commited by mistake. updated .gitignore)
@aryaniyaps
Copy link
Contributor Author

oops, committed venv by mistake. Updated .gitignore and removed the dir.

@@ -75,6 +76,9 @@ def get_context(self, request):
def get_middleware(self):
return self.middleware

def get_validation_rules(self):
return self.validation_rules
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should return the default validation rules if validation_rules is None:

from graphql import specified_rules

@aryaniyaps aryaniyaps requested a review from jkimbo August 9, 2021 08:34
jkimbo
jkimbo previously approved these changes Aug 9, 2021
@aryaniyaps
Copy link
Contributor Author

When would this be merged?🤔

@jkimbo
Copy link
Member

jkimbo commented Aug 9, 2021

@codebyaryan I just merged #84 Could you bring this branch up to date?

@aryaniyaps
Copy link
Contributor Author

@jkimbo done!

@jkimbo jkimbo merged commit 86b7926 into graphql-python:master Aug 10, 2021
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.

allow validation rules to be passed during schema execution
2 participants