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

Clean up API #25

Closed
benjaminjkraft opened this issue Apr 22, 2021 · 2 comments · Fixed by #82
Closed

Clean up API #25

benjaminjkraft opened this issue Apr 22, 2021 · 2 comments · Fixed by #82
Assignees
Milestone

Comments

@benjaminjkraft
Copy link
Collaborator

benjaminjkraft commented Apr 22, 2021

This is just to make sure there's nothing in godoc that we don't want to commit to. Although of course in v0 we don't totally have to.

At some point we will also need to decide if we consider a change to generated code to be breaking; it is only if you re-run your generator but obviously you want to be able to do that. (What if it's a non-functional change? That's only breaking if you expect your generator to be deterministic, which you might also reasonably want.)

See also #19.

@benjaminjkraft benjaminjkraft added this to the OSS "launch" milestone Apr 22, 2021
@benjaminjkraft
Copy link
Collaborator Author

benjaminjkraft commented May 1, 2021

At some point we will also need to decide if we consider a change to generated code to be breaking; it is only if you re-run your generator but obviously you want to be able to do that. (What if it's a non-functional change? That's only breaking if you expect your generator to be deterministic, which you might also reasonably want.)

@StevenACoffman I'm interested if you know how other code-generation libraries in Go handle this. It seems very awkward to me because it's going to be hard to guarantee that existing generated code is rarely updated -- even the smallest bugfix may need to change it! But if users want to check in the generated code, and make sure go generate ./... never introduces changes, then on some level it is a breaking change. That's especially true if the changes could cause your code to no longer compile. How do other libraries handle this? Do they just assume that changes to generated code are never breaking, because you can always just not run the generator?

@benjaminjkraft
Copy link
Collaborator Author

The compat issue is now discussed more at #63, but I think for v0 the path is clear enough, so this is just to make sure we do a pass over godoc before launching.

benjaminjkraft added a commit that referenced this issue Sep 9, 2021
Before open-sourcing, we want to make sure that (a) GoDoc looks
reasonable, and (b) everything in the API is something we want to commit
to.  In this commit, I do some miscellaneous cleanup on both fronts;
this does involve a few breaking changes to the programmatic API (better
now than once it has users).  In future commits, I'll likely move the
documentation for `genqlient.yaml` and `@genqlient` to clearer places,
and make `GenqlientDirective` private, such that GoDoc is really only
for programmatic users.

Fixes #25.

Issue: #25

Test plan: make check

Reviewers: marksandstrom, miguel, adam
@benjaminjkraft benjaminjkraft linked a pull request Sep 9, 2021 that will close this issue
@benjaminjkraft benjaminjkraft self-assigned this Sep 9, 2021
benjaminjkraft added a commit that referenced this issue Sep 10, 2021
Before open-sourcing, we want to make sure that (a) GoDoc looks
reasonable, and (b) everything in the API is something we want to commit
to.  In this commit, I do some miscellaneous cleanup on both fronts;
this does involve a few breaking changes to the programmatic API (better
now than once it has users).  In future commits, I'll likely move the
documentation for `genqlient.yaml` and `@genqlient` to clearer places,
and make `GenqlientDirective` private, such that GoDoc is really only
for programmatic users.

Fixes #25.

Issue: #25

Test plan: make check

Reviewers: marksandstrom, miguel, adam
benjaminjkraft added a commit that referenced this issue Sep 10, 2021
Before open-sourcing, we want to make sure that (a) GoDoc looks
reasonable, and (b) everything in the API is something we want to commit
to.  In this commit, I do some miscellaneous cleanup on both fronts;
this does involve a few breaking changes to the programmatic API (better
now than once it has users).  In future commits, I'll likely move the
documentation for `genqlient.yaml` and `@genqlient` to clearer places,
and make `GenqlientDirective` private, such that GoDoc is really only
for programmatic users.

Fixes #25.

Issue: #25

Test plan: make check

Reviewers: marksandstrom, miguel, adam
benjaminjkraft added a commit that referenced this issue Sep 10, 2021
## Summary:
Before open-sourcing, we want to make sure that (a) GoDoc looks
reasonable, and (b) everything in the API is something we want to commit
to.  In this commit, I do some miscellaneous cleanup on both fronts;
this does involve a few breaking changes to the programmatic API (better
now than once it has users).  In future commits, I'll likely move the
documentation for `genqlient.yaml` and `@genqlient` to clearer places,
and make `GenqlientDirective` private, such that GoDoc is really only
for programmatic users.

Fixes #25.

Issue: #25

## Test plan:
make check


Author: benjaminjkraft

Reviewers: dnerdy, benjaminjkraft, jvoll, aberkan, MiguelCastillo, mahtabsabet

Required Reviewers: 

Approved By: dnerdy, jvoll

Checks: ✅ Test (1.17), ✅ Test (1.16), ✅ Test (1.15), ✅ Test (1.14), ✅ Lint, ✅ Test (1.17), ✅ Test (1.16), ✅ Test (1.15), ✅ Test (1.14), ✅ Lint

Pull Request URL: #82
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 a pull request may close this issue.

1 participant