Skip to content

Commit

Permalink
Cleanup.
Browse files Browse the repository at this point in the history
  • Loading branch information
eerimoq committed May 10, 2019
1 parent 399b741 commit 09ee771
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 17 deletions.
4 changes: 0 additions & 4 deletions mqttools/broker.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
import asyncio
import bitstruct
import logging
import binascii
from collections import defaultdict

from .common import ControlPacketType
from .common import DisconnectReasonCode
from .common import PropertyIds
from .common import MalformedPacketError
from .common import PayloadReader
from .common import control_packet_type_to_string
from .common import unpack_packet_type
from .common import unpack_connect
from .common import pack_connack
from .common import pack_publish
Expand Down
4 changes: 0 additions & 4 deletions mqttools/client.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import os
import logging
import asyncio
import enum
import binascii
import uuid
import bitstruct

Expand All @@ -11,8 +9,6 @@
from .common import PropertyIds
from .common import DisconnectReasonCode
from .common import QoS
from .common import control_packet_type_to_string
from .common import unpack_packet_type
from .common import pack_connect
from .common import unpack_connack
from .common import pack_disconnect
Expand Down
9 changes: 0 additions & 9 deletions mqttools/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,15 +212,6 @@ def is_data_available(self):
return at_end


def control_packet_type_to_string(control_packet_type):
try:
name = ControlPacketType(control_packet_type).name
except ValueError:
name = 'UNKNOWN'

return f'{name}({control_packet_type})'


def pack_string(data):
data = data.encode('utf-8')
packed = struct.pack('>H', len(data))
Expand Down

0 comments on commit 09ee771

Please sign in to comment.