From: Eugene Crosser Date: Tue, 26 Apr 2022 18:34:49 +0000 (+0200) Subject: Remove deprecated functions X-Git-Tag: 0.01~37 X-Git-Url: http://www.average.org/gitweb/?a=commitdiff_plain;h=e3a66f35e7850bfbf507b0f50dcd6d365dc0afe4;hp=faa8ce9d87530105ec2ad2f4809a9ace581a2ad6;p=loctrkd.git Remove deprecated functions --- diff --git a/gps303.conf b/gps303.conf index bb7b6c7..7669381 100644 --- a/gps303.conf +++ b/gps303.conf @@ -4,10 +4,10 @@ publishurl = ipc:///tmp/collected listenurl = ipc:///tmp/responses [storage] -dbfn = gps303.sqlite +dbfn = /home/crosser/src/gps303/gps303.sqlite [opencellid] -dbfn = opencellid.sqlite +dbfn = /home/crosser/src/gps303/opencellid.sqlite [termconfig] statusIntervalMinutes = 25 diff --git a/gps303/common.py b/gps303/common.py index 6e4a2f3..09fb01f 100644 --- a/gps303/common.py +++ b/gps303/common.py @@ -3,6 +3,7 @@ from configparser import ConfigParser from getopt import getopt from logging import getLogger, StreamHandler, DEBUG, INFO +from logging.handlers import SysLogHandler from sys import argv, stderr, stdout CONF = "/etc/gps303.conf" diff --git a/gps303/gps303proto.py b/gps303/gps303proto.py index dcc335b..b0259a4 100755 --- a/gps303/gps303proto.py +++ b/gps303/gps303proto.py @@ -22,10 +22,8 @@ from struct import pack, unpack __all__ = ( "class_by_prefix", - "handle_packet", "inline_response", "make_object", - "make_response", "parse_message", "proto_by_name", "Dir", @@ -616,14 +614,3 @@ def parse_message(packet): adjust, ) return make_object(length, proto, payload) - - -def handle_packet(packet): # DEPRECATED - if len(packet) < 6 or packet[:2] != b"xx" or packet[-2:] != b"\r\n": - return UNKNOWN.from_packet(len(packet), packet) - return parse_message(packet[2:-2]) - - -def make_response(msg, **kwargs): # DEPRECATED - inframe = msg.response(**kwargs) - return None if inframe is None else b"xx" + inframe + b"\r\n"