oj 3.13.3 → 3.13.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f5350547ea8224c68aefa0d8f1539689ffb24c9addc20b3cbad3537af06b9f45
4
- data.tar.gz: d27f8a3fa9311685f215f1636f7ebaf4ed3b10d03725531f8b42c4d1e64b0985
3
+ metadata.gz: de6407e200d1233d9d36804f49cbd3827d6d318220c44221968dae032e80cc31
4
+ data.tar.gz: 9b0c2f83be6a37ba83677a956e40ba2571128d5ae95efca8e24c56dfcb9fbfc9
5
5
  SHA512:
6
- metadata.gz: e3497f0ac6fb20ae4b0aa252855120f2a3e938bbd703dfcebc1d433ea112924b24e3e352080b3f7c09c5cae99d57dde5f26659031126bcb6855d85761e282b1e
7
- data.tar.gz: c35a5190c600bcd237041cd30cbe227700fc6aed723fb2d54f13013b4af6f79b96b1c5c2dfbcb4dc9c9db30b2894d97c6242a9b0183376da2c2aaa9fb08d4f0a
6
+ metadata.gz: 506be0671f0aecc01447f625e54eaf3a7e70d6a0d148771e94a8968c18224dae2b9e6c06cd0321dc41f1874e0663dae2c20e43b5e3e88a04d2bb23f160d93a27
7
+ data.tar.gz: ab6b025efb11d2c5181a869dfa52755a4c891bc0625a9746a8f3b0189792b5e550829f602eb26c84b125b84657a7a4445f3e2b878a01334c26133a0b910edbab
data/CHANGELOG.md ADDED
@@ -0,0 +1,1266 @@
1
+ # CHANGELOG
2
+
3
+ ## 3.13.4 - 2021-09-04
4
+
5
+ - Fixed concurrent GC issue in the cache.
6
+
7
+ ## 3.13.3 - 2021-08-30
8
+
9
+ - Caches are now self adjusting and clearing so less used entries are
10
+ expunged to avoid memory growth.
11
+
12
+ - When mimicking the JSON gem the JSON::State now handles all Hash
13
+ methods. While this is different than the actually JSON gem it
14
+ avoids failing due to errors in Rails code and other gems.
15
+
16
+ ## 3.13.2 - 2021-08-11
17
+
18
+ - Fixed C99 compiler errors.
19
+
20
+ ## 3.13.1 - 2021-08-09
21
+
22
+ - Fixed failing build on Windows.
23
+
24
+ ## 3.13.0 - 2021-08-08
25
+
26
+ - Added `Oj::Parser`, a faster parser with better option management.
27
+
28
+ - Watson1978 increasd dump performance ever more and is now a collaborator on Oj!
29
+
30
+ ## 3.12.3 - 2021-08-02
31
+
32
+ - Update documents for the `:cache_keys` and `:cache_strings`.
33
+
34
+ - Watson1978 increased dump performance for rails mode.
35
+
36
+ ## 3.12.2 - 2021-07-25
37
+
38
+ - Thanks to Watson1978 for the dump performance for time values.
39
+
40
+ ## 3.12.1 - 2021-07-09
41
+
42
+ - Fixed `:cache_keys` not being honored in compat mode.
43
+ - Increased the cache size.
44
+
45
+ ## 3.12.0 - 2021-07-05
46
+
47
+ - Added string and symbol caching options that give Oj about a 20% parse performance boost.
48
+
49
+ ## 3.11.8 - 2021-07-03
50
+
51
+ - Fixed or reverted change that set the default mode when optimize_Rails was called.
52
+
53
+ ## 3.11.7 - 2021-06-22
54
+
55
+ - Fixed exception type when parsing after `Oj::Rails.mimic_JSON` is called.
56
+
57
+ ## 3.11.6 - 2021-06-14
58
+
59
+ - Fixed bug where `Oj::Doc#fetch` on an empty Hash or Array did not return `nil`.
60
+
61
+ - Added an `Oj::Doc#exists?` method.
62
+
63
+ - Deprecated `Oj::Doc#where?` in favor `Oj::Doc#where` or the alias, `Oj::Doc#path`.
64
+
65
+ ## 3.11.5 - 2021-04-15
66
+
67
+ - Oj.generate fix introduced in previous bug fix. Oj.mimic_JSON is forced if Oj.generate is called.
68
+
69
+ ## 3.11.4 - 2021-04-14
70
+
71
+ - Code re-formatted with clang-format. Thanks goes to BuonOmo for
72
+ suggesting and encouraging the use of a formatter and getting the
73
+ effort started.
74
+
75
+ - Added support for `GC.compact` on `Oj::Doc`
76
+
77
+ - Fixed compatibility issue with Rails and the JSON gem that requires
78
+ a special case when using JSON.generate versus call `to_json` on an
79
+ object.
80
+
81
+ ## 3.11.3 - 2021-03-09
82
+
83
+ - Fixed `respond_to?` method on `Oj::EasyHash`.
84
+
85
+ ## 3.11.2 - 2021-01-27
86
+
87
+ - Fixed JSON gem `:decimal_class` option.
88
+
89
+ ## 3.11.1 - 2021-01-24
90
+
91
+ - XrXr fixed Ruby 3.0.0 object movement issue.
92
+
93
+ ## 3.11.0 - 2021-01-12
94
+
95
+ - Added `:compat_bigdecimal` to support the JSON gem `:decimal_class` undocumented option.
96
+
97
+ - Reverted the use of `:bigdecimal_load` for `:compat` mode.
98
+
99
+ ## 3.10.18 - 2020-12-25
100
+
101
+ - Fix modes table by marking compat mode `:bigdecimal_load` instead of `:bigdecimal_as_decimal`.
102
+
103
+ - Added `:custom` mode setting that are the same as `:compat` mode. There are some minor differences between the two setting.
104
+
105
+ ## 3.10.17 - 2020-12-15
106
+
107
+ - The undocumented JSON gem option of `:decimal_class` is now
108
+ supported and the default option of `:bigdecimal_load` is also
109
+ honored in JSON.parse() and in compat mode.
110
+
111
+ - Invalid encoding detection bug fixed for rails.
112
+
113
+ ## 3.10.16 - 2020-11-10
114
+
115
+ - Allow escaping any character in :compat mode to match the json gem behavior.
116
+
117
+ ## 3.10.15 - 2020-10-16
118
+
119
+ Remove license from code.
120
+
121
+ ## 3.10.14 - 2020-09-05
122
+
123
+ - Updated float test to check a range.
124
+
125
+ ## 3.10.13 - 2020-08-28
126
+
127
+ - Removed explicit dependency on bigdecimal.
128
+
129
+ ## 3.10.12 - 2020-08-20
130
+
131
+ - Another try at bracketing bigdecimal versions to 1.0 and 3.
132
+
133
+ ## 3.10.11 - 2020-08-20
134
+
135
+ - Bracketed bigdecimal dependency to 1.0 and 3.
136
+
137
+ ## 3.10.10 - 2020-08-20
138
+
139
+ - Backed off bigdecimal dependency to 1.0.
140
+
141
+ ## 3.10.9 - 2020-08-17
142
+
143
+ - Add bigdecimal dependency to gemfile.
144
+
145
+ ## 3.10.8 - 2020-07-24
146
+
147
+ - New fast option for float parsing.
148
+
149
+ - Fixes a float parse error.
150
+
151
+ ## 3.10.7 - 2020-07-13
152
+
153
+ - Faster float parsing and an adjust to more closely match Ruby.
154
+
155
+ ## 3.10.6 - 2020-04-04
156
+
157
+ - Correct object dump code to continue instead of return on an _ attribnute.
158
+
159
+ ## 3.10.5 - 2020-03-03
160
+
161
+ - Fix test
162
+
163
+ ## 3.10.4 - 2020-03-03
164
+
165
+ - Another adjustment to get Ruby floats to match Oj thanks to klaxit.
166
+
167
+ ## 3.10.3 - 2020-03-01
168
+
169
+ - Fixed difference between some unicode character encoding in Rails mode.
170
+
171
+ ## 3.10.2 - 2020-01-30
172
+
173
+ - Fixed circular array reference load.
174
+
175
+ ## 3.10.1 - 2020-01-14
176
+
177
+ - Fixed bug where setting `ActiveSupport::JSON::Encoding.use_standard_json_time_format` before calling `Oj.optimize_rails` did not have an effect on the time format.
178
+
179
+ - Worked around the Active Support hack that branched in `to_json` depending on the class of the option argument.
180
+
181
+ - Updated for Ruby 2.7.0
182
+
183
+ ## 3.10.0 - 2019-11-28
184
+
185
+ - Fixed custom mode load_file to use custom mode.
186
+
187
+ - Fixed rails mode output of IO objects
188
+
189
+ - Fixed issue #567. Second precision is forced if set to the correct number of decimals even if zero nanoseconds.
190
+
191
+ - Fixed issue #568. Dumping bigdecimal in `:rails' mode made more consistent.
192
+
193
+ - Fixed issue #569. `:compat` mode not restricts the escape mode as indicated in the documentation.
194
+
195
+ - Fixed issue #570. In `:strict` mode number parsing follows the JSON specification more closely as intended.
196
+
197
+ - Added `:ignore_under` which when true will ignore attributes that begin with a `_` when dumping in `:object` or `:custom` mode.
198
+
199
+ ## 3.9.2 - 2019-10-01
200
+
201
+ - Fixed wrong exception type when mimicking the JSON gem.
202
+
203
+ ## 3.9.1 - 2019-08-31
204
+
205
+ - Raise an exception on an invalid time represented as a decimal in `:object` mode.
206
+
207
+ ## 3.9.0 - 2019-08-18
208
+
209
+ - Changed custom behavior when `:create_additions` is true and `:create_id` is
210
+ set to nil. Now Range, Regexp, Rational, and Complex are output as strings
211
+ instead of a JSON object with members. Setting any other value for
212
+ `:create_id`, even an empty string will result in an object being dumped.
213
+
214
+ - Detection of pthread mutex support was changed.
215
+
216
+ ## 3.8.1 - 2019-07-22
217
+
218
+ - Fix replacement of JSON::Parse thanks to paracycle.
219
+
220
+ ## 3.8.0 - 2019-07-17
221
+
222
+ - Fixed a buffer allocation bug for `JSON.pretty_generate`.
223
+
224
+ - Added mimic `safe` option to not include the complete JSON in a parse error message.
225
+
226
+ - Added `use_raw_json` option for `:compat` and `:rails` mode to allow better
227
+ performance on dump. StringWriter in particular has been optimized for this option.
228
+
229
+ ## 3.7.12 - 2019-04-14
230
+
231
+ - The `:omit_nil` option did not work in `:rails` mode. That has been fixed.
232
+
233
+ ## 3.7.11 - 2019-03-19
234
+
235
+ - Fix to Rails optimize that missed initializing the mimic JSON `:symbolize_names` value.
236
+
237
+ ## 3.7.10 - 2019-03-14
238
+
239
+ - Corrected time dump so that the none-leap years after a 400 year period are correct.
240
+
241
+ ## 3.7.9 - 2019-02-18
242
+
243
+ - Return correct value in `create_opt` C function.
244
+
245
+ - Return `Oj::ParseError` if an invalid big decimal string is encountered instead of an argument error
246
+
247
+ ## 3.7.8 - 2019-01-21
248
+
249
+ - Replace `gmtime` with a custom function.
250
+
251
+ - Oj::Doc crash fix.
252
+
253
+ - Mark odd args to avoid GC.
254
+
255
+ ## 3.7.7 - 2019-01-14
256
+
257
+ - Exception with other than a single argument initializer can now be decoded.
258
+
259
+ - StreamWriter bug fixed that forces UTF-8 when appending to a stream. Ruby likes to convert to ASCII-8BIT but forcing the append to be UTF-8 avoids that issue.
260
+
261
+ ## 3.7.6 - 2018-12-30
262
+
263
+ - Changed time encoding for 32 bit to work around a Ruby bug in `rb_time_timespec()` that fails for times before 1970.
264
+
265
+ - Addressed issue #514 by changing reserved identifiers.
266
+
267
+ - Addressed issue #515 by adding return value checks on `strdup()` and `pthread_mutex_init()`.
268
+
269
+ ## 3.7.5 - 2018-12-27
270
+
271
+ - Address issue #517 with a special escape table for mimicking the JSON gem.
272
+
273
+ ## 3.7.4 - 2018-11-29
274
+
275
+ - Allow `+` in front of numbers in parse as well as stream parse **EXCEPT** when mimicking the JSON gem.
276
+
277
+ ## 3.7.3 - 2018-11-29
278
+
279
+ - Allow `+` in front of numbers in parse as well as stream parse.
280
+
281
+ ## 3.7.2 - 2018-11-29
282
+
283
+ - More tolerant float parsing to allow `123.`.
284
+
285
+ - Parse exceptions raised by user code now preserve the message content of the exception.
286
+
287
+ ## 3.7.1 - 2018-11-09
288
+
289
+ - Updated to support TruffleRuby.
290
+
291
+ ## 3.7.0 - 2018-10-29
292
+
293
+ - Thanks to Ziaw for adding a integer range where integers outside that range are written as strings.
294
+
295
+ ## 3.6.13 - 2018-10-25
296
+
297
+ - Fixed issue where exceptions were not being cleared on parsing.
298
+
299
+ - Added addition unicode dump error information.
300
+
301
+ ## 3.6.12 - 2018-10-16
302
+
303
+ - Fixed random `:omit_nil` setting with StringWriter and StreamWriter.
304
+
305
+ ## 3.6.11 - 2018-09-26
306
+
307
+ - Added the JSON path to parse error messages.
308
+
309
+ - BigDecimal parse errors now return Oj::ParseError instead of ArgumentError.
310
+
311
+ ## 3.6.10 - 2018-09-13
312
+
313
+ - Additional occurrences of `SYM2ID(sym)` replaced.
314
+
315
+ ## 3.6.9 - 2018-09-12
316
+
317
+ - `SYM2ID(sym)` causes a memory leak. A work around is now used.
318
+
319
+ ## 3.6.8 - 2018-09-08
320
+
321
+ - Stopped setting the default options when optimize rails is called as the documentation has indicated.
322
+
323
+ - In custom mode `Date` and `DateTime` instances default to use the `:time_format` option is the `:create_additions` option is false.
324
+
325
+ ## 3.6.7 - 2018-08-26
326
+
327
+ - Fixed incorrect check in StreamWriter when adding raw JSON.
328
+
329
+ ## 3.6.6 - 2018-08-16
330
+
331
+ - Fixed Debian build issues on several platforms.
332
+
333
+ - `oj_slash_string` is now frozen.
334
+
335
+ ## 3.6.5 - 2018-07-26
336
+
337
+ - Fixed GC issue with Oj::Doc.
338
+
339
+ - Fixed issue with time encoding with Windows.
340
+
341
+ ## 3.6.4 - 2018-07-10
342
+
343
+ - JSON.generate() now sets the `to_json` option as expected.
344
+
345
+ - Show `:create_additions` in the default options. It did not appear before.
346
+
347
+ ## 3.6.3 - 2018-06-21
348
+
349
+ - Fixed compat dump compilation error on Windows.
350
+
351
+ ## 3.6.2 - 2018-05-30
352
+
353
+ - Regex encoded correctly for rails when using `to_json`.
354
+
355
+ - ActiveSupport::TimeWithZone optimization fixed.
356
+
357
+ ## 3.6.1 - 2018-05-16
358
+
359
+ - Fixed realloc bug in rails dump.
360
+
361
+ ## 3.6.0 - 2018-05-01
362
+
363
+ - Add optimization for Rails ActiveRecord::Result encoding.
364
+
365
+ ## 3.5.1 - 2018-04-14
366
+
367
+ - Fixed issue with \u0000 terminating keys early.
368
+
369
+ - Add trace for calls to `to_json` and 'as_json`.
370
+
371
+ ## 3.5.0 - 2018-03-04
372
+
373
+ - A trace option is now available in all modes. The format roughly follows the Ruby trace format.
374
+
375
+ ## 3.4.0 - 2018-01-24
376
+
377
+ - Option to ignore specific classes in :object and :custom mode added.
378
+
379
+ ## 3.3.10 - 2017-12-30
380
+
381
+ - Re-activated the bigdecimal_as_decimal option in custom mode and made the selection active for Rails mode.
382
+
383
+ - Fixed bug in optimize_rails that did not optimize all classes as expected.
384
+
385
+ - Fixed warnings for Ruby 2.5.0.
386
+
387
+ ## 3.3.9 - 2017-10-27
388
+
389
+ - Fixed bug where empty strings were sometimes marked as invalid.
390
+
391
+ ## 3.3.8 - 2017-10-04
392
+
393
+ - Fixed Rail mimic precision bug.
394
+
395
+ ## 3.3.7 - 2017-10-02
396
+
397
+ - Handle invalid unicode characters better for single byte strings.
398
+
399
+ - Parsers for empty strings handle errors more consistently.
400
+
401
+ ## 3.3.6 - 2017-09-22
402
+
403
+ - Numerous fixes and cleanup to support Ruby 2.4.2.
404
+
405
+ ## 3.3.5 - 2017-08-11
406
+
407
+ - Fixed a memory error when using rails string encoding of certain unicode characters.
408
+
409
+ ## 3.3.4 - 2017-08-03
410
+
411
+ - Oj::Rails.mimic_JSON now uses Float for JSON.parse for large decimals instead of BigDecimal.
412
+
413
+ ## 3.3.3 - 2017-08-01
414
+
415
+ - Allow nil as a second argument to parse when mimicking the json gem. This is
416
+ a special case where the gem does not raise an exception on a non-Hash
417
+ second argument.
418
+
419
+ ## 3.3.2 - 2017-07-11
420
+
421
+ - Fixed Windows compile issue regarding timegm().
422
+
423
+ ## 3.3.1 - 2017-07-06
424
+
425
+ - Some exceptions such as NoMethodError have an invisible attribute where the
426
+ key name is NULL. Not an empty string but NULL. That is now detected and
427
+ dealt with.
428
+
429
+ ## 3.3.0 - 2017-07-05
430
+
431
+ - Added the :wab mode to support the [WABuR](https://github.com/ohler55/wabur)
432
+ project. The :wab mode only allows the indent option and is faster due to
433
+ not having to check the multitude of options the other modes support.
434
+
435
+ ## 3.2.1 - 2017-07-04
436
+
437
+ - Made json gem NaN dumping more consistent.
438
+
439
+ - Fixed :null mode to not revert to strict mode.
440
+
441
+ ## 3.2.0 - 2017-06-20
442
+
443
+ - A buffer_size option was added to StringWriter and StreamWriter. That option
444
+ also sets the suggested flush limit for StreamWriter.
445
+
446
+ ## 3.1.4 - 2017-06-16
447
+
448
+ - :symbolize_names now works with Oj::Rails.mimic_JSON.
449
+
450
+ ## 3.1.3 - 2017-06-13
451
+
452
+ - JSON.dump used the default mode instead of :compat mode. That has been fixed.
453
+
454
+ - Updated docs on Oj.mimic_JSON to note the :encoding is set to :unicode_xss and not :ascii.
455
+
456
+ ## 3.1.2 - 2017-06-10
457
+
458
+ - StringWriter was passing incorrect arguments to to_json and as_json. Fixed.
459
+
460
+ - StringWriter now accepts the mode option. This means it also defaults to the
461
+ default_options mode instead of the custom mode.
462
+
463
+ - JSON.pretty_generate when in rails mode now loads the JSON::State class correctly.
464
+
465
+ ## 3.1.1 - 2017-06-09
466
+
467
+ - Custom mode now honors the :create_additions option for time.
468
+
469
+ ## 3.1.0 - 2017-06-04
470
+
471
+ - Added Oj::Rails.mimic_JSON which mimics the json gem when used with
472
+ ActiveSupport which monkey patches the same to_json methods does. Basically
473
+ this changes the JSON.parse and other JSON entry points for encoding and
474
+ decoding.
475
+
476
+ - Oj.optimize_rails now calls Oj::Rails.mimic_JSON.
477
+
478
+ ## 3.0.11 - 2017-06-02
479
+
480
+ - If rails in required and Oj.mimic_JSON is called without calling
481
+ Oj.optimize_rails nil.to_json failed. That has been fixed.
482
+
483
+ - Fixed crash on setting create_id to nil after mimic_JSON.
484
+
485
+ ## 3.0.10 - 2017-05-22
486
+
487
+ - Oj.optimize_rails failed to include Hash and Array in the optimization. It does now.
488
+
489
+ ## 3.0.9 - 2017-05-17
490
+
491
+ - Missed catching invalid unicodes beginning with \xE2. Fixed.
492
+
493
+ - In :compat mode a non-string and non IO value is converted to a string with a call to to_s.
494
+
495
+ ## 3.0.8 - 2017-05-16
496
+
497
+ - Float significant digits now match Ruby's unless optimized and then significant digits are set to 16.
498
+
499
+ - Rails Hash post merging of identical keys after calling as_json is preserved only for un-optimized Hashes.
500
+
501
+ - Raise an exception to match json gem behavior on invalid unicode.
502
+
503
+ ## 3.0.7 - 2017-05-10
504
+
505
+ - Changed JSON.pretty_generate options to a State instead of a Hash to get the
506
+ json gen to_json method to accept formatting options.
507
+
508
+ - Added optimization for ActionController::Parameters
509
+
510
+ ## 3.0.6 - 2017-05-07
511
+
512
+ - Added Oj.optimize_rails().
513
+
514
+ - Fixed argument passing bug on calls to to_json().
515
+
516
+ ## 3.0.5 - 2017-05-02
517
+
518
+ - No change in the Oj::Rails.optimize() API but additional classes are now supported.
519
+
520
+ - Added ActiveSupport::TimeWithZone optimization to rails mode.
521
+
522
+ - Added ActiveRecord::Base optimization to rails mode which allows optimization of any class inheriting from ActiveRecord::Base.
523
+
524
+ ## 3.0.4 - 2017-05-01
525
+
526
+ - Fixed compile problem on Windows again.
527
+
528
+ - Fixed issue with TimeWithZone not being encoded correctly when a member of an object.
529
+
530
+ ## 3.0.3 - 2017-04-28
531
+
532
+ - Improved compatibility with a json gem and Rails combination when json adds are used.
533
+
534
+ - Fixed compile problem on Windows.
535
+
536
+ ## 3.0.2 - 2017-04-27
537
+
538
+ - Fixed crash due to unset var with dump to Rails mode.
539
+
540
+ ## 3.0.1 - 2017-04-25
541
+
542
+ - Fixed compile error with help from Dylan Johnson.
543
+
544
+ ## 3.0.0 - 2017-04-24
545
+
546
+ - Major changes focused on json gem and Rails compatibility. A new :custom
547
+ mode was added as well. Starting with this release the json gem tests are
548
+ being used to test the :compat mode and the ActiveSupport 5 tests are being
549
+ used to test the :rails mode.
550
+
551
+ - Please give stereobooster a thank you for getting the tests set up and
552
+ helping out with json gem and Rails understanding. He also has some
553
+ benchmarks of Oj versus other options
554
+ [here](https://github.com/stereobooster/ruby-json-benchmark).
555
+
556
+ ## 2.18.3 - 2017-03-14
557
+
558
+ - Changed to use long doubles for parsing to minimize round off errors. So PI will be accurate to more places for PI day.
559
+
560
+ ## 2.18.2 - 2017-03-01
561
+
562
+ - Strict mode now allows symbol keys in hashes.
563
+
564
+ - Fixed omit_nil bug discovered by ysmazda.
565
+
566
+ ## 2.18.1 - 2017-01-09
567
+
568
+ - Missing argument to dump now raises the correct arg exception and with mimic does not crash on missing argument.
569
+ - Oj::Doc paths can now contain escaped path separators so "a\/b" can match an lement name with a slash in it.
570
+
571
+ ## 2.18.0 - 2016-11-26
572
+
573
+ - Rubinius compilation fixes.
574
+ - Added a separate option for as_json instead of piggy backing on the use_to_json. This changes the API slightly.
575
+ - Ready for Ruby 2.4.
576
+ - Thanks to faucct for fixing mimic to not redefine JSON::ParserError.
577
+
578
+ ## 2.17.5 - 2016-10-19
579
+
580
+ - Added additional code to check for as_json arguments and recursive calls.
581
+
582
+ ## 2.17.4 - 2016-09-04
583
+
584
+ - Added the ascii_only option to JSON.generate when in mimic_JSON mode so that it is consistent with the undocumented feature in the json gem.
585
+
586
+ ## 2.17.3 - 2016-08-16
587
+
588
+ - Updated mimic_JSON to monkey patch OpenStruct, Range, Rational, Regexp, Struct, Symbol, and Time like the JSON gem does. Also added the JSON.create_id accessor.
589
+
590
+ ## 2.17.2 - 2016-08-13
591
+
592
+ - Worked around a problem with DateTime and ActiveSupport that causes a hang when hour, minute, second, and some other methods are called from C.
593
+
594
+ ## 2.17.1 - 2016-07-08
595
+
596
+ - Added an option provide an alternative Hash class for loading.
597
+ - Added the Oj::EasyHash class.
598
+ - Fixed test failures on 32 bit machines.
599
+ - Sped up mimic_JSON.
600
+ - Added an option to omit Hash and Object attributes with nil values.
601
+
602
+ ## 2.16.1 - 2016-06-21
603
+
604
+ - Thanks to hsbt for fixing a compile issue with Ruby 2.4.0-preview1.
605
+
606
+ ## 2.16.0 - 2016-06-19
607
+
608
+ - Added option to allow invalid unicode characters. This is not a suggested option in a majority of the cases.
609
+ - Fixed float parsing for 32 bit systems so that it does not roll over to BigDecimal until more than 15 significant digits.
610
+
611
+ ## 2.15.1 - 2016-05-26
612
+
613
+ - Fixed bug with activerecord when to_json returns an array instead of a string.
614
+
615
+ ## 2.15.0 - 2016-03-28
616
+
617
+ - Fixed bug where encoded strings could be GCed.
618
+ - :nan option added for dumping Infinity, -Infinity, and NaN. This is an edition to the API. The default value for the :non option is :auto which uses the previous NaN handling on dumping of non-object modes.
619
+
620
+ ## 2.14.7 - 2016-03-20
621
+
622
+ - Fixed bug where a comment before another JSON element caused an error. Comments are not part of the spec but this keep support consistent.
623
+
624
+ ## 2.14.6 - 2016-02-26
625
+
626
+ - Changed JSON::ParserError to inherit from JSON::JSONError which inherits from StandardError.
627
+
628
+ ## 2.14.5 - 2016-02-19
629
+
630
+ - Parse errors in mimic mode are not a separate class than Oj.ParseError so the displayed name is JSON::ParserError instead.
631
+
632
+ ## 2.14.4 - 2016-02-04
633
+
634
+ - When not in quirks mode strings are now raise an exception if they are the top level JSON value.
635
+
636
+ ## 2.14.3 - 2015-12-31
637
+
638
+ - Updated to support Ruby 2.3.0.
639
+
640
+ ## 2.14.2 - 2015-12-19
641
+
642
+ - Non-UTF-8 string input is now converted to UTF-8.
643
+
644
+ ## 2.14.1 - 2015-12-15
645
+
646
+ - Fixed bug that reverted to BigDecimal when a decimal had preceding zeros after the decimal point.
647
+
648
+ ## 2.14.0 - 2015-12-04
649
+
650
+ - More tweaking on decimal rounding.
651
+ - Made dump options available in the default options and not only in the mimic generate calls.
652
+
653
+ ## 2.13.1 - 2015-11-16
654
+
655
+ - Thanks to Comboy for the fix to a large number rounding bug.
656
+
657
+ ## 2.13.0 - 2015-10-19
658
+
659
+ - Oj no longer raises an exception if the to_hash method of an object does not return a Hash. ActiveRecord has decided that to_hash should return an Array instead so Oj now encodes what ever is returned.
660
+ - Added a register_odd_raw function that allows odd marshal functions to return raw JSON as a string to be included in the dumped JSON.
661
+ - The register_odd function now supports modules in additions to classes.
662
+
663
+ ## 2.12.14 - 2015-09-14
664
+
665
+ - Change the failure mode for objects that can not be serialized such as a socket. Now in compat mode the to_s of the object is placed in the output instead of raising an exception.
666
+
667
+ ## 2.12.13 - 2015-09-02
668
+
669
+ - Added a check for the second argument to load() is a Hash.
670
+ - Yet another attempt to make floating point numbers display better.
671
+ - Thanks to mkillianey for getting the extconf.rb and gemspec file updated.
672
+
673
+ ## 2.12.12 - 2015-08-09
674
+
675
+ - Thanks to asurin for adding support for arguments to to_json() that rails uses.
676
+
677
+ ## 2.12.11 - 2015-08-02
678
+
679
+ - Oj::ParseError is now thrown instead of SyntaxError when there are multiple JSON documents in a string or file and there is no proc or block associated with the parse call.
680
+
681
+ ## 2.12.10 - 2015-07-12
682
+
683
+ - An exception is now raised if there are multiple JSON documents in a string or file if there is no proc or block associated with the parse call.
684
+
685
+ ## 2.12.9 - 2015-05-30
686
+
687
+ - Fixed failing test when using Rubinius.
688
+ - Changed mimic_JSON to support the global/kernel function JSON even when the json gem is loaded first.
689
+
690
+ ## 2.12.8 - 2015-05-16
691
+
692
+ - mimic_JSON now supports the global/kernel JSON function that will either parse a string argument or dump an array or object argument.
693
+
694
+ ## 2.12.7 - 2015-05-07
695
+
696
+ - Fixed compile error with 32 bit HAS_NANO_TIME extra paren bug.
697
+
698
+ ## 2.12.6 - 2015-05-05
699
+
700
+ - Fixed a number of 32bit related bugs.
701
+
702
+ ## 2.12.5 - 2015-04-27
703
+
704
+ - In :null mode Oj now dumps Infinity and NaN as null.
705
+
706
+ ## 2.12.4 - 2015-04-20
707
+
708
+ - Fixed memory leak in Oj::Doc when not using a given proc.
709
+
710
+ ## 2.12.3 - 2015-04-16
711
+
712
+ - Fixed bug when trying to resolve an invalid class path in object mode load.
713
+
714
+ ## 2.12.2 - 2015-04-13
715
+
716
+ - Fixed Oj::Doc bug that causes a crash on local name lookups.
717
+ - Fixed Oj::Doc unicode parsing.
718
+
719
+ ## 2.12.1 - 2015-03-12
720
+
721
+ - Changed the unix_zone encoded format to be the utc epoch.
722
+
723
+ ## 2.12.0 - 2015-03-06
724
+
725
+ - String formats for UTC time are now explicitly UTC instead of offset of zero. This fixes a problem with pre-2.2.0 Rubies that automatically convert zero offset times to local times.
726
+ - Added :unix_zone time_format option for formatting numeric time. This option is the same as the :unix time option but the UTC offset is included as an exponent to the number time value. A value of 86400 is an indication of UTC time.
727
+
728
+ ## 2.11.5 - 2015-02-25
729
+
730
+ - Fixed issue with rails as_json not being called for Structs.
731
+ - Added support for anonymous Structs with object mode encoding. Note that this will result in a new anonymous Struct for each instance.
732
+
733
+ ## 2.11.4 - 2015-01-20
734
+
735
+ - DateTime second encoding is now always a Rational to preserve accuracy.
736
+ - Fixed buf in the Oj.load() callback feature that caused an endless loop when a StringIO was used with a JSON that was a number.
737
+
738
+ ## 2.11.3 - 2015-01-18
739
+
740
+ - DateTime encoding now includes nanoseconds.
741
+
742
+ ## 2.11.2 - 2015-01-10
743
+
744
+ - Changed the defaults for mimic_JSON to use 16 significant digits instead of the default 15.
745
+ - Fixed bug where a subclass of Array would be serialized as if in object mode instead of compat when in compat mode.
746
+
747
+ ## 2.11.1 - 2014-11-09
748
+
749
+ - Changed the use_to_json option to still allow as_json even when set to false.
750
+
751
+ ## 2.11.0 - 2014-11-02
752
+
753
+ - Restricted strict dump to not dump NaN nor Infinity but instead raise an exception.
754
+ - Changed compat mode so that the :bigdecimal_as_decimal option over-rides the to_json method if the option is true. The default for mimic_JSON is to leave the option off.
755
+ - Added support for Module encoding in compat mode.
756
+ - Added ActiveSupportHelper so that require 'active_support_helper' will added a helper for serializing ActiveSupport::TimeWithZone.
757
+ - Added float_precision option to control the number of digits used for floats when dumping.
758
+
759
+ ## 2.10.4 - 2014-10-22
760
+
761
+ - Fixed Range encoding in compat mode to not use the object mode encoding.
762
+ - Fixed serialization problem with timestamps.
763
+ - Fixed compat parser to accept NaN and Infinity.
764
+
765
+ ## 2.10.3 - 2014-10-04
766
+
767
+ - Using the xmlschema option with :object mode now saves time as a string and preserves the timezone.
768
+ - Rational recursive loop caused by active support fixed.
769
+ - Time in mimic_JSON mode are now the ruby string representation of a date.
770
+
771
+ ## 2.10.2 - 2014-08-20
772
+
773
+ - Fixed string corruption bug due to an uncommented assignment used for debugging.
774
+
775
+ ## 2.10.1 - 2014-08-17
776
+
777
+ - Changed parse argument error to be a Ruby ArgError instead of a general Exception.
778
+
779
+ ## 2.10.0 - 2014-08-03
780
+
781
+ - Using an indent of less than zero will not place newline characters between JSON elements when using the string or stream writer.
782
+ - A new options callback method was added to the Simple Callback Parser. If defined the prepare_key() method will be called when an JSON object ket is first encountered. The return value is then used as the key in the key-value pair.
783
+ - Increased significants digits to 16 from 15. On occasion there may be unexpected round off results. Tou avoid those use the bigdecimal options.
784
+
785
+ ## 2.9.9 - 2014-07-07
786
+
787
+ - Missed a character map entry. / in ascii mode is now output as / and not \/
788
+ - Fixed SC parser to not treat all IO that respond to fileno as a file. It not checks stat and asks if it is a file.
789
+ - Tightened object parsing of non-string hash keys so that just "^#x" is parsed as a hash pair and not "~#x".
790
+ - Using echo to STDIN as an IO input works around the exception raised when asking the IO for it's position (IO.pos).
791
+ - Simple Callback Parser now uses the new stream parser for handling files and IO so that larger files are handled more efficiently and streams are read as data arrives instead of on close.
792
+ - Handles file FIFO pipes correctly now.
793
+
794
+ ## 2.9.8 - 2014-06-25
795
+
796
+ - Changed escaping back to previous release and added a new escape mode.
797
+ - Strict mode and compat mode no longer parse Infinity or NaN as a valid number. Both are valid in object mode still.
798
+
799
+ ## 2.9.7 - 2014-06-24
800
+
801
+ - Changed dump to use raw / and raw \n in output instead of escaping.
802
+ - Changed the writer to always put a new line at the end of a top level JSON object. It makes output easier to view and edit with minimal impact on size.
803
+ - Worked around the file.gets look ahead caching as long as it is not called while parsing (of course).
804
+ - Thanks to lautis for a new parse option. quirks_mode allows Oj to behave quirky like the JSON gem. Actually the JSON gem has it backwards with quirky mode supporting the JSON spec and non-quirky limiting parsing to objects and arrays. Oj stays consistent with the JSON gem to avoid confusion.
805
+ - Fixed problem with sc_parse not terminating the string when loaded from a file.
806
+ - Thanks go to dchelimsky for expanding the code sample for the ScHandler.
807
+
808
+ ## 2.9.6 - 2014-06-15
809
+
810
+ - Fixed bug using StringIO with SCParser.
811
+ - Tightened up JSON mimic to raise an exception if JSON.parse is called on a JSON documents that returns a primitive type.
812
+
813
+ ## 2.9.5 - 2014-06-07
814
+
815
+ - Mimic mode now monkey patches Object like JSON.
816
+ - A big thanks to krasnoukhov for reorganizing test and helping get Oj more rails compatible.
817
+ - Another thanks goes out to lautis for a pull request that provided some optimization and fixed the return exception for an embedded null in a string.
818
+ - Fixed a bug with zip reader streams where EOF was not handled nicely.
819
+
820
+ ## 2.9.4 - 2014-05-28
821
+
822
+ - In mimic mode parse errors now match the JSON::ParserError.
823
+
824
+ ## 2.9.3 - 2014-05-15
825
+
826
+ - Fixed IO read error that showed up in IO objects that return nil instead of raising an EOF error when read is done.
827
+
828
+ ## 2.9.2 - 2014-05-14
829
+
830
+ - Fixed link error with Windows.
831
+
832
+ ## 2.9.1 - 2014-05-14
833
+
834
+ - Fixed mimic load when given a block to evalate. It conflicted with the new load option.
835
+ - Added a true stream that is used when the input argument to load is an IO object such as a stream or file. This is slightly slower for smaller files but allows reading of huge files that will not fit in memory and is more efficient on even larger files that would fit into memory. The load_file() method uses the new stream parser so multiple GB files can be processed without used execessive memory.
836
+
837
+ ## 2.9.0 - 2014-05-01
838
+
839
+ - Added support for detection and handling of String, Array, and Hash subclasses.
840
+ - Oj.load() can now take a block which will be yielded to on every object parsed when used with a file or string with multiple JSON entries.
841
+
842
+ ## 2.8.1 - 2014-04-21
843
+
844
+ - Added additional argument to the register_odd function.
845
+ - Fixed bug that failed to load on some uses of STDIN.
846
+
847
+ ## 2.8.0 - 2014-04-20
848
+
849
+ - Added support for registering special encoding and decoding rules for specific classes. This the ActiveSupport subclass of the String class for safe strings. For an example look at the `test_object.rb` file, `test_odd_string` test.
850
+
851
+ ## 2.7.3 - 2014-04-11
852
+
853
+ - Fixed bug where load and dump of Structs in modules did not work correctly.
854
+
855
+ ## 2.7.2 - 2014-04-06
856
+
857
+ - Added option return nil if nil is provided as input to load.
858
+
859
+ ## 2.7.1 - 2014-03-30
860
+
861
+ - Fixed bug in new push_key which caused duplicate characters.
862
+
863
+ ## 2.7.0 - 2014-03-29
864
+
865
+ - Added the push_key() method to the StringWriter and StreamWriter classes.
866
+
867
+ ## 2.6.1 - 2014-03-21
868
+
869
+ - Set a limit on the maximum nesting depth to 1000. An exception is raised instead of a segfault unless a reduced stack is used which could trigger the segfault due to an out of memory condition.
870
+
871
+ ## 2.6.0 - 2014-03-11
872
+
873
+ - Added the :use_to_json option for Oj.dump(). If this option is set to false the to_json() method on objects will not be called when dumping. This is the default behavior. The reason behind the option and change is to better support Rails and ActiveSupport. Previous works arounds have been removed.
874
+
875
+ ## 2.5.5 - 2014-02-18
876
+
877
+ - Worked around the Rubinius failure to load bigdecimal from a require within the C code.
878
+
879
+ ## 2.5.4 - 2014-01-14
880
+
881
+ - Fixed bug where unterminated JSON did not raise an exception.
882
+
883
+ ## 2.5.3 - 2014-01-03
884
+
885
+ - Added support for blocks with StringWriter.
886
+
887
+ ## 2.5.2 - 2014-01-02
888
+
889
+ - Fixed indent problem with StringWriter so it now indents properly.
890
+
891
+ ## 2.5.1 - 2013-12-18
892
+
893
+ - Added push_json() to the StringWriter and StreamWriter to allow raw JSON to be added to a JSON document being constructed.
894
+
895
+ ## 2.4.3 - 2013-12-16
896
+
897
+ - Made include pthread.h conditional for Windows.
898
+
899
+ ## 2.4.2 - 2013-12-14
900
+
901
+ - Thanks to Patrik Rak for a fix to a buffer short copy when dumping with 0 indent.
902
+
903
+ ## 2.4.1 - 2013-12-10
904
+
905
+ - Fixed Windows version by removing class cache test.
906
+
907
+ ## 2.4.0 - 2013-12-08
908
+
909
+ - Merged in a PR to again allow strings with embedded nulls.
910
+ - Implemented StreamWriter to compliment the StringWriter.
911
+ - Fixed bug in the class cache hash function that showed up with the sparc compiler.
912
+
913
+ ## 2.3.0 - 2013-12-01
914
+
915
+ - JRuby is no longer supported.
916
+ - Thanks to Stefan Kaes the support for structs has been optimized.
917
+ - Better support for Rubinous.
918
+ - Added option to disable GG during parsing.
919
+ - Added StringWriter that allows building a JSON document one element at a time.
920
+
921
+ ## 2.2.3 - 2013-11-19
922
+
923
+ - Fixed struct segfault on load.
924
+ - Added option to force float on load if a decimal number.
925
+
926
+ ## 2.2.2 - 2013-11-17
927
+
928
+ - Added mutex support for Windows.
929
+ - Protected SCP parser for GC.
930
+
931
+ ## 2.2.1 - 2013-11-15
932
+
933
+ - Made all VALUEs in parse volatile to avoid garbage collection while in use.
934
+
935
+ ## 2.2.0 - 2013-11-11
936
+
937
+ - All 1.8.x versions of Ruby now have require 'rational' called.
938
+ - Removed the temporary GC disable and implemented mark strategy instead.
939
+ - Added new character encoding mode to support the Rails 4 escape characters of &, as xss_safe mode. The :encoding option replaces the :ascii_only option.
940
+ - Change parsing of NaN to not use math.h which on older systems does not define NAN.
941
+
942
+ ## 2.1.8 - 2013-10-28
943
+
944
+ - All 1.8.x versions of Ruby now have require 'rational' called.
945
+ - Removed the temporary GC disable and implemented mark strategy instead.
946
+
947
+ ## 2.1.7 - 2013-10-19
948
+
949
+ - Added support for NaN and -NaN to address issue #102. This is not according to the JSON spec but seems to be expected.
950
+ - Added require for rational if the Ruby version is 1.8.7 to address issue #104.
951
+ - Added Rails re-call of Oj.dump in the to_json() method which caused loops with Rational objects to fix issue #108 and #105.
952
+
953
+ ## 2.1.6 - 2013-10-07
954
+
955
+ - Added Oj.to_stream() for dumping JSON to an IO object.
956
+
957
+ ## 2.1.5 - 2013-07-21
958
+
959
+ - Allow exception dumping magic with Windows.
960
+
961
+ ## 2.1.4 - 2013-07-04
962
+
963
+ - Fixed Linux 32 bit rounding bug.
964
+
965
+ ## 2.1.3 - 2013-06-30
966
+
967
+ - Fixed bug that did not deserialize all attributes in an Exception subclass.
968
+ - Added a sample to demonstrate how to write Exception subclasses that will automatically serialize and deserialize.
969
+
970
+ ## 2.1.2 - 2013-06-19
971
+
972
+ - Fixed support for Windows.
973
+
974
+ ## 2.1.1 - 2013-06-17
975
+
976
+ - Fixed off by 1 error in buffer for escaped strings.
977
+
978
+ ## 2.1.0 - 2013-06-16
979
+
980
+ - This version is a major rewrite of the parser. The parser now uses a constant stack size no matter how deeply nested the JSON document is. The parser is also slightly faster for larger documents and 30% faster for object parsing.
981
+ - Oj.strict_load() was renamed to Oj.safe_load() to better represent its functionality. A new Oj.strict_load() is simply Oj.load() with :mode set to :strict.
982
+ - Oj.compat_load() and Oj.object_load() added.
983
+ - A new Simple Callback Parser was added invoked by Oj.sc_parse().
984
+ - Eliminated :max_stack option as it is no longer needed.
985
+ - Handle cleanup after exceptions better.
986
+
987
+ ## 2.0.14 - 2013-05-26
988
+
989
+ - Fixed bug in Oj::Doc.each_leaf that caused an incorrect where path to be created and also added a check for where path maximum length.
990
+ - Updated the documentation to note that invalid JSON documents, which includes an empty string or file, will cause an exception to be raised.
991
+
992
+ ## 2.0.13 - 2013-05-17
993
+
994
+ - Changed dump to put closing array brackets and closing object curlies on the line following the last element if :indent is set to greater than zero.
995
+
996
+ ## 2.0.12 - 2013-04-28
997
+
998
+ - Another fix for mimic.
999
+ - mimic_JSON now can now be called after loading the json gem. This will replace the json gem methods after loading. This may be more compatible in many cases.
1000
+
1001
+ ## 2.0.11 - 2013-04-23
1002
+
1003
+ - Fixed mimic issue with Debian
1004
+ - Added option to not cache classes when loading. This should be used when classes are dynamically unloaded and the redefined.
1005
+ - Float rounding improved by limiting decimal places to 15 places.
1006
+ - Fixed xml time dumping test.
1007
+
1008
+ ## 2.0.10 - 2013-03-10
1009
+
1010
+ - Tweaked dump calls by reducing preallocation. Speeds are now several times faster for smaller objects.
1011
+ - Fixed Windows compile error with Ruby 2.0.0.
1012
+
1013
+ ## 2.0.9 - 2013-03-04
1014
+
1015
+ - Fixed problem with INFINITY with CentOS and Ruby 2.0.0. There are some header file conflicts so a different INFINITY was used.
1016
+
1017
+ ## 2.0.8 - 2013-03-01
1018
+
1019
+ - Added :bigdecimal_load option that forces all decimals in a JSON string to be read as BigDecimals instead of as Floats. This is useful if precision is important.
1020
+ - Worked around bug in active_support 2.3.x where BigDecimal.as_json() returned self instead of a JSON primitive. Of course that creates a loop and blows the stack. Oj ignores the as_json() for any object that returns itself and instead encodes the object as it sees fit which is usually what is expected.
1021
+ - All tests pass with Ruby 2.0.0-p0. Had to modify Exception encoding slightly.
1022
+
1023
+ ## 2.0.7 - 2013-02-18
1024
+
1025
+ - Fixed bug where undefined classes specified in a JSON document would freeze Ruby instead of raising an exception when the auto_define option was not set. (It seems that Ruby freezes on trying to add variables to nil.)
1026
+
1027
+ ## 2.0.6 - 2013-02-18
1028
+
1029
+ - Worked around an undocumented feature in linux when using make that misreports the stack limits.
1030
+
1031
+ ## 2.0.5 - 2013-02-16
1032
+
1033
+ - DateTimes are now output the same in compat mode for both 1.8.7 and 1.9.3 even though they are implemented differently in each Ruby.
1034
+ - Objects implemented as data structs can now change the encoding by implemented either to_json(), as_json(), or to_hash().
1035
+ - Added an option to allow BigDecimals to be dumped as either a string or as a number. There was no agreement on which was the best or correct so both are possible with the correct option setting.
1036
+
1037
+ ## 2.0.4 - 2013-02-11
1038
+
1039
+ - Fixed bug related to long class names.
1040
+ - Change the default for the auto_define option.
1041
+ - Added Oj.strict_load() method that sets the options to public safe options. This should be safe for loading JSON documents from a public unverified source. It does not eleviate to need for reasonable programming practices of course. See the section on the proper use of Oj in a public exposure.
1042
+
1043
+ ## 2.0.3 - 2013-02-03
1044
+
1045
+ - Fixed round off error in time format when rounding up to the next second.
1046
+
1047
+ ## 2.0.2 - 2013-01-23
1048
+
1049
+ - Fixed bug in Oj.load where loading a hash with symbold keys and also turning on symbolize keys would try to symbolize a symbol.
1050
+
1051
+ ## 2.0.1 - 2013-01-15
1052
+
1053
+ - BigDecimals now dump to a string in compat mode thanks to cgriego.
1054
+ - High precision time (nano time) can be turned off for better compatibility with other JSON parsers.
1055
+ - Times before 1970 now encode correctly.
1056
+
1057
+ ## 2.0.0 - 2012-12-18
1058
+
1059
+ - Thanks to yuki24 Floats are now output with a decimal even if they are an integer value.
1060
+ - The Simple API for JSON (SAJ) API has been added. Read more about it on the Oj::Saj page.
1061
+
1062
+ ## 1.4.7 - 2012-12-09
1063
+
1064
+ - In compat mode non-String keys are converted to Strings instead of raising and error. (issue #52)
1065
+
1066
+ ## 1.4.6 - 2012-12-03
1067
+
1068
+ - Silently ignores BOM on files and Strings.
1069
+ - Now works with JRuby 1.7.0 to the extent possible with the unsupported C extension in JRuby.
1070
+
1071
+ ## 1.4.5 - 2012-11-19
1072
+
1073
+ - Adds the old deprecated methods of unparse(), fast_unparse(), and pretty_unparse() to JSON_mimic.
1074
+
1075
+ ## 1.4.4 - 2012-11-07
1076
+
1077
+ - Fixed bug in mimic that missed mimicking json_pure.
1078
+
1079
+ ## 1.4.3 - 2012-10-19
1080
+
1081
+ - Fixed Exception encoding in Windows version.
1082
+
1083
+ ## 1.4.2 - 2012-10-17
1084
+
1085
+ - Fixed dump and load of BigDecimals in :object mode.
1086
+ - BigDecimals are now dumped and loaded in all modes.
1087
+
1088
+ ## 1.4.1 - 2012-10-17
1089
+
1090
+ - Windows RubyInstaller and TCS-Ruby now supported thanks to Jarmo Pertman. Thanks Jarmo.
1091
+
1092
+ ## 1.4.0 - 2012-10-11
1093
+
1094
+ - Parse errors now raise an Exception that inherites form Oj::Error which inherits from StandardError. Some other Exceptions were changed as well to make it easier to rescue errors.
1095
+
1096
+ ## 1.3.7 - 2012-10-05
1097
+
1098
+ - Added header file for linux builds.
1099
+
1100
+ ## 1.3.6 - 2012-10-04
1101
+
1102
+ - Oj.load() now raises a SystemStackError if a JSON is too deeply nested. The loading is allowed to use on 75% of the stack.
1103
+ - Oj::Doc.open() now raises a SystemStackError if a JSON is too deeply nested. The loading is allowed to use on 75% of the stack. Oj::Doc.open will allow much deeper nesting than Oj.load().
1104
+
1105
+ ## 1.3.5 - 2012-09-25
1106
+
1107
+ - Fixed mimic_JSON so it convinces Ruby that the ALL versions of the json gem are already loaded.
1108
+
1109
+ ## 1.3.4 - 2012-08-12
1110
+
1111
+ - Fixed mimic_JSON so it convinces Ruby that the json gem is already loaded.
1112
+
1113
+ ## 1.3.2 - 2012-07-28
1114
+
1115
+ - Fixed compile problems with native Ruby on OS X 10.8 (Mountain Lion)
1116
+
1117
+ ## 1.3.1 - 2012-07-01
1118
+
1119
+ - Fixed time zone issue with :xmlschema date format.
1120
+
1121
+ ## 1.3.0 - 2012-07-09
1122
+
1123
+ - extconf.rb fixed to not pause on some OSs when checking CentOS special case.
1124
+ - Added an option to control the time format output when in :compat mode.
1125
+
1126
+ ## 1.2.13 - 2012-07-08
1127
+
1128
+ - Fixed double free bug in Oj::Doc that showed up for larger documents.
1129
+
1130
+ ## 1.2.12 - 2012-07-06
1131
+
1132
+ - Fixed GC bug in Oj::Doc, the fast parser.
1133
+ - Serialization of Exceptions in Ruby 1.8.7 now includes message and backtrace.
1134
+
1135
+ ## 1.2.11 - 2012-06-21
1136
+
1137
+ - Added :max_stack option to limit the size of string allocated on the stack.
1138
+
1139
+ ## 1.2.10 - 2012-06-20
1140
+
1141
+ - Added check for circular on loading of circular dumped JSON.
1142
+ - Added support for direct serialization of BigDecimal, Rational, Date, and DateTime.
1143
+ - Added json.rb to $" in mimic mode to avoid pulling in the real JSON by accident.
1144
+ - Oj is now thread safe for all functions.
1145
+ - The / (solidus) character is now placed in strings without being escaped.
1146
+
1147
+ ## 1.2.9 - 2012-05-29
1148
+
1149
+
1150
+ ## 1.2.8 - 2012-05-03
1151
+
1152
+ - Included a contribution by nevans to fix a math.h issue with an old fedora linux machine.
1153
+ - Included a fix to the documentation found by mat.
1154
+
1155
+ ## 1.2.7 - 2012-04-22
1156
+
1157
+ - Fixed bug where a float with too many characters would generate an error. It is not parsed as accuractly as Ruby will support.
1158
+ - Cleaned up documentation errors.
1159
+ - Added support for OS X Ruby 1.8.7.
1160
+
1161
+ ## 1.2.6 - 2012-04-22
1162
+
1163
+ - Cleaned up documentation errors.
1164
+ - Added support for OS X Ruby 1.8.7.
1165
+
1166
+ ## 1.2.5 - 2012-04-18
1167
+
1168
+ - Added support for create_id in Oj and in mimic_JSON mode
1169
+
1170
+ ## 1.2.4 - 2012-04-13
1171
+
1172
+ - Removed all use of math.h to get around CentOS 5.4 compile problem.
1173
+
1174
+ ## 1.2.3 - 2012-04-09
1175
+
1176
+ - Fixed compile error for the latest RBX on Travis.
1177
+
1178
+ ## 1.2.2 - 2012-04-02
1179
+
1180
+ - minor bug fixes for different rubies along with test updates
1181
+ - Oj::Doc will now automatically close on GC.
1182
+
1183
+ ## 1.2.1 - 2012-03-30
1184
+
1185
+ - Organized compile configuration better.
1186
+ - as_json() support now more flexible thanks to a contribution by sauliusg.
1187
+
1188
+ ## 1.2.0 - 2012-03-30
1189
+
1190
+ - Removed the encoding option and fixed a misunderstanding of the string encoding. Unicode code points are now used instead of byte codes. This is not compatible with previous releases but is compliant with RFC4627.
1191
+ - Time encoding in :object mode is faster and higher nanosecond precision.
1192
+
1193
+ ## 1.1.1 - 2012-03-27
1194
+
1195
+ - The encoding option can now be an Encoding Object or a String.
1196
+ - Fixed Rubinius errors.
1197
+
1198
+ ## 1.1.0 - 2012-03-27
1199
+
1200
+ - Errors are not longer raised when comments are encountered in JSON documents.
1201
+ - Oj can now mimic JSON. With some exceptions calling JSON.mimic_JSON will allow all JSON calls to use OJ instead of JSON. This gives a speedup of more than 2x on parsing and 5x for generating over the JSON::Ext module.
1202
+ - Oj::Doc now allows a document to be left open and then closed with the Oj::Doc.close() class.
1203
+ - Changed the default encoding to UTF-8 instead of the Ruby default String encoding.
1204
+
1205
+ ## 1.0.6 - 2012-03-20
1206
+
1207
+ - Gave Oj::Doc a speed increase. It is now 8 times fast than JSON::Ext.
1208
+
1209
+ ## 1.0.5 - 2012-03-17
1210
+
1211
+ - Added :ascii_only options for dumping JSON where all high-bit characters are encoded as escaped sequences.
1212
+
1213
+ ## 1.0.4 - 2012-03-16
1214
+
1215
+ - Fixed bug that did not allow symbols as keys in :compat mode.
1216
+
1217
+ ## 1.0.3 - 2012-03-15
1218
+
1219
+ - Added :symbol_keys option to convert String hash keys into Symbols.
1220
+ - The load() method now supports IO Objects as input as well as Strings.
1221
+
1222
+ ## 1.0.2 - 2012-03-15
1223
+
1224
+ - Added RSTRING_NOT_MODIFIED for Rubinius optimization.
1225
+
1226
+ ## 1.0.1 - 2012-03-15
1227
+
1228
+ - Fixed compatibility problems with Ruby 1.8.7.
1229
+
1230
+ ## 1.0.0 - 2012-03-13
1231
+
1232
+ - The screaming fast Oj::Doc parser added.
1233
+
1234
+ ## 0.9.0 - 2012-03-05
1235
+
1236
+ - Added support for circular references.
1237
+
1238
+ ## 0.8.0 - 2012-02-27
1239
+
1240
+ - Auto creation of data classes when unmarshalling Objects if the Class is not defined
1241
+
1242
+ ## 0.7.0 - 2012-02-26
1243
+
1244
+ - changed the object JSON format
1245
+ - serialized Ruby Objects can now be deserialized
1246
+ - improved performance testing
1247
+
1248
+ ## 0.6.0 - 2012-02-22
1249
+
1250
+ - supports arbitrary Object dumping/serialization
1251
+ - to_hash() method called if the Object responds to to_hash and the result is converted to JSON
1252
+ - to_json() method called if the Object responds to to_json
1253
+ - almost any Object can be dumped, including Exceptions (not including Thread, Mutex and Objects that only make sense within a process)
1254
+ - default options have been added
1255
+
1256
+ ## 0.5.2 - 2012-02-19
1257
+
1258
+ - Release 0.5.2 fixes encoding and float encoding.
1259
+ - This is the first release sith a version of 0.5 indicating it is only half done. Basic load() and dump() is supported for Hash, Array, NilClass, TrueClass, FalseClass, Fixnum, Float, Symbol, and String Objects.
1260
+
1261
+ ## 0.5.1 - 2012-02-19
1262
+
1263
+
1264
+ ## 0.5 - 2012-02-19
1265
+
1266
+ - This is the first release with a version of 0.5 indicating it is only half done. Basic load() and dump() is supported for Hash, Array, NilClass, TrueClass, FalseClass, Fixnum, Float, Symbol, and String Objects.