]> www.average.org Git - loctrkd.git/blobdiff - gps303/collector.py
Multiprotocol support in zmq messages and storage
[loctrkd.git] / gps303 / collector.py
index 8adaeb36fa4671b7f60f7409ecec45e320806215..cb45d8144bb9ec132265f8bed3d18881b6dab6de 100644 (file)
@@ -58,7 +58,7 @@ class ProtoModule:
         ...
 
     @staticmethod
-    def proto_of_message(packet: bytes) -> int:
+    def proto_of_message(packet: bytes) -> str:
         ...
 
     @staticmethod
@@ -87,7 +87,9 @@ class Client:
         else:
             rest = b""
         if rest:
-            log.warning("%d bytes in buffer on close: %s", len(rest), rest)
+            log.warning(
+                "%d bytes in buffer on close: %s", len(rest), rest[:64].hex()
+            )
 
     def recv(self) -> Optional[List[Tuple[float, Tuple[str, int], bytes]]]:
         """Read from the socket and parse complete messages"""