-
Notifications
You must be signed in to change notification settings - Fork 161
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
[INFRA] Add .lgtm.yml file for better usage of LGTM CI tool #865
[INFRA] Add .lgtm.yml file for better usage of LGTM CI tool #865
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fine with me :-) the additional lgtm.yml
file is a bit ugly in the repo, but I can live with it. Thanks!
The alternative to |
044e673
to
c13e290
Compare
I agree with you. the alternative that I see is to not care about the LGTM tool reports. Maybe someone else can offer their opinion here - can you tag some people you'd like to chime in? |
The alternative is OK with me. It's just that a small part of the LGTM alerts is actually useful, so it would be useful to be able to disable (some of) the false positives and focus on real issues. |
That said, I'm not certain any more that The Will have to look into it in more detail. |
Also, file can be renamed to a hidden file |
Ignoring false positive is the kind of implicit knowledge that might confuse new users / maintainers: it also leads experienced users / maintainers to not spot new true positive when they show up. So if we could avoid this it would be great, no? |
The alternative would be to document the places where we suppress false positives. Like this: import foobar # lgtm[py/unused-import] However, that means adding multiple suppression comments for multiple linters: import foobar # noqa: F401 # pylint: disable=unused-import # lgtm[py/unused-import] |
The other alternative is to keep false positives as is, of course. But for projects with dozens of alerts, it's not easy to spot real positives in a haystack of false positives. There's no tool to classify them as real and false positives in LGTM. |
c13e290
to
68890a4
Compare
It actually does work. I was just confused by the existence of two alerts with very similar names, see pydicom/pydicom@2ded1d2:
|
68890a4
to
80d2e13
Compare
Ok great, is it possible to include an explanatory comment in the I think after that we could merge, given Remi's opinion as well. |
d4c7705
to
49fbdac
Compare
There's a comment that points to the documentation of the LGTM |
49fbdac
to
1c0fcb1
Compare
Previous commit bb6065a from bids-standard#853 does not work around the LGTM alert. We attempt to silence the LGTM alert using an lgtm.yml file, and use standard Flake8 noqa suppression comments to document the issue at hand.
1c0fcb1
to
33067a6
Compare
Thanks @DimitriPapadopoulos |
Because Semmle has joined GitHub, LGTM.com will be deprecated and replaced by GitHub code scanning. The next step for LGTM.com: GitHub code scanning! As far as I can understand, in simple cases such as this one, automated pull requests will be created to help us migrate:
|
Previous commit bb6065a from #853 does not work around the LGTM alert.
We attempt to silence the LGTM alert using an
lgtm.yml
file, and use standard Flake8noqa
suppression comments to document the issue at hand.Fixes #864.
Links: