Skip to content

Commit

Permalink
Fix Ruby 3.3 deprecation warning
Browse files Browse the repository at this point in the history
Ruby 3.3 [moved][] the `observer` library into a bundled gem, which
means we must declare it as an explicit depedency going forward.

[moved]: https://www.ruby-lang.org/en/news/2023/12/25/ruby-3-3-0-released/
  • Loading branch information
olegantonyan authored and mike-burns committed Dec 26, 2023
1 parent 0c46150 commit adc4857
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ PATH
specs:
factory_bot (6.4.2)
activesupport (>= 5.0.0)
observer

GEM
remote: https://rubygems.org/
Expand Down Expand Up @@ -73,6 +74,7 @@ GEM
middleware (0.1.0)
minitest (5.14.3)
multi_test (0.1.2)
observer (0.1.2)
parallel (1.22.1)
parser (3.1.2.1)
ast (~> 2.4.1)
Expand Down
1 change: 1 addition & 0 deletions factory_bot.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Gem::Specification.new do |s|
}

s.add_dependency("activesupport", ">= 5.0.0")
s.add_dependency("observer") if Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.3')

s.add_development_dependency("activerecord")
s.add_development_dependency("appraisal")
Expand Down

0 comments on commit adc4857

Please sign in to comment.