Open snehaso opened 4 years ago
@snehaso in case this is still useful to you: while spiking out using deprecation toolkit I ran into this issue and worked around it by overriding deprecations_without_stacktrace
. So, not a long term solution but as I said: just in case it's useful. Here's most of the initializer we were thinking of using:
DeprecationToolkit::Configuration.warnings_treated_as_deprecation = [
/Using the last argument as keyword parameters is deprecated/,
/Capturing the given block using Proc.new is deprecated/,
]
module DeprecationToolkit
class Collector
alias old_deprecations_without_stacktrace deprecations_without_stacktrace
def deprecations_without_stacktrace
old_deprecations_without_stacktrace.map do |deprecation|
deprecation
.sub(/^DEPRECATION WARNING: \/.* warning: /, "DEPRECATION WARNING: ")
.sub(/\/.* is defined here$/, "")
end
end
end
end
Hi
I'm using deprecation-toolkit to capture ruby 2.7 warnings in our codebase. We'd disabled them earlier but want to enable again.
I recorded warnings using CIRecordHelper but I've hit a issue where the ruby code and gem paths in warnings are different on CI and developer environment. How do I handle this?
On local,
On CI,
Does this mean that a developer can not record a new warning locally? How do I handle this?