From f2d8a973b562ec57e22333cd7ce4ee77d4418211 Mon Sep 17 00:00:00 2001 From: Charlie Sharpsteen Date: Tue, 7 Jul 2026 08:34:36 -0500 Subject: [PATCH 1/3] Drop Java 17 from GitHub Actions matrix JRuby 10 requires Java 21 or newer. Attempting to run tests under Java 17 just results in a pile of type errors from the Java compiler. Signed-off-by: Charlie Sharpsteen --- .github/workflows/lein-test.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/lein-test.yaml b/.github/workflows/lein-test.yaml index 82e752d7..8ec088da 100644 --- a/.github/workflows/lein-test.yaml +++ b/.github/workflows/lein-test.yaml @@ -24,7 +24,6 @@ jobs: java: - '25' - '21' - - '17' steps: - name: Check out repository code uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 From e8fb18b7993dc9850a91d581f8c8589ab41e6ed6 Mon Sep 17 00:00:00 2001 From: Charlie Sharpsteen Date: Tue, 7 Jul 2026 08:59:43 -0500 Subject: [PATCH 2/3] Remove dead imports of org.jruby CompatVersion The `org.jruby.CompatVersion` class was used by JRuby 1.x to switch the Ruby language version targeted by its interpreter between 1.8.x, 1.9.x, and 2.x. This functionality was reduced to a deprecated no-op in JRuby 9.0 and finally removed in JRuby 10.0. This commit removes all imports of `org.jruby.CompatVersion` from `jruby-utils` code as they cause tests to fail under JRuby 10. None of the imports were actually used, they were all dead code. Signed-off-by: Charlie Sharpsteen --- .../services/jruby_pool_manager/impl/jruby_internal.clj | 2 +- src/clj/puppetlabs/services/jruby_pool_manager/jruby_core.clj | 1 - .../services/jruby_pool_manager/jruby_internal_test.clj | 2 +- 3 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/clj/puppetlabs/services/jruby_pool_manager/impl/jruby_internal.clj b/src/clj/puppetlabs/services/jruby_pool_manager/impl/jruby_internal.clj index e080728b..d1e0b32d 100644 --- a/src/clj/puppetlabs/services/jruby_pool_manager/impl/jruby_internal.clj +++ b/src/clj/puppetlabs/services/jruby_pool_manager/impl/jruby_internal.clj @@ -15,7 +15,7 @@ ScriptingContainer) (java.io File) (java.util.concurrent TimeUnit Executors ExecutorService) - (org.jruby CompatVersion Main Ruby RubyInstanceConfig RubyInstanceConfig$CompileMode RubyInstanceConfig$ProfilingMode) + (org.jruby Main Ruby RubyInstanceConfig RubyInstanceConfig$CompileMode RubyInstanceConfig$ProfilingMode) (org.jruby.embed LocalContextScope) (org.jruby.runtime.profile.builtin ProfileOutput) (org.jruby.util KCode) diff --git a/src/clj/puppetlabs/services/jruby_pool_manager/jruby_core.clj b/src/clj/puppetlabs/services/jruby_pool_manager/jruby_core.clj index b32378b6..0aba10bc 100644 --- a/src/clj/puppetlabs/services/jruby_pool_manager/jruby_core.clj +++ b/src/clj/puppetlabs/services/jruby_pool_manager/jruby_core.clj @@ -16,7 +16,6 @@ (:import (puppetlabs.services.jruby_pool_manager.jruby_schemas JRubyInstance) (clojure.lang IFn) (java.util.concurrent TimeUnit) - (org.jruby CompatVersion) (org.jruby.util.cli OutputStrings))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; diff --git a/test/integration/puppetlabs/services/jruby_pool_manager/jruby_internal_test.clj b/test/integration/puppetlabs/services/jruby_pool_manager/jruby_internal_test.clj index 10dc4b54..0276976c 100644 --- a/test/integration/puppetlabs/services/jruby_pool_manager/jruby_internal_test.clj +++ b/test/integration/puppetlabs/services/jruby_pool_manager/jruby_internal_test.clj @@ -9,7 +9,7 @@ [me.raynes.fs :as fs]) (:import (java.io StringReader) (com.puppetlabs.jruby_utils.pool JRubyPool) - (org.jruby RubyInstanceConfig$CompileMode CompatVersion RubyInstanceConfig$ProfilingMode) + (org.jruby RubyInstanceConfig$CompileMode RubyInstanceConfig$ProfilingMode) (org.jruby.util.cli Options) (clojure.lang ExceptionInfo))) From 56c28169d21bf8c14beb8ce04bdb68dd74571918 Mon Sep 17 00:00:00 2001 From: Charlie Sharpsteen Date: Tue, 7 Jul 2026 09:08:08 -0500 Subject: [PATCH 3/3] Stop testing for a specific JRuby version This commit updates one of the core unit tests to stop looking for a specific JRuby version and to instead accept any version string that starts with "jruby". This allows the test suite to pass on both JRuby 9.4 and JRuby 10, and keeps things open for future versions. Signed-off-by: Charlie Sharpsteen --- .../puppetlabs/services/jruby_pool_manager/jruby_core_test.clj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/unit/puppetlabs/services/jruby_pool_manager/jruby_core_test.clj b/test/unit/puppetlabs/services/jruby_pool_manager/jruby_core_test.clj index b4c84475..37602116 100644 --- a/test/unit/puppetlabs/services/jruby_pool_manager/jruby_core_test.clj +++ b/test/unit/puppetlabs/services/jruby_pool_manager/jruby_core_test.clj @@ -125,4 +125,4 @@ (is (re-find #"bar" out)))))) (deftest jruby-version-info-test - (is (re-find #"jruby 9." jruby-core/jruby-version-info))) + (is (re-find #"^jruby" jruby-core/jruby-version-info)))