-
Notifications
You must be signed in to change notification settings - Fork 573
Code quality #1773
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
base: v0.6
Are you sure you want to change the base?
Code quality #1773
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -21,7 +21,7 @@ class UDPSocket(BMProto): # pylint: disable=too-many-instance-attributes | |
port = 8444 | ||
|
||
def __init__(self, host=None, sock=None, announcing=False): | ||
# pylint: disable=bad-super-call | ||
# pylint: disable=bad-super-call, access-member-before-definition | ||
super(BMProto, self).__init__(sock=sock) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. super(UDPSocket, self).__init__(sock=sock) ? |
||
self.verackReceived = True | ||
self.verackSent = True | ||
|
@@ -97,22 +97,30 @@ def bm_command_addr(self): | |
time.time() | ||
return True | ||
|
||
# override the protocol do ignore the following commands on UDP | ||
# we do this mainly for security reasons | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is more of inheritance flow. Maybe There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Perhaps. |
||
def bm_command_portcheck(self): | ||
# pylint: disable=no-self-use | ||
return True | ||
|
||
def bm_command_ping(self): | ||
# pylint: disable=no-self-use | ||
return True | ||
|
||
def bm_command_pong(self): | ||
# pylint: disable=no-self-use | ||
return True | ||
|
||
def bm_command_verack(self): | ||
# pylint: disable=no-self-use | ||
return True | ||
|
||
def bm_command_version(self): | ||
# pylint: disable=no-self-use | ||
return True | ||
|
||
def handle_connect(self): | ||
# pylint: disable=no-self-use | ||
return | ||
|
||
def writable(self): | ||
|
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.
This is a bug: pylint-dev/pylint#2315
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 linked bug has been fixed. The ignore shouldn't be needed anymore.