diff --git a/.github/workflows/fuzz.yml b/.github/workflows/fuzz.yml index 633ae40..ce4a0d3 100644 --- a/.github/workflows/fuzz.yml +++ b/.github/workflows/fuzz.yml @@ -26,7 +26,7 @@ jobs: run: working-directory: ext/nosj steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - uses: ruby/setup-ruby@v1 with: ruby-version: "3.4" diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 649f65a..c4be758 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -15,7 +15,7 @@ jobs: standardrb: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - uses: ruby/setup-ruby@v1 with: @@ -27,7 +27,7 @@ jobs: rbs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - uses: ruby/setup-ruby@v1 with: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 97d52bb..b636447 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -29,7 +29,7 @@ jobs: tag: ${{ steps.version.outputs.tag }} version: ${{ steps.version.outputs.version }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - name: Read version id: version @@ -52,7 +52,7 @@ jobs: needs: version runs-on: ubuntu-latest steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 with: ref: ${{ github.sha }} @@ -103,7 +103,7 @@ jobs: env: SKIP_PGO: ${{ matrix.skip_pgo || '' }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 with: ref: ${{ github.sha }} @@ -163,7 +163,7 @@ jobs: - { platform: aarch64-linux-musl, os: ubuntu-24.04-arm } runs-on: ${{ matrix.os }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 with: ref: ${{ github.sha }} @@ -219,7 +219,7 @@ jobs: } runs-on: ${{ matrix.runs_on }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 with: ref: ${{ github.sha }} sparse-checkout: script/ci/smoke.rb @@ -258,7 +258,7 @@ jobs: contents: write id-token: write steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 with: ref: ${{ github.sha }} diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 35e2796..3f0d8d2 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -25,7 +25,7 @@ jobs: ruby: ["3.3", "3.4", "4.0"] steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - name: Set up Ruby & Rust uses: oxidize-rb/actions/setup-ruby-and-rust@v1 @@ -65,7 +65,7 @@ jobs: NOSJ_JSON_VERSION: ${{ matrix.json }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - name: Set up Ruby & Rust uses: oxidize-rb/actions/setup-ruby-and-rust@v1 @@ -86,8 +86,8 @@ jobs: - name: Run the Rails-facing specs run: bundle exec rspec spec/rails_spec.rb spec/rails_integration_spec.rb spec/json_dropin_spec.rb - # The whole suite against json 3 (the main matrix runs the locked json - # 2.x): the drop-in follows whichever is installed, and the parity + # The whole suite against json 2 (the main matrix runs the locked json + # 3.x): the drop-in follows whichever is installed, and the parity # specs compare against it. json-compat: name: json ${{ matrix.json }} on Ruby ${{ matrix.ruby }} @@ -96,13 +96,13 @@ jobs: fail-fast: false matrix: include: - - { json: "~> 3.0", ruby: "3.3" } - - { json: "~> 3.0", ruby: "4.0" } + - { json: "< 3", ruby: "3.3" } + - { json: "< 3", ruby: "4.0" } env: NOSJ_JSON_VERSION: ${{ matrix.json }} steps: - - uses: actions/checkout@v6 + - uses: actions/checkout@v7 - name: Set up Ruby & Rust uses: oxidize-rb/actions/setup-ruby-and-rust@v1 @@ -110,7 +110,7 @@ jobs: ruby-version: ${{ matrix.ruby }} cargo-cache: true - # The committed lockfile pins json 2.x; the pin needs a fresh + # The committed lockfile pins json 3.x; the pin needs a fresh # resolution. - name: Bundle with the pinned json run: | diff --git a/Cargo.lock b/Cargo.lock index 557f080..2714626 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -76,9 +76,9 @@ dependencies = [ [[package]] name = "either" -version = "1.18.0" +version = "1.19.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "252afb9ae5eaa683babdc6a068b3f5726eb19e05070c731f9b2a23a7c3e8ed34" +checksum = "0e9c71c2167ca323c882b99918929403426e2373ea17242ff5653e0d5e1058be" [[package]] name = "fast-float2" @@ -115,15 +115,15 @@ dependencies = [ [[package]] name = "lazy_static" -version = "1.5.0" +version = "1.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" +checksum = "20870f649af7073d53e38067b2a84312175d56ea15217e1b15bc83506ec50afb" [[package]] name = "libc" -version = "0.2.189" +version = "0.2.191" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3eaf3ede3fee6db1a4c2ee091bf8a8b4dccdc6d17f656fb07896ee72867612f2" +checksum = "65cd87c9a6d60536580b316ad985726104730a5151c99845f2490428ef91240a" [[package]] name = "libloading" @@ -137,9 +137,9 @@ dependencies = [ [[package]] name = "magnus" -version = "0.9.0" +version = "0.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "379d50b6eea4ca84074ccd3e551eb9b07f7865194d5b3198325317e9ef78e5e9" +checksum = "40ef424404d166cbb71c8b8d19c9c589c748c4547c1afa1928c5504299f6c713" dependencies = [ "magnus-macros", "rb-sys", @@ -149,9 +149,9 @@ dependencies = [ [[package]] name = "magnus-macros" -version = "0.9.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4ca70566af98184bb92d4d9853daaf533c1a3418b9570d0547ea44970035f3fe" +checksum = "9dafde2eeb66f090e0f326112323eb8324b12cb32b5d1210e541d3df6b0ce77e" dependencies = [ "proc-macro2", "quote", @@ -166,9 +166,9 @@ checksum = "cf8baf1c55e62ffcace7a9f06f4bd9cd3f0c4beb022d3b367256b91b87513d98" [[package]] name = "memmap2" -version = "0.9.11" +version = "0.9.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d1219ed1b7f229ee7104d281dd01d6802fe28bb6e95d292942c4daacdeb798c0" +checksum = "6b0ca1155a9ecc25aa12e8313a119f32edf0255fea2f44839c4ac0a12b2ac157" dependencies = [ "libc", ] @@ -335,9 +335,9 @@ dependencies = [ [[package]] name = "unicode-ident" -version = "1.0.26" +version = "1.0.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d245f478577f809a851594d02313b640fb437e0bb33866753cff937863096954" +checksum = "a2c754d6c33795a1c324727428e5a7dedb5b06195f9890bdbcba760d3e246563" [[package]] name = "version_check" @@ -368,18 +368,18 @@ checksum = "1ebf944e87a7c253233ad6766e082e3cd714b5d03812acc24c318f549614536e" [[package]] name = "zerocopy" -version = "0.8.58" +version = "0.8.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c17e8fafad82b542ff3717217ecdc736231b59e387768c9630123b4ce4d2db44" +checksum = "e5fe1f8f1b06191a00962174c61aa5005e0bb391a6d80d07e24d115c01a92ed8" dependencies = [ "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.8.58" +version = "0.8.63" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "595f56e044df4f46a0c9a626f65c3d99eb8488f7e8a8baa12dd76326d9710bf2" +checksum = "863ad3ac83293fb4d740aedbfdc9240dd8d1a50c1099acd76ce80ce7c7230c7f" dependencies = [ "proc-macro2", "quote", diff --git a/Gemfile b/Gemfile index 93bb2f6..4687af4 100644 --- a/Gemfile +++ b/Gemfile @@ -27,14 +27,14 @@ group :test do gem "actionpack", *[rails_pin].compact end -# Pinnable for CI's json-compat matrix (e.g. "~> 3.0"): the drop-in -# follows whichever json is installed. A pinned run leaves out standard, -# whose rubocop requires json 2.x. +# Pinnable for CI's json-compat and rails-compat matrices (e.g. "< 3"): +# the drop-in follows whichever json is installed. json_pin = ENV.fetch("NOSJ_JSON_VERSION", nil) gem "json", json_pin if json_pin group :development do - gem "standard", "~> 1.3" unless json_pin + # 1.57 is the first standard whose rubocop accepts json 3. + gem "standard", "~> 1.57" gem "rbs", "~> 4.0" gem "yard", "~> 0.9" gem "lefthook", "~> 2.1" diff --git a/Gemfile.lock b/Gemfile.lock index be507a7..7f615e0 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -7,9 +7,9 @@ PATH GEM remote: https://rubygems.org/ specs: - actionpack (8.1.3.1) - actionview (= 8.1.3.1) - activesupport (= 8.1.3.1) + actionpack (8.1.4) + actionview (= 8.1.4) + activesupport (= 8.1.4) nokogiri (>= 1.8.5) rack (>= 2.2.4) rack-session (>= 1.0.1) @@ -17,13 +17,13 @@ GEM rails-dom-testing (~> 2.2) rails-html-sanitizer (~> 1.6) useragent (~> 0.16) - actionview (8.1.3.1) - activesupport (= 8.1.3.1) + actionview (8.1.4) + activesupport (= 8.1.4) builder (~> 3.1) erubi (~> 1.11) rails-dom-testing (~> 2.2) rails-html-sanitizer (~> 1.6) - activesupport (8.1.3.1) + activesupport (8.1.4) base64 bigdecimal concurrent-ruby (~> 1.0, >= 1.3.1) @@ -41,20 +41,20 @@ GEM benchmark-ips (2.15.1) benchmark-memory (0.2.0) memory_profiler (~> 1) - bigdecimal (4.1.2) + bigdecimal (4.1.3) builder (3.3.0) concurrent-ruby (1.3.8) connection_pool (3.0.2) - crass (1.0.7) + crass (1.0.8) diff-lcs (1.6.2) drb (2.2.3) erubi (1.13.1) fast_jsonparser (0.6.0) i18n (1.15.2) concurrent-ruby (~> 1.0) - json (2.21.2) + json (3.1.0) language_server-protocol (3.17.0.6) - lefthook (2.1.12) + lefthook (2.2.2) lint_roller (1.1.0) logger (1.7.0) loofah (2.25.2) @@ -65,7 +65,7 @@ GEM minitest (6.0.6) drb (~> 2.0) prism (~> 1.5) - multi_json (1.21.1) + multi_json (1.21.2) nokogiri (1.19.4) mini_portile2 (~> 2.8.2) racc (~> 1.4) @@ -81,12 +81,12 @@ GEM racc (~> 1.4) nokogiri (1.19.4-x86_64-linux-musl) racc (~> 1.4) - oj (3.17.6) + oj (3.17.7) bigdecimal (>= 3.0) ostruct (>= 0.2) ostruct (0.6.3) - parallel (2.1.0) - parser (3.3.12.0) + parallel (2.3.0) + parser (3.3.13.0) ast (~> 2.4.1) racc prism (1.9.0) @@ -95,7 +95,7 @@ GEM rack-session (2.1.2) base64 (>= 0.1.0) rack (>= 3.0.0) - rack-test (2.2.0) + rack-test (2.3.0) rack (>= 1.3) rails-dom-testing (2.3.0) activesupport (>= 5.0.0) @@ -106,7 +106,7 @@ GEM nokogiri (>= 1.15.7, != 1.16.7, != 1.16.6, != 1.16.5, != 1.16.4, != 1.16.3, != 1.16.2, != 1.16.1, != 1.16.0.rc1, != 1.16.0) rainbow (3.1.1) rake (13.4.2) - rake-compiler (1.3.1) + rake-compiler (1.3.2) rake rake-compiler-dock (1.12.0) rapidjson (0.4.0) @@ -116,7 +116,7 @@ GEM logger prism (>= 1.6.0) tsort - regexp_parser (2.12.0) + regexp_parser (2.13.1) rspec (3.13.2) rspec-core (~> 3.13.0) rspec-expectations (~> 3.13.0) @@ -130,8 +130,8 @@ GEM diff-lcs (>= 1.2.0, < 2.0) rspec-support (~> 3.13.0) rspec-support (3.13.7) - rubocop (1.88.2) - json (~> 2.3) + rubocop (1.91.0) + json (>= 2.3) language_server-protocol (~> 3.17.0.2) lint_roller (~> 1.1.0) parallel (>= 1.10) @@ -150,10 +150,10 @@ GEM rubocop-ast (>= 1.47.1, < 2.0) ruby-progressbar (1.13.0) securerandom (0.4.1) - standard (1.56.0) + standard (1.57.0) language_server-protocol (~> 3.17.0.2) lint_roller (~> 1.0) - rubocop (~> 1.88.0) + rubocop (~> 1.91.0) standard-custom (~> 1.0.0) standard-performance (~> 1.8) standard-custom (1.0.2) @@ -165,10 +165,10 @@ GEM tsort (0.2.0) tzinfo (2.0.6) concurrent-ruby (~> 1.0) - unicode-display_width (3.2.0) - unicode-emoji (~> 4.1) - unicode-emoji (4.2.0) - uri (1.1.1) + unicode-display_width (3.3.0) + unicode-emoji (~> 4.3) + unicode-emoji (4.3.0) + uri (1.1.2) useragent (0.16.11) yajl-ruby (1.4.3) yard (0.9.45) @@ -198,9 +198,9 @@ DEPENDENCIES rapidjson rbs (~> 4.0) rspec (~> 3.0) - standard (~> 1.3) + standard (~> 1.57) yajl-ruby yard (~> 0.9) BUNDLED WITH - 4.0.1 + 4.0.23 diff --git a/Rakefile b/Rakefile index 79a7cba..cec1ea3 100644 --- a/Rakefile +++ b/Rakefile @@ -5,8 +5,7 @@ require "rspec/core/rake_task" RSpec::Core::RakeTask.new(:spec) -# CI's json-compat bundle has no standard (see Gemfile). -require "standard/rake" unless ENV["NOSJ_JSON_VERSION"] +require "standard/rake" require "rb_sys/extensiontask"