-
Notifications
You must be signed in to change notification settings - Fork 19
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
Remove monkey-patching #231
Comments
What is the reason of monkey-patching the class we don't own? (i.e. the point of having this file, since it is not needed by Rails) |
It logs all the flash messages to syslog/standard logger |
I was actually wondering why that code is present there. If nobody knows the reason, I am about to remove first 3. The latter requires code base change. |
They all give some extra logging, i wouldnt remove them just yet. |
First of all, I am trying to say that monkey patching is very dangerous. There should be unbeatable argument to do it, and currently there is no. |
Example of real-life WTF http://prntscr.com/f1foaz |
Nothing to test. Should not affect any production code. |
@teadur Is this good by you? |
@artur-beljajev why is http://prntscr.com/f1foaz a problem ? |
It is unnecessary. |
I think its far easier to use valid? then this long reference to get the error, what is the actual problem with it, does it brake anything ? |
Why do you need that error at all? |
Its really convient when you want to know why some objects validation failed, sadly you cant check object state from any UI you need to use the actual rails console for it. |
This ticket cannot be closed until #231 (comment) remains valid. It creates unnecessary noise with no benefit. @teadur |
@vohmar Any reason why this issue has been closed? The code is still there
|
I might also set |
The information in question may be obtained using |
That monkey-patch can lead to problems with Rails update in the future. |
I must have misunderstood that work with config/initializers/eis_custom_active_model.rb, eis_custom_active_record.rb and eis_custom_flash.rb is done. |
How is that logging in the latter is useful for us? |
It's useful when you look at logs, if you think its so big problem and brakes everything remove it. |
in production |
config/initializers/eis_custom_active_model.rb
config/initializers/eis_custom_active_record.rb
config/initializers/eis_custom_flash.rb
The text was updated successfully, but these errors were encountered: