-
Notifications
You must be signed in to change notification settings - Fork 57
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
Resolve pylint benchmarks #178
Resolve pylint benchmarks #178
Conversation
Codecov Report
@@ Coverage Diff @@
## master #178 +/- ##
==========================================
+ Coverage 73.75% 74.10% +0.35%
==========================================
Files 61 61
Lines 3124 3167 +43
Branches 409 409
==========================================
+ Hits 2304 2347 +43
Misses 659 659
Partials 161 161
Continue to review full report at Codecov.
|
benchmarks/distribution.py
Outdated
def setup(self, dist, property): | ||
def setup(self, dist, method): | ||
# pylint: disable=missing-function-docstring,attribute-defined-outside-init | ||
# pylint: disable=unused-argument |
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.
# pylint: disable=unused-argument
# pylint: disable=missing-function-docstring
will appear in almost every benchmark and should if possible be ignored for all benchmarks.
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.
The docstring warning makes sense to be ignored globally IMO (the docstrings seem to be super repetitive anyway: "Time method xyz", "Benchmark memory usage of xyz". The unused-argument
I am more hesitant about...
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.
I put the ignore for unused-argument back into the tox file. Any idea where we can best document that this is not one of the "we have not resolved this yet" ignores but a "final" ignore? I put a comment into the tox ini file, but if you have a better idea please share.
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.
Maybe @nathanaelbosch knows a way to ignore specific warnings in a certain folder, however judging from StackOverflow one can only achieve this by having a .pylintrc
file in benchmarks
and then having two pylint
statements (which we already have anyway).
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.
@marvinpfoertner also looked into it and, if I'm not mistaken, came to the conclusion that it's unfortunately not possible to have configs on a per-directory basis.
In general I'm definitely open for ideas to move these exceptions out of the tox.ini
, since the current way does not feel ideal.
…mer/probnum into resolve_pylint_benchmarks
I did what I claimed I will never do and touch linear solver code... Now the benchmark directory is pylint-clean. Mostly, this amounted to adding some pylint-discard messages but I also changed some code. Nothing major IMO. Everything still benchmarks and I hope the changes are not too opinionated. If I misunderstood something, @JonathanWenger please judge.