1
0
Fork 0
mirror of https://github.com/mperham/sidekiq.git synced 2022-11-09 13:52:34 -05:00
mperham--sidekiq/lib
ojab 20cdf68a73
Improve compatibility with Semantic Logger (#5238)
Semantic Logger returns Symbol for `#level`:
```
[1] pry(main)> SemanticLogger[Sidekiq].level
=> :debug
```
so current code fails with
```
[2] pry(main)> Sidekiq.logger = SemanticLogger[Sidekiq]
=> #<SemanticLogger::Logger:0x00007f1d27984a18 @filter=nil, @level=nil, @level_index=nil, @name="Sidekiq">
[3] pry(main)> Sidekiq.logger.debug?
ArgumentError: comparison of Symbol with 0 failed
from /home/ojab/.rbenv/versions/3.1.1/lib/ruby/gems/3.1.0/gems/sidekiq-6.4.1/lib/sidekiq/logger.rb:39:in
`<='
```
Calling `#{level}?` methods on the logger directly instead of
comparing `#level` with integer fixes that.
2022-03-10 09:20:18 -08:00
..
generators/sidekiq Replace worker generator with job generator (#5055) 2021-11-17 08:35:18 -08:00
sidekiq Improve compatibility with Semantic Logger (#5238) 2022-03-10 09:20:18 -08:00
sidekiq.rb Improve compatibility with Semantic Logger (#5238) 2022-03-10 09:20:18 -08:00