Skip to content

Commit 98cdfed

Browse files
Minor improvement for Inventory.py (#701)
Update service interface `InventoryService` to inherit from ABC, as `rpc.Service` expects. (This is an improvement for type checker; it doesn't fix any runtime bug)
1 parent 050ae4b commit 98cdfed

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

examples/connext_dds/remote_procedure_call/py/Inventory.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
# damages arising out of the use or inability to use the software.
1010
#
1111

12+
from abc import ABC
1213
from dataclasses import field
1314
from typing import Sequence
1415
import rti.idl as idl
@@ -32,7 +33,7 @@ class UnknownItemError(Exception):
3233

3334

3435
@rpc.service
35-
class InventoryService:
36+
class InventoryService(ABC):
3637
@rpc.operation
3738
def get_inventory(self) -> InventoryContents:
3839
"""Get the current inventory inventory"""

0 commit comments

Comments
 (0)