From 7f0b1ea27ca82dc106e742b47abd327ddd17854d Mon Sep 17 00:00:00 2001 From: Andy Waite <13400+andyw8@users.noreply.github.com> Date: Tue, 24 Jun 2025 13:08:50 -0400 Subject: [PATCH 1/3] Update httparty for Ruby 3.4 compatability --- .github/workflows/ruby.yml | 2 +- Gemfile.lock | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index 98e9790..2470d05 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -23,7 +23,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - ruby-version: ['3.1'] + ruby-version: ['3.1', '3.4'] steps: - uses: actions/checkout@v4 diff --git a/Gemfile.lock b/Gemfile.lock index 4b302b2..ecc7a28 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -33,6 +33,7 @@ GEM crack (1.0.0) bigdecimal rexml + csv (3.3.5) diff-lcs (1.5.0) drb (2.1.1) ruby2_keywords @@ -46,7 +47,8 @@ GEM faraday-net_http (3.0.2) ffi (1.16.3) hashdiff (1.1.0) - httparty (0.21.0) + httparty (0.23.1) + csv mini_mime (>= 1.0.0) multi_xml (>= 0.5.2) i18n (1.14.1) @@ -57,7 +59,8 @@ GEM method_source (1.0.0) mini_mime (1.1.5) minitest (5.20.0) - multi_xml (0.6.0) + multi_xml (0.7.2) + bigdecimal (~> 3.1) multipart-post (2.3.0) mutex_m (0.1.2) ostruct (0.6.1) From 4715475261130716e2747d8ba44cc97e527f037a Mon Sep 17 00:00:00 2001 From: Andy Waite <13400+andyw8@users.noreply.github.com> Date: Tue, 24 Jun 2025 13:12:57 -0400 Subject: [PATCH 2/3] Update minimum Ruby version --- .github/workflows/ruby.yml | 2 +- sublayer.gemspec | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index 2470d05..f8f8052 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -23,7 +23,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - ruby-version: ['3.1', '3.4'] + ruby-version: ['3.2', '3.4'] steps: - uses: actions/checkout@v4 diff --git a/sublayer.gemspec b/sublayer.gemspec index 709ff88..ad68300 100644 --- a/sublayer.gemspec +++ b/sublayer.gemspec @@ -12,7 +12,7 @@ Gem::Specification.new do |spec| spec.summary = "A model-agnostic Ruby GenerativeAI DSL and Framework" spec.description = "A DSL and framework for building AI powered applications through the use of Generators, Actions, Tasks, and Agents" spec.homepage = "https://docs.sublayer.com" - spec.required_ruby_version = ">= 2.6.0" + spec.required_ruby_version = ">= 3.2.0" spec.metadata["homepage_uri"] = "https://docs.sublayer.com" spec.metadata["documentation_uri"] = "https://docs.sublayer.com" From 61016aff209788c5c304fd6595665c4f61e1245a Mon Sep 17 00:00:00 2001 From: Andy Waite <13400+andyw8@users.noreply.github.com> Date: Tue, 24 Jun 2025 13:24:54 -0400 Subject: [PATCH 3/3] Handle output difference for Ruby 3.4 --- spec/logging/debug_logger_spec.rb | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/spec/logging/debug_logger_spec.rb b/spec/logging/debug_logger_spec.rb index 0d1470d..df08f4f 100644 --- a/spec/logging/debug_logger_spec.rb +++ b/spec/logging/debug_logger_spec.rb @@ -12,8 +12,14 @@ end it "pretty prints the data" do + expected = if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new("3.4") + /\{key: "value"\}/ + else + /\{:key=>"value"\}/ + end + expect { logger.log(:info, message, data) - }.to output(/\{:key=>"value"\}/).to_stdout + }.to output(expected).to_stdout end end