-
Notifications
You must be signed in to change notification settings - Fork 13
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
Question on ent to gqlgen model binding #3
Comments
@florian-nguyen It seems like gqlgen couldn't find the model file. Could you check the autobind:
- go-ent-gqlgen/pkg/entity/model
- go-ent-gqlgen/ent And make sure that module name is correct in your module go-ent-gqlgen If you can't figure it out, let me see your code so that I can find out what happens. |
Hello @manakuro, Thanks for your kind reply. My autobind was correct, but turns out I hadn't commented the "model" section in
I spent quite some time trying to solve these issues, to no avail. Eventually I just manually corrected the mistakes in the generated files. Apart from this I was able to complete the tutorial, and I learned a lot so I am grateful to you for the time you spent on it. On a completely different topic, how are you able to have a dark theme in the playground ? Looks like the Apollo playground, but I am seeing GraphiQL's playground instead. I don't mind sharing my code. I'd be grateful if you could tell me what's happening there, but if it takes you too much time then nevermind, I'll probably figure it out one day... Here's my code : https://github.com/florian-nguyen/go-ent-gqlgen Thanks to you, |
Thanks for the clarification. @florian-nguyen
Could you get the following version and try it out again? Install
And the entgo.io/contrib v0.2.0
entgo.io/ent v0.10.1
Because gqlgen has replaced the playground with GraphiQL at some point. I was using the |
Hello @manakuro, Thanks a lot for these tips! Working better now with the ent versions you indicated. With these changes, the binding to
Where you able to reproduce this error last time you had a look at this issue? |
Okay, I confirmed that error with |
While following your great tutorial on gqlgen/ent clean architecture on Medium, I am having difficulty binding my
TodoStatus
from ent using thegqlgen.yaml
file using the following lines.Despite spending quite some time trying to understand what I am missing here, I am still having the following error upon running the
gqlgen
command, and I wanted to ask if it is familiar to you:At this point I am suspecting a wrong configuration of Go on my machine, but as someone relatively new to the language I was unable to find what is causing my issue. I would really appreciate if you could help me find the root cause.
go env output
And allow me at last to thank you for your articles. It is quite difficult to find advanced tutorials on Golang and I enjoy very much learning through yours.
Thank you,
Florian
The text was updated successfully, but these errors were encountered: