Closed mansoorelahi closed 4 years ago
Any update on it @vilyapilya should we write a custom error handler and ditch the rails supports ?
@mansoorelahi can you please give us more information on how you use the logger in your code?
@mansoorelahi Actually I see what the issue is. I was able to reproduce it. Ruby just tries to use its own logger and initialize the Logger class and does not really reassign config.logger. Try to use a different name instead of 'logger'. For example
config.logdnaLogger = Logdna::Ruby.new(key, options)
and then you can use it in your application like so :
Rails.configuration.logdnaLogger.log("my log message")
@vilyapilya Same thing happens to me, but the workaround you provided is not good for us.
We basically need to replace the default logger with logdna so it captures all the logs. Could you please look into this? Thanks!
@mansoorelahi , @vidurangaw we will release the fix next week.
@mansoorelahi , @vidurangaw the fix is in the v1.4.1
There seems to be some issue with the library when used as config.logger = Logdna::Ruby.new("key", options={} ) as per the README its showing the below error .rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/logger.rb:284:in `level=': invalid log level: (ArgumentError)