lsegal / yard

YARD is a Ruby Documentation tool. The Y stands for "Yay!"
http://yardoc.org
MIT License
1.92k stars 394 forks source link

Add `logger` to runtime dependency #1546

Open koic opened 2 weeks ago

koic commented 2 weeks ago

This PR adds logger to runtime dependency to suppress the following warning:

$ ruby -v
ruby 3.4.0dev (2024-06-14T03:14:32Z master 2677ab1607) [x86_64-darwin23]
$ cd path/to/rubocop
$ bundle exec rake
/Users/koic/.rbenv/versions/3.4-dev/lib/ruby/gems/3.4.0+0/gems/yard-0.9.36/lib/yard/logging.rb:3:
warning: logger was loaded from the standard library, but will no longer be part of the default gems since Ruby 3.5.0.
Add logger to your Gemfile or gemspec.

This change is aimed at Ruby 3.5 and will start showing warnings from Ruby 3.4: https://github.com/ruby/ruby/commit/d7e558e

To maintain the following behavior, the dependency will be added in the gemspec to resolve this. https://github.com/lsegal/yard/blob/v0.9.36/lib/yard/logging.rb#L3-L9

Description

Describe your pull request and problem statement here.

Completed Tasks