-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Breaking on 64bit ids? #178
Comments
See #143 |
Thanks for the reference. In this particular case I would have loved to at least get a warning, if not an error message, so that the caller knows that the processing of that JSON piece was "not safe." |
Well, you should see the recent 1,000+ mail threads in the IETF JSON WG There are implementations that don't handle decimals very well at all (from In general you really must read the docs for any JSON implementations you |
Yes, this is annoying. I don't really want to add 64-bit ints, because that just moves the screwup further away (64bit int overflow still exists). I would quite like to add proper bigint support at some stage, though. I know you don't have control over this data format, but in general IDs should be strings, not numbers. |
Close as dup of #218. |
If one parses a JSON object with a large number represented as int and as string (e.g. Twitter IDs), jq seems to break.
Works fine.
But with 64bit Twitter IDs:
It does not:
(Emphasis added.) A bug?
PS: just in case you arrived here searching for a solution for the specific case of Twitter JSON, just using
id_str
instead ofid
is probably the way to go. Just thought it would be worth mentioning the issue.The text was updated successfully, but these errors were encountered: