From d9adf17fbe45da89d4da2941f5a47f826154269f Mon Sep 17 00:00:00 2001 From: Earlopain <14981592+Earlopain@users.noreply.github.com> Date: Wed, 5 Jun 2024 13:53:33 +0200 Subject: [PATCH] Add an explicit dependency on the `logger` gem This is getting the same treatment as `base64`, `mutex_m`, etc. In Ruby 3.4 it will start to warn: https://github.com/ruby/ruby/commit/d7e558e3c48c213d0e8bedca4fb547db55613f7c Remoce require from two files that don't seem to need it --- Gemfile.lock | 2 ++ actionview/test/template/template_test.rb | 1 - activesupport/CHANGELOG.md | 3 +++ activesupport/activesupport.gemspec | 1 + activesupport/lib/active_support/tagged_logging.rb | 1 - 5 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Gemfile.lock b/Gemfile.lock index a5cf0757f8..97b682f4ef 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -93,6 +93,7 @@ PATH connection_pool (>= 2.2.5) drb i18n (>= 1.6, < 2) + logger minitest (>= 5.1) tzinfo (~> 2.0, >= 2.0.5) rails (8.0.0.alpha) @@ -325,6 +326,7 @@ GEM listen (3.8.0) rb-fsevent (~> 0.10, >= 0.10.3) rb-inotify (~> 0.9, >= 0.9.10) + logger (1.6.0) loofah (2.22.0) crass (~> 1.0.2) nokogiri (>= 1.12.0) diff --git a/actionview/test/template/template_test.rb b/actionview/test/template/template_test.rb index 6df34f829a..53b8b0c528 100644 --- a/actionview/test/template/template_test.rb +++ b/actionview/test/template/template_test.rb @@ -2,7 +2,6 @@ # frozen_string_literal: true require "abstract_unit" -require "logger" class TestERBTemplate < ActiveSupport::TestCase ERBHandler = ActionView::Template::Handlers::ERB.new diff --git a/activesupport/CHANGELOG.md b/activesupport/CHANGELOG.md index d178e0596a..db168229a3 100644 --- a/activesupport/CHANGELOG.md +++ b/activesupport/CHANGELOG.md @@ -1,2 +1,5 @@ +* Add `logger` as a dependency since it is a bundled gem candidate for Ruby 3.5 + + *Earlopain* Please check [7-2-stable](https://github.com/rails/rails/blob/7-2-stable/activesupport/CHANGELOG.md) for previous changes. diff --git a/activesupport/activesupport.gemspec b/activesupport/activesupport.gemspec index 4e4f651492..7f1da4eb27 100644 --- a/activesupport/activesupport.gemspec +++ b/activesupport/activesupport.gemspec @@ -42,4 +42,5 @@ s.add_dependency "base64" s.add_dependency "drb" s.add_dependency "bigdecimal" + s.add_dependency "logger" end diff --git a/activesupport/lib/active_support/tagged_logging.rb b/activesupport/lib/active_support/tagged_logging.rb index ea8f967360..90485b6613 100644 --- a/activesupport/lib/active_support/tagged_logging.rb +++ b/activesupport/lib/active_support/tagged_logging.rb @@ -2,7 +2,6 @@ require "active_support/core_ext/module/delegation" require "active_support/core_ext/object/blank" -require "logger" require "active_support/logger" module ActiveSupport