module Console
Shims for the console gem, redirecting warnings and above to Kernel#warn
.
If you require this file, the async
library will not depend on the console
gem.
That includes any gems that sit within the Async
namespace.
This is an experimental feature.
Definitions
def self.debug(...)
Log a message at the debug level. The shim is silent.
Implementation
def self.debug(...)
end
def self.info(...)
Log a message at the info level. The shim is silent.
Implementation
def self.info(...)
end
def self.warn(*arguments, exception: nil, **options)
Log a message at the warn level. The shim redirects to Kernel#warn
.
Implementation
def self.warn(*arguments, exception: nil, **options)
if exception
super(*arguments, exception.full_message, **options)
else
super(*arguments, **options)
end
end
def self.error(...)
Log a message at the error level. The shim redirects to Kernel#warn
.
Implementation
def self.error(...)
self.warn(...)
end
def self.fatal(...)
Log a message at the fatal level. The shim redirects to Kernel#warn
.
Implementation
def self.fatal(...)
self.warn(...)
end