Skip to content

Commit c308374

Browse files
authored
Update pre-commit and fix issues (#954)
1 parent 55b8fa3 commit c308374

File tree

8 files changed

+13
-14
lines changed

8 files changed

+13
-14
lines changed

.pre-commit-config.yaml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# See https://pre-commit.com for more information
22
repos:
33
- repo: https://github.com/pre-commit/pre-commit-hooks
4-
rev: v4.0.1
4+
rev: v4.6.0
55
hooks:
66
- id: check-added-large-files
77
- id: check-case-conflict
@@ -16,27 +16,27 @@ repos:
1616
- id: trailing-whitespace
1717

1818
- repo: https://github.com/pycqa/isort
19-
rev: 5.12.0
19+
rev: 5.13.2
2020
hooks:
2121
- id: isort
2222

2323
- repo: https://github.com/psf/black
24-
rev: 22.3.0
24+
rev: 24.8.0
2525
hooks:
2626
- id: black
2727

2828
- repo: https://github.com/PyCQA/flake8
29-
rev: 3.9.2
29+
rev: 7.1.1
3030
hooks:
3131
- id: flake8
3232

3333
- repo: https://github.com/PyCQA/bandit
34-
rev: 1.7.0
34+
rev: 1.7.10
3535
hooks:
3636
- id: bandit
3737
args: ["--skip", "B101,B110,B311"]
3838

3939
- repo: https://github.com/codespell-project/codespell
40-
rev: v2.1.0
40+
rev: v2.3.0
4141
hooks:
4242
- id: codespell

rosbridge_library/src/rosbridge_library/capabilities/advertise_action.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ async def execute_callback(self, goal: Any) -> Any:
7777
# generate a unique ID
7878
goal_id = f"action_goal:{self.action_name}:{self.next_id()}"
7979

80-
def done_callback(fut: rclpy.task.Future()) -> None:
80+
def done_callback(fut: rclpy.task.Future) -> None:
8181
if fut.cancelled():
8282
goal.abort()
8383
self.protocol.log("info", f"Aborted goal {goal_id}")

rosbridge_library/src/rosbridge_library/capabilities/advertise_service.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def next_id(self):
3131

3232
async def handle_request(self, req, res):
3333
# generate a unique ID
34-
request_id = f"service_request:{self.service_name }:{self.next_id()}"
34+
request_id = f"service_request:{self.service_name}:{self.next_id()}"
3535

3636
future = rclpy.task.Future()
3737
self.request_futures[request_id] = future

rosbridge_library/src/rosbridge_library/capability.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ def basic_type_check(self, msg, types_info):
7979
"""Performs basic typechecking on fields in msg.
8080
8181
Keyword arguments:
82-
msg -- a message, deserialized into a dictoinary
82+
msg -- a message, deserialized into a dictionary
8383
types_info -- a list of tuples (mandatory, fieldname, fieldtype) where
8484
mandatory - boolean, is the field mandatory
8585
fieldname - the name of the field in the message

rosbridge_library/src/rosbridge_library/protocol.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,6 @@ def serialize(self, msg, cid=None):
311311
return None
312312

313313
def deserialize(self, msg, cid=None):
314-
315314
"""Turns the wire-level representation into a dictionary of values
316315
317316
Default behaviour assumes JSON. Override to use a different container.

rosbridge_library/test/experimental/complex_srv+tcp/test_non-ros_service_client_complex-srv.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def request_service():
3535
"position": {"y": 0.0, "x": 0.0, "z": 0.0},
3636
"orientation": {"y": 0.0, "x": 0.0, "z": 0.0, "w": 0.0},
3737
}
38-
}
38+
},
3939
# "count" : request_byte_count # count is the parameter for send_bytes as defined in srv-file (always put into args field!)
4040
}
4141
service_request = json.dumps(service_request_object)

rosbridge_library/test/internal/publishers/test_multi_publisher.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ def test_publish(self):
109109
"""Make sure that publishing works"""
110110
topic = "/test_publish"
111111
msg_type = "std_msgs/String"
112-
msg = {"data": "why halo thar"}
112+
msg = {"data": "why hello there"}
113113

114114
received = {"msg": None}
115115

@@ -133,7 +133,7 @@ def test_publish_twice(self):
133133
"""Make sure that publishing works"""
134134
topic = "/test_publish_twice"
135135
msg_type = "std_msgs/String"
136-
msg = {"data": "why halo thar"}
136+
msg = {"data": "why hello there"}
137137

138138
received = {"msg": None}
139139

rosbridge_server/CHANGELOG.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -486,7 +486,7 @@ Changelog for package rosbridge_server
486486
* merging changes of groovy-devel into hydro-devel
487487
* Specific IP address binding using roslauch
488488
* added parameter lookup to rosbridge_tcp.py, modules where those are used, and default parameters to launch file; internal default-values still get used when launch-file does not provide them; internal defaults can be changed within rosbridge_tcp.py
489-
* increaing max_msg_length - still hardcoded
489+
* increasing max_msg_length - still hardcoded
490490
* preparing pull request for upstream..
491491
* cleanup: files, notes, some code
492492
* cleanup tcp-server

0 commit comments

Comments
 (0)