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

Document behavior/options for the 32-bit int issue #39

Closed
benjaminjkraft opened this issue Apr 23, 2021 · 0 comments · Fixed by #86
Closed

Document behavior/options for the 32-bit int issue #39

benjaminjkraft opened this issue Apr 23, 2021 · 0 comments · Fixed by #86
Assignees
Labels
documentation Improvements or additions to documentation
Milestone

Comments

@benjaminjkraft
Copy link
Collaborator

benjaminjkraft commented Apr 23, 2021

  • note that GraphQL ints are 32-bit, servers may reject or misbehave:
    • apollo-server explicitly checks ints are 32 bits
    • gqlgen checks (via ParseInt) that ints fit in whatever type your code uses (default int)
    • graphene documents 53 bits but actually requires 32 (unless you use its BigInt type)
  • default behavior is to not check
    • apollo-client doesn't check (although it's JS so it's at most 53 bits)
    • shurcooL effectively makes you pass its graphql.Int type, which is int32
  • instead can set an int32 in scalars, or a custom type that say warns on conversion
@benjaminjkraft benjaminjkraft added the documentation Improvements or additions to documentation label Apr 23, 2021
@benjaminjkraft benjaminjkraft added this to the OSS "launch" milestone Apr 23, 2021
@benjaminjkraft benjaminjkraft self-assigned this Sep 9, 2021
benjaminjkraft added a commit that referenced this issue Sep 9, 2021
This is something that came up at Khan; we decided that just binding to
`int` is actually the right thing, but there are other options.

Fixes #39.
@benjaminjkraft benjaminjkraft linked a pull request Sep 9, 2021 that will close this issue
benjaminjkraft added a commit that referenced this issue Sep 10, 2021
This is something that came up at Khan; we decided that just binding to
`int` is actually the right thing, but there are other options.

Fixes #39.
benjaminjkraft added a commit that referenced this issue Sep 10, 2021
This is something that came up at Khan; we decided that just binding to
`int` is actually the right thing, but there are other options.

Fixes #39.
benjaminjkraft added a commit that referenced this issue Sep 14, 2021
## Summary:
In this commit, I add a bunch more documentation of how to use
genqlient, including a getting started guide, and a FAQ that also acts
as a how-to shaped index of common configuration options and extension
points.  Much of this is adapted from the internal doc I wrote at Khan,
or reorganized from what was in the README.  Speaking of which, now that
there are better places for all the details, I rewrote the README to be
a bit more of an overview and index of other documentation.  (For now I
left the "unmaintained" notes, which I'll remove fairly soon once all
our ducks are in a row.)

Fixes #26, #39.

Issue: #26
Issue: #39

## Test plan:
make check, read the docs


Author: benjaminjkraft

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

Required Reviewers: 

Approved By: mahtabsabet

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: #86
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant