u9n / dlms-cosem

A Python library for DLMS/COSEM
Other
80 stars 41 forks source link

WrapperHeader is not defined #98

Open telemetrix opened 3 months ago

telemetrix commented 3 months ago

Pycharm, python 3.12, getting an error with WrapperHeader class.

Traceback (most recent call last):

header = WrapperHeader(
         ^^^^^^^^^^^^^

NameError: name 'WrapperHeader' is not defined

telemetrix commented 2 months ago

I found an issue in the newest version of the library; there is a lack of WrapperHeader declaration in the io.py file. It can be resolved in the best way like this:

from dlms_cosem.protocol.wrappers import WrapperHeader, WrapperProtocolDataUnit