-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
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
How to suppress parser/current warnings? #1819
Comments
You can't. It comes from the So many people have complained about this message that I'm starting to think it's more trouble that it's worth. |
I think it would made sense if it was displayed with |
As I said - it's not in RuboCop - we can suppress the output, but I don't want to do this, as we might end up suppressing something useful. |
2.1.2 and 2.1.6 genuinely differ in syntax. If you want to complain to someone, complain to the Ruby MRI authors, who consider these changes between patchlevels acceptable. I will not change |
Err... Okay. So how do I force Rubocop to not complaint about that? |
Run Rubocop as, for example, |
Keep in mind this will kill all the warnings, not just this one. |
Thanks @whitequark I just deleted the warnings. |
@whitequark if I can get some kind of unofficial guarantee that the Ruby core team won't break syntax in patch releases going forward, can we remove the warning? |
@ioquatix I'm not sure why you mean by "unofficial". If the Ruby core team publicly commits to not changing syntax in patch releases (which will doubtlessly benefit the entire ecosystem) I am of course fine with removing the warning, since there would be no reason to have it anymore. |
@whitequark I don't know what's possible yet, and I don't know at what level we could make the guarantee, ideally it would never happen, but I need to investigate further, e.g. why it happened in the past. I guess I'm just looking at options to try and help mitigate the need for the warning. |
@ioquatix I think that is an excellent initiative and I look forward to your results. |
For anyone else coming here looking for an easy solution without updating their Ruby version. Just use the # config/initializers/warning_ignores.rb
### https://github.com/jeremyevans/ruby-warning
Warning.ignore(/warning: parser/) |
If I'm not mistaken, you should simply always use the latest |
@westonganger This allows to silence the warning starting rails server, etc. But not when just running rubocop.. or I'm missing something? |
When I run rubocop I get something like this on top:
Is there a way to suppress that? It breaks Syntastic for Vim.
I can't change ruby version. There are other people working on this project and the version is locked.
The text was updated successfully, but these errors were encountered: