-
Notifications
You must be signed in to change notification settings - Fork 530
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
Fix unused variables: flake8 --select=F841 #623
Conversation
82030fe
to
fe3dfdb
Compare
fe3dfdb
to
92b7e37
Compare
@@ -77,7 +77,7 @@ def fragment(self, message, fragment_size, mid=None): | |||
if message_length <= fragment_size: | |||
return [message] | |||
|
|||
msg_id = message.get("id", None) |
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 suggest just deleting this line entirely
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.
Done.
@@ -70,7 +70,7 @@ def stopProtocol(self): | |||
rospy.loginfo("Client disconnected. %d clients total.", cls.clients_connected) | |||
|
|||
def send_message(self, message): | |||
binary = isinstance(message, bson.BSON) |
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.
delete
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.
Done.
d8e3765
to
ea58349
Compare
@@ -35,7 +35,7 @@ | |||
|
|||
def calculate_service_response(request): | |||
request_object = json.loads(request) # parse string for service request | |||
args = request_object["args"] # get parameter field (args) |
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 think since this is a test this whole block of commented code (line 38-45) seems to be dead, we can delete it
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.
actually, maybe leave it there. I'm not sure if the test is being used. someone has been making PRs to fix these tests so maybe it is helpful for now.
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!
Fix
five of thesix flake8 issues related to variables that are assigned to but then not used.This PR does not fix the following issue where theNOTE: Fixed in second commit.--unregister_timeout
command line option should probably be removed,