-
Notifications
You must be signed in to change notification settings - Fork 335
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
json 1.8.3: json/pure fails generating Fixnum #269
Comments
atombrenner
changed the title
json 1.8.3: json/pure fails generating integers
json 1.8.3: json/pure fails generating Fixnum
Feb 6, 2016
I looked into generator.rb and couldn't find any kind of type check. So I got back to my code and found out that it required 'aws-sdk' which required 'json'. So to reproduce the issue on irb you need to do this:
|
This was referenced Apr 5, 2016
Sorry for the late feedback. This is fixed in 2.3.0 and can be closed. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The following snippet raises an exception when generating to_json with the pure parser.
The C parser works like expected. If you change 5 to 5.1 it works again. Seems to be a wrong type check inside the pure generator.
Stacktrace:
/var/lib/gems/2.1.0/gems/json-1.8.3/lib/json/pure/generator.rb:366:in
to_json': wrong argument type JSON::Pure::Generator::State (expected JSON/Generator/State) (TypeError)from /var/lib/gems/2.1.0/gems/json-1.8.3/lib/json/pure/generator.rb:366:in
block in json_transform' from /var/lib/gems/2.1.0/gems/json-1.8.3/lib/json/pure/generator.rb:359:in
each'from /var/lib/gems/2.1.0/gems/json-1.8.3/lib/json/pure/generator.rb:359:in
json_transform' from /var/lib/gems/2.1.0/gems/json-1.8.3/lib/json/pure/generator.rb:341:in
to_json'`The text was updated successfully, but these errors were encountered: