-
Notifications
You must be signed in to change notification settings - Fork 3k
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} Fix arguments-renamed #30345
Conversation
️✔️AzureCLI-FullTest
|
️✔️AzureCLI-BreakingChangeTest
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
arguments-renamed
pylint errorfc328e5
to
e3d23b3
Compare
@@ -60,22 +60,22 @@ class JsonBytearrayEncoder(json.JSONEncoder): | |||
DATE_FORMAT = "%Y-%m-%d" | |||
TIME_FORMAT = "%H:%M:%S" | |||
|
|||
def default(self, obj): # pylint: disable=E0202,W0221 |
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.
W0221
is arguments-differ
: https://pylint.readthedocs.io/en/latest/user_guide/messages/warning/arguments-differ.html
@@ -365,8 +365,7 @@ def _ignore_if_not_registered(self, dest): | |||
if not match: | |||
super().argument(dest, arg_type=ignore_type) | |||
|
|||
# pylint: disable=arguments-differ |
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.
Putting # pylint: disable=arguments-differ
here is incorrect as it disables all arguments-differ
s below, including ignore()
, not only for argument()
.
e3d23b3
to
034b615
Compare
034b615
to
3f1c8bc
Compare
def ignore(self, *args): # pylint: disable=arguments-differ | ||
# It is expected that this method's signature differs from its base class, as it can be used to ignore | ||
# multiple arguments in one method call. |
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.
Some examples:
c.ignore('source_virtual_machine', 'os_blob_uri', 'os_disk', 'os_snapshot', 'data_blob_uris', 'data_disks', 'data_snapshots') |
c.ignore('ignore_this', 'ignore_that') |
Description
Finish the unfinished tasks of #20192
Fix
arguments-renamed
pylint error.