-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
pylint pre-commit #48759
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
pylint pre-commit #48759
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.
thanks for working on this
I've left a few comments, but there's also still a few lint errors
************* Module pandas.tests.frame.methods.test_rename
pandas/tests/frame/methods/test_rename.py:339:12: E1124: Argument 'mapper' passed by position and keyword in method call (redundant-keyword-arg)
************* Module pandas.tests.window.test_groupby
pandas/tests/window/test_groupby.py:1082:8: E0102: function already defined line 1067 (function-redefined)
************* Module pandas.tests.io.pytables.test_append
pandas/tests/io/pytables/test_append.py:440:8: E0102: function already defined line 364 (function-redefined)
************* Module pandas.tests.extension.decimal.test_decimal
pandas/tests/extension/decimal/test_decimal.py:287:4: E0213: Method should have "self" as first argument (no-self-argument)
************* Module doc.make
doc/make.py:87:22: E0602: Undefined variable 'pandas' (undefined-variable)
************* Module pandas.tests.io.test_gcs
pandas/tests/io/test_gcs.py:36:8: E0211: Method has no argument (no-method-argument)
************* Module pandas.tests.groupby.test_groupby
pandas/tests/groupby/test_groupby.py:140:4: E0102: function already defined line 124 (function-redefined)
pandas/tests/groupby/test_groupby.py:172:4: E0102: function already defined line 165 (function-redefined)
pandas/tests/groupby/test_groupby.py:182:4: E0102: function already defined line 165 (function-redefined)
pandas/tests/groupby/test_groupby.py:193:4: E0102: function already defined line 165 (function-redefined)
pandas/tests/groupby/test_groupby.py:204:4: E0102: function already defined line 165 (function-redefined)
************* Module pandas.core.internals.blocks
pandas/core/internals/blocks.py:1984:12: E0704: The raise statement is not inside an except clause (misplaced-bare-raise)
************* Module pandas.tests.io.test_html
pandas/tests/io/test_html.py:1143:8: E1124: Argument 'flavor' passed by position and keyword in function call (redundant-keyword-arg)
pandas/tests/io/test_html.py:1281:12: E0301: __iter__ returns non-iterator (non-iterator-returned)
************* Module pandas.io.clipboard
pandas/io/clipboard/__init__.py:131:17: E0602: Undefined variable 'Foundation' (undefined-variable)
pandas/io/clipboard/__init__.py:132:44: E0602: Undefined variable 'Foundation' (undefined-variable)
pandas/io/clipboard/__init__.py:133:16: E0602: Undefined variable 'AppKit' (undefined-variable)
pandas/io/clipboard/__init__.py:134:35: E0602: Undefined variable 'AppKit' (undefined-variable)
pandas/io/clipboard/__init__.py:135:40: E0602: Undefined variable 'AppKit' (undefined-variable)
pandas/io/clipboard/__init__.py:139:16: E0602: Undefined variable 'AppKit' (undefined-variable)
pandas/io/clipboard/__init__.py:140:39: E0602: Undefined variable 'AppKit' (undefined-variable)
************* Module pandas.tests.scalar.period.test_period
pandas/tests/scalar/period/test_period.py:843:4: E0213: Method should have "self" as first argument (no-self-argument)
************* Module pandas.tests.resample.test_resampler_grouper
pandas/tests/resample/test_resampler_grouper.py:83:4: E0102: function already defined line 68 (function-redefined)
pandas/tests/resample/test_resampler_grouper.py:266:4: E0102: function already defined line 260 (function-redefined)
************* Module pandas.core.arrays.base
pandas/core/arrays/base.py:96:4: E0239: Inheriting "'ExtensionArray'", which is not a class. (inherit-non-class)
************* Module pandas.tests.arrays.datetimes.test_constructors
pandas/tests/arrays/datetimes/test_constructors.py:23:26: E1121: Too many positional arguments for method call (too-many-function-args)
************* Module pandas.tests.io.test_sql
pandas/tests/io/test_sql.py:1609:4: E0213: Method should have "self" as first argument (no-self-argument)
************* Module pandas.core.indexes.base
pandas/core/indexes/base.py:1144:23: E1121: Too many positional arguments for method call (too-many-function-args)
pandas/core/indexes/base.py:5126:19: E1121: Too many positional arguments for method call (too-many-function-args)
pandas/core/indexes/base.py:6478:19: E1121: Too many positional arguments for method call (too-many-function-args)
************* Module pandas.tests.arrays.timedeltas.test_constructors
pandas/tests/arrays/timedeltas/test_constructors.py:14:27: E1121: Too many positional arguments for method call (too-many-function-args)
************* Module pandas.tests.groupby.aggregate.test_aggregate
pandas/tests/groupby/aggregate/test_aggregate.py:297:4: E0102: function already defined line 284 (function-redefined)
************* Module pandas.tests.frame.methods.test_assign
pandas/tests/frame/methods/test_assign.py:70:12: E1121: Too many positional arguments for method call (too-many-function-args)
-----------------------------------
Your code has been rated at 9.99/10
I guess we can organize a sprint for beginners if there are many easy things to fix to make pylint happy. |
I have updated the request with the changes you have suggested, I'll start working on the lint errors. |
Have fixed on raise function, however, pylint passes locally rather than on CI, due to the inline disables I have added in some locations. |
looks like you just need to run the other checks as well, |
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.
Sorry for the probably silly question, but seem like we're adding pylint, but we aren't fixing any error because of it, only adding marks to disable to validation in some places. Are we planning to fix the checks being disabled in this PR later, or how is this useful? |
Yeah I think they could gradually enabled in sprints - this is at least gives us something start with |
* pylint pre-commit integration * Requested Changes * missing syntax * pylint passed * CI Passed * Cont * fixup Co-authored-by: Marco Edward Gorelli <[email protected]> Co-authored-by: MarcoGorelli <>
Added pylint to CI. Disabled most messages due to the sheer amount of warnings and changes that would need to be fixed in other PR.
@MarcoGorelli