-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
reloading module info generating core failed: #1849
Comments
Seems to be broken with the new release, v0.16.0. For reproduction, just follow the steps at https://gqlgen.com/#quick-start, then try to call |
@StevenACoffman is this a real issue? |
Facing the same issue as above after following the quick start steps |
@frederikhors I think we need to update quick start instructions. The empty model directory causes this issue. |
@ipfans can you PR please? |
@ipfans The model directory gets cleared during generation, isn't it? |
@ubiuser yes, it is. I just hit this issue as well with v0.16.0 ... if I switch to v0.15.1 everthing works ok:
|
@frederikhors @StevenACoffman Can we use master branch to gqlgen.com, or we need to tag a new version to update quickstart. |
Just make a PR for the https://github.com/99designs/gqlgen/blob/master/README.md and I will take care of the rest. |
The code generation is still broken and I believe the change to |
@ubiuser Can you give me an example that reproduces a problem? |
@StevenACoffman Reproduction in a shell with output:
As you can see the |
Thanks, that is very helpful for me to understand what you meant, and I agree the current situation is awkward, and adding the empty file definitely is a workaround. Without an empty non-generated file, you will encounter a problem with the autobind. It will try to autoload the empty dir and fail. |
I understand now, thank you for the explanation. |
I would be very excited to get a PR that would allow us to NOT throw an error in this specific case (just haven't generated yet) but DO throw an error when we after we generate the thing we are trying to autobind is still not there. That would help a lot of people getting started to avoid a confusing situation. |
I don't believe this should be closed yet - we're saying it's a regression introduced in #1773, right?. gqlgen should handle this gracefully, not require you to add model files manually before running generate |
write down my go.mod when I checked it
|
I think I misunderstood. In any case, the original issue I can't reproduce any longer, so I think #1850 can be reverted |
When following the directions, users got an error because gqlgen cannot autobind to an empty models directory. |
What happened?
gqlgen --config ./gqlgen.yml
gqlgen.yml
schema.graphs
What did you expect?
Minimal graphql.schema and models to reproduce
versions
gqlgen version
?go version
?The text was updated successfully, but these errors were encountered: