Age | Commit message (Collapse) | Author |
|
https://github.com/ruby/json/commit/92beca8032
|
|
https://github.com/ruby/stringio/commit/14fbdcc02c
|
|
https://github.com/ruby/stringio/commit/ee3ee1df31
|
|
EOC octets are required at the end of contents of a constructed encoding
that uses the indefinite length form. This cannot be assumed from the
end of the input. Raise an exception when necessary.
https://github.com/ruby/openssl/commit/bc20c13a7c
|
|
'NV Domain' needs to be quoted.
https://github.com/ruby/resolv/commit/332a16dcc0
|
|
Notes:
Merged-By: ioquatix <[email protected]>
|
|
Notes:
Merged-By: ioquatix <[email protected]>
|
|
Correctly pass the new object assigned by StringValue() to
ossl_ssl_write_internal_safe().
This is a follow-up to commit https://github.com/ruby/openssl/commit/0d8c17aa855d (Reduce
OpenSSL::Buffering#do_write overhead, 2024-12-21).
https://github.com/ruby/openssl/commit/3ff096196a
|
|
(https://github.com/ruby/stringio/pull/129)
Companion PR to <https://github.com/ruby/ruby/pull/7894>.
https://github.com/ruby/stringio/commit/2d3988e12f
|
|
https://github.com/ruby/json/commit/573ebdca89
|
|
https://github.com/ruby/json/commit/27155b6500
|
|
https://github.com/ruby/json/commit/3e7e661ef5
|
|
https://github.com/ruby/json/commit/ff8e18392d
|
|
https://github.com/ruby/strscan/commit/7b1eb1e4ed
|
|
(https://github.com/ruby/strscan/pull/147)
For a reason unknown, even though `pos` is stored as a `long`, the
`#pos` and `#pos=` treat it as an `int`, which prevent seeking into
strings larger than 2GiB.
https://github.com/ruby/strscan/commit/b76368416e
Co-authored-by: Jean Boussier <[email protected]>
|
|
https://github.com/ruby/etc/commit/410c8dd4ae
|
|
https://github.com/ruby/etc/commit/15c2696794
|
|
Notes:
Merged-By: ioquatix <[email protected]>
|
|
https://github.com/ruby/json/commit/97f2924d0a
|
|
https://github.com/ruby/json/commit/97f47d1cfd
|
|
T_DATA with a NULL pointer are not marked. Let's wrap 1 instead to
ensure that our mark function is actually run.
Notes:
Merged: https://github.com/ruby/ruby/pull/13047
|
|
[Bug #21211]
Socket errors raised from background threads are hard to track down because
their backtrace starts from the spawned thread.
To solve this we can raise a new error with the old one as `cause`.
Notes:
Merged: https://github.com/ruby/ruby/pull/13041
|
|
|
|
By leveraging the `on_load` callback we can move all this logic
out of the parser. Which mean we no longer have to duplicate
that logic in both parser and that we'll later be able to extract
it entirely from the gem.
https://github.com/ruby/json/commit/f411ddf1ce
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
And substitute the return value like `Marshal.load` doesm
which I can only assume was the intent.
This also open the door to re-implement all the `create_addition`
logic in `json/common.rb`.
https://github.com/ruby/json/commit/73d2137fd3
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
https://github.com/ruby/json/commit/eda239ad34
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
https://github.com/ruby/json/commit/1ca7efed1f
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
https://github.com/ruby/json/commit/760d922265
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
https://github.com/ruby/json/commit/3de8702354
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
https://github.com/ruby/json/commit/01c47a0555
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
https://github.com/ruby/json/commit/6508455d82
Notes:
Merged: https://github.com/ruby/ruby/pull/13004
|
|
Fix https://github.com/ruby/psych/pull/644
https://github.com/ruby/psych/commit/b1ade765ba
|
|
It was only used by JRuby and TruffleRuby to call `SAFE_STATE_PROTOTYPE.dup`
instead of `State.new` which isn't an worthy optimization.
Notes:
Merged: https://github.com/ruby/ruby/pull/12994
|
|
Some relatively minor change to make the library more in line
with the gem. Some renaming, etc.
Notes:
Merged: https://github.com/ruby/ruby/pull/12994
|
|
|
|
|
|
This commit provides an alternative implementation for a
long → decimal conversion.
The main difference is that it uses an algorithm pulled from
https://github.com/jeaiii/itoa.
The source there is C++, it was converted by hand to C for
inclusion with this gem.
jeaiii's algorithm is covered by the MIT License, see source code.
On addition this version now also generates the string directly into
the fbuffer, foregoing the need to run a separate memory copy.
As a result, I see a speedup of 32% on Apple Silicon M1 for an
integer set of benchmarks.
|
|
https://github.com/ruby/json/commit/18e5c3c67c
|
|
These were deprecated 16 years ago.
https://github.com/ruby/json/commit/a88d825a91
|
|
Globally changing the behavior of the library is a bad idea, as
many different libraries may rely on `json` and may not expect it
and likely never tested that a different default config works for them.
If you need to change the behavior of JSON, it's best to do it only
locally, and not globally.
In addition the new `JSON::Coder` interface is much more suited for
that.
Another reason for the deprecation is that it's impossible to
make `JSON.load` and `JSON.dump` Ractor-safe with such API.
https://github.com/ruby/json/commit/172762c6e4
|
|
* Because it uses RbConfig::CONFIG.
* See https://github.com/ruby/ruby/actions/runs/14069312270/job/39399502142#step:12:947
https://github.com/ruby/etc/commit/12dbe03b6a
|
|
* See https://bugs.ruby-lang.org/issues/21115
https://github.com/ruby/etc/commit/ae62b7619c
|
|
|
|
|
|
Make it a single file and declare the dependency.
|
|
https://github.com/ruby/json/commit/cce3d1f6c1
|
|
Adds a test case
fix
https://github.com/ruby/json/commit/fa5bdf87cb
|
|
This commit provides an alternative implementation for a float → decimal conversion.
It integrates a C implementation of Fabian Loitsch's Grisu-algorithm [[pdf]](http://florian.loitsch.com/publications/dtoa-pldi2010.pdf), extracted from https://github.com/night-shift/fpconv. The relevant files are added in this PR, they are, as is all of https://github.com/night-shift/fpconv, available under a MIT License.
As a result, I see a speedup of 900% on Apple Silicon M1 for a float set of benchmarks.
floats don't have a single correct string representation: a float like `1000.0` can be represented as "1000", "1e3", "1000.0" (and more).
The Grisu algorithm converts floating point numbers to an optimal decimal string representation without loss of precision. As a result, a float that is exactly an integer (like `Float(10)`) will be converted by that algorithm into `"10"`. While technically correct – the JSON format treats floats and integers identically –, this differs from the current behaviour of the `"json"` gem. To address this, the integration checks for that case, and explicitely adds a ".0" suffix in those cases.
This is sufficient to meet all existing tests; there is, however, a chance that the current implementation and this implementation occasionally encode floats differently.
```
== Encoding floats (4179311 bytes)
ruby 3.4.1 (2024-12-25 revision https://github.com/ruby/json/commit/48d4efcb85) +YJIT +PRISM [arm64-darwin24]
Warming up --------------------------------------
json (local) 4.000 i/100ms
Calculating -------------------------------------
json (local) 46.046 (± 2.2%) i/s (21.72 ms/i) - 232.000 in 5.039611s
Normalize to 2090234 byte
== Encoding floats (4179242 bytes)
ruby 3.4.1 (2024-12-25 revision https://github.com/ruby/json/commit/48d4efcb85) +YJIT +PRISM [arm64-darwin24]
Warming up --------------------------------------
json (2.10.2) 1.000 i/100ms
Calculating -------------------------------------
json (2.10.2) 4.614 (± 0.0%) i/s (216.74 ms/i) - 24.000 in 5.201871s
```
These benchmarks are run via a script ([link](https://gist.github.com/radiospiel/04019402726a28b31616df3d0c17bd1c)) which is based on the gem's `benchmark/encoder.rb` file. There are probably better ways to run benchmarks :) My version allows to combine multiple test cases into a single one.
The `dumps` benchmark, which covers the JSON files in `benchmark/data/*.json` – with the exception of `canada.json` – , reported a minor speedup within statistical uncertainty.
https://github.com/ruby/json/commit/7d77415108
|
|
https://github.com/ruby/date/commit/a3d85e0be5
|
|
Notes:
Merged: https://github.com/ruby/ruby/pull/12923
|