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

chore: upgrade hasura to v2 #849

Merged
merged 4 commits into from
Mar 7, 2022
Merged

chore: upgrade hasura to v2 #849

merged 4 commits into from
Mar 7, 2022

Conversation

johnrees
Copy link
Contributor

https://hasura.io/docs/latest/graphql/core/guides/upgrade-hasura-v2.html#migrate-hasura-v1-instance-to-hasura-v2

in theory it should just work™

there's one thing I want to check, as I think we might be using it, or might've done in the past -

Semantics of explicit “null” values in “where” filters have changed

According to the discussion in this GitHub issue, an explicit null value in a comparison input object will be treated as an error rather than resulting in the expression being evaluated to True.

For example: The mutation delete_users(where: {id: {_eq: $userId}}) { name } will yield an error if $userId is null instead of deleting all users.

The older behaviour can be preserved by setting the HASURA_GRAPHQL_V1_BOOLEAN_NULL_COLLAPSE env var to true.

@github-actions
Copy link

github-actions bot commented Feb 17, 2022

Removed vultr server and associated DNS entries

Copy link
Contributor

@DafyddLlyr DafyddLlyr left a comment

Choose a reason for hiding this comment

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

Works for me - good find on the health check ✅

Following on from our conversation the other day, about the collapsing null - I've been using a version with this change in it for a while and haven't hit any issues with it (that I'm aware of).

@jessicamcinchak mentioned that this behaviour was present in an AddressBase related call I believe (?) which has now been removed. Is this something we're able to verify on Github to put minds at ease?

@johnrees
Copy link
Contributor Author

johnrees commented Mar 7, 2022

Works for me - good find on the health check ✅

thanks for looking @DafyddLlyr

I did a quick scan through the repo for query: gql and I don't think there's anything there that is predicated on null dropping the filter. I'll run some more quick tests today but hopefully this one is good to go 🚀

@DafyddLlyr
Copy link
Contributor

I did a quick scan through the repo for query: gql and I don't think there's anything there that is predicated on null dropping the filter. I'll run some more quick tests today but hopefully this one is good to go 🚀

Yeah I did the same and didn't see anything that could cause us issues 👍

@johnrees johnrees merged commit f67cb84 into main Mar 7, 2022
@johnrees johnrees deleted the jr/hasura-v2 branch March 7, 2022 20:52
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.

2 participants