Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Override Ruby Warning.warn #3

Closed
Edouard-chin opened this issue Mar 21, 2018 · 2 comments
Closed

Override Ruby Warning.warn #3

Edouard-chin opened this issue Mar 21, 2018 · 2 comments

Comments

@Edouard-chin
Copy link
Contributor

A lot of gems (resque-scheduler, minitest, dogapi ...) doesn't use ActiveSupport::Deprecation and instead just trigger a deprecation using Kernel.warn. We have no way on our side to keep track of these deprecations.

My idea was to implement something similar to the ruby-warning gem and catch any warning that might be deprecations (most of the time the warning is prefixed with the [DEPRECATION] tag) and monkey patch the Warning module to instead use ActiveSupport::Deprecation.warn whenever a deprecation is triggered.

WDYT @rafaelfranca @wvanbergen

@wvanbergen
Copy link

I think that makes sense. We probably want to make that opt in though.

@Edouard-chin
Copy link
Contributor Author

Sounds good, planning to implement that and polish this gem sometimes before June 15th where it's planned to be opensource it as well as talk about it in the engineering blog

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants