-
Notifications
You must be signed in to change notification settings - Fork 8
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
Relationships break in ruby-graphql >= 1.9 #12
Comments
I've narrowed this down to being introduced in this commit: rmosolgo/graphql-ruby@f06ab79. Here's the PR introducing this commit: rmosolgo/graphql-ruby#1758. It had an issue which is why it were pushed to 1.9 rather than released as a minor to 1.8. Maybe it's related. Prior to this, the I'll try and find time to dive deeper into this... |
This introduced Commenting it out allows |
@ostrgard thank you very much for using this gem, it makes me really happy. Feel free to send a PR if you find the solution to the ruby-graphql version upgrade. Unfortunately I stopped using this gem because of lack of support/usage, and that resolves in no maintenance from my side. |
@ostrgard I've been trying to upgrade to graphql1.9, here are the results: I am leaving the progress in a different branch because it seems to be working when there is only one worker in the puma.rb server configuration file. But when there is more than one, like: I think I will try a different way of loading the gem as a next step, by declaring the models in the config file instead of including concerns. Any ideas ? 😄 |
Hi! Love this gem, thanks for creating it!
I've had issues implementing it in a project and isolated it to the fact that we used ruby-graphql >=1.9. Upgrading the root
.gemspec
and thetester_ar
project to 1.9 allowed me to reproduce this.The relationships are not being added to the queries as they were before. However, relocating the
include Graphoid::Queries
to the bottom of the model classes (or just below all relationship definitions) will add some of these, depending on the order they're being mapped over byGraphoid::Types
. For instance, theUser
model goes first, and theGraphoid::Queries::LIST
is empty, whileAccount
goes last and is able to addUser
relations due to it being present inLIST
by that point.I've been looking through the ruby-graphql changelog for 1.9.0 and can't really identify some obvious reason for this to break. I checked ruby-graphql 1.8.17 which works as expected.
I'll continue investigating this...
The text was updated successfully, but these errors were encountered: