Skip to content

Commit b2a5c99

Browse files
committed
Fixed formatting (again)
1 parent 69d65a2 commit b2a5c99

File tree

3 files changed

+17
-5
lines changed

3 files changed

+17
-5
lines changed

rosbridge_library/src/rosbridge_library/capabilities/advertise.py

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,12 @@ def unregister(self) -> None:
7575
manager.unregister(self.client_id, self.topic)
7676

7777
def register_advertisement(
78-
self, msg_type: str, adv_id: str | None = None, latch: bool = False, queue_size: int = 100, qos: QoSProfile | None = None
78+
self,
79+
msg_type: str,
80+
adv_id: str | None = None,
81+
latch: bool = False,
82+
queue_size: int = 100,
83+
qos: QoSProfile | None = None
7984
) -> None:
8085
# Register with the publisher manager, propagating any exception
8186
manager.register(
@@ -139,7 +144,12 @@ def advertise(self, message: dict[str, Any]) -> None:
139144
liveliness=message.get("liveliness_policy", LivelinessPolicy.SYSTEM_DEFAULT),
140145
)
141146

142-
if message.keys() & {"durability_policy", "history_policy", "liveliness_policy", "reliability_policy"}:
147+
if message.keys() & {
148+
"durability_policy",
149+
"history_policy",
150+
"liveliness_policy",
151+
"reliability_policy"
152+
}:
143153
qos = None
144154

145155
if self.topics_glob is not None:
@@ -168,7 +178,9 @@ def advertise(self, message: dict[str, Any]) -> None:
168178
self._registrations[topic] = Registration(client_id, topic, self.protocol.node_handle)
169179

170180
# Register, propagating any exceptions
171-
self._registrations[topic].register_advertisement(msg_type=msg_type, adv_id=aid, latch=latch, queue_size=queue_size, qos=qos)
181+
self._registrations[topic].register_advertisement(
182+
msg_type=msg_type, adv_id=aid, latch=latch, queue_size=queue_size, qos=qos
183+
)
172184

173185
def unadvertise(self, message: dict[str, Any]) -> None:
174186
# Pull out the ID

rosbridge_library/src/rosbridge_library/capabilities/subscribe.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ class Subscribe(Capability):
255255
(False, "fragment_size", int),
256256
(False, "queue_length", int),
257257
(False, "compression", str),
258-
(False, "qos", QoSProfile)
258+
(False, "qos", QoSProfile),
259259
)
260260
unsubscribe_msg_fields = ((True, "topic", str),)
261261

rosbridge_library/src/rosbridge_library/internal/publishers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ def __init__(
6767
msg_type: str | None = None,
6868
latched_client_id: str | None = None,
6969
queue_size: int = 100,
70-
qos : QoSProfile | None = None,
70+
qos: QoSProfile | None = None,
7171
) -> None:
7272
"""
7373
Register a publisher on the specified topic.

0 commit comments

Comments
 (0)