removed absolute imports back to relative due to serial.py importing from serial

This commit is contained in:
Nigel Dokter 2017-01-09 21:31:08 +01:00
parent 21334e5a0a
commit 759e0a0d92
5 changed files with 13 additions and 15 deletions

View File

@ -3,7 +3,7 @@ import asyncio
import logging
from functools import partial
from dsmr_parser.protocol import create_dsmr_reader, create_tcp_dsmr_reader
from .protocol import create_dsmr_reader, create_tcp_dsmr_reader
def console():

View File

@ -3,9 +3,9 @@ import re
from PyCRC.CRC16 import CRC16
from dsmr_parser.objects import MBusObject, MBusObjectV2_2, CosemObject
from dsmr_parser.exceptions import ParseError, InvalidChecksumError
from dsmr_parser.obis_references import GAS_METER_READING
from .objects import MBusObject, MBusObjectV2_2, CosemObject
from .exceptions import ParseError, InvalidChecksumError
from .obis_references import GAS_METER_READING
logger = logging.getLogger(__name__)

View File

@ -6,11 +6,10 @@ from functools import partial
from serial_asyncio import create_serial_connection
from dsmr_parser import telegram_specifications
from dsmr_parser.exceptions import ParseError
from dsmr_parser.parsers import TelegramParserV2_2, TelegramParserV4
from dsmr_parser.serial import (SERIAL_SETTINGS_V2_2, SERIAL_SETTINGS_V4,
TelegramBuffer)
from . import telegram_specifications
from .exceptions import ParseError
from .parsers import TelegramParserV2_2, TelegramParserV4
from .serial import (SERIAL_SETTINGS_V2_2, SERIAL_SETTINGS_V4, TelegramBuffer)
def create_dsmr_protocol(dsmr_version, telegram_callback, loop=None):

View File

@ -4,9 +4,8 @@ import re
import serial
import serial_asyncio
from dsmr_parser.exceptions import ParseError
from dsmr_parser.parsers import TelegramParser, TelegramParserV2_2, \
TelegramParserV4
from .exceptions import ParseError
from .parsers import TelegramParser, TelegramParserV2_2, TelegramParserV4
logger = logging.getLogger(__name__)

View File

@ -1,8 +1,8 @@
from decimal import Decimal
from dsmr_parser import obis_references as obis
from dsmr_parser.parsers import CosemParser, ValueParser, MBusParser
from dsmr_parser.value_types import timestamp
from . import obis_references as obis
from .parsers import CosemParser, ValueParser, MBusParser
from .value_types import timestamp
"""