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

Uint64 is represented as type:"string" in the swagger docs. #735

Closed
trusch opened this issue Aug 22, 2018 · 1 comment
Closed

Uint64 is represented as type:"string" in the swagger docs. #735

trusch opened this issue Aug 22, 2018 · 1 comment

Comments

@trusch
Copy link

trusch commented Aug 22, 2018

Please follow the general troubleshooting steps first:

  • [ x ] Update your protoc to the latest version
  • [ x ] Update your copy of grpc-gateway to the latest version from github. with
    git fetch https://github.com/grpc-ecosystem/grpc-gateway master && git reset --hard FETCH_HEAD
  • [ x ] Delete the protoc-gen-grpc-gateway and protoc-gen-swagger binary from your PATH,
    and install locally built binaries.

Bug reports:

Steps you follow to reproduce the error:

  1. create a message with one uint64 field
  2. create a service using the message
  3. generate swagger doc for it
  4. it lists the type as {type: string, format: uint64}

What did you expect to happen instead:

The swagger doc should list the type as {type: integer, format: int64, min: 0}

What's your theory on why it isn't working:

The well-known-type Uint64 is hardcoded to map to the result we currently see.

@johanbrandhorst
Copy link
Collaborator

This kind of thing has been discussed before at length: #438. Is this a fundamentally different issue? I will pre-emptively close this, but please let me know if I'm wrong.

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

No branches or pull requests

2 participants