laforge has submitted this change. ( https://gerrit.osmocom.org/c/python/pyosmocom/+/41384?usp=email )
Change subject: Fix lint errors: don't use star imports ...................................................................... Fix lint errors: don't use star imports tests/test_tlv.py:21:1: F403 `from osmocom.tlv import *` used; unable to detect undefined names | 19 | import unittest 20 | from construct import Int8ub, GreedyBytes 21 | from osmocom.tlv import * | ^^^^^^^^^^^^^^^^^^^^^^^^^ F403 22 | from osmocom.utils import h2b Change-Id: I0ca76a40d47f72635682de9303ff73e9b2197266 --- M src/osmocom/gsmtap.py M tests/test_construct.py M tests/test_gsup.py M tests/test_tlv.py M tests/test_utils.py 5 files changed, 9 insertions(+), 5 deletions(-) Approvals: laforge: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/osmocom/gsmtap.py b/src/osmocom/gsmtap.py index 60d7ee4..3474396 100644 --- a/src/osmocom/gsmtap.py +++ b/src/osmocom/gsmtap.py @@ -25,7 +25,7 @@ import socket from construct import Int8ub, Int8sb, Int32ub, BitStruct, Enum, GreedyBytes, Struct, Switch from construct import this, PaddedString, Flag, BitsInteger, Bytes -from osmocom.construct import * +from osmocom.construct import parse_construct # The root definition of GSMTAP can be found at # https://cgit.osmocom.org/cgit/libosmocore/tree/include/osmocom/core/gsmtap.h diff --git a/tests/test_construct.py b/tests/test_construct.py index 94ae71f..195732d 100755 --- a/tests/test_construct.py +++ b/tests/test_construct.py @@ -2,7 +2,8 @@ import unittest from osmocom.utils import b2h, h2b -from osmocom.construct import * +from osmocom.construct import Asn1DerInteger, Bytes, DnsAdapter, GreedyInteger, GreedyBytes, PlmnAdapter +from osmocom.construct import StripHeaderAdapter, StripTrailerAdapter, Ucs2Adapter, filter_dict # pylint: disable=no-name-in-module from construct import FlagsEnum diff --git a/tests/test_gsup.py b/tests/test_gsup.py index db3f29e..c6f2429 100755 --- a/tests/test_gsup.py +++ b/tests/test_gsup.py @@ -4,7 +4,7 @@ from pprint import pprint as pp from osmocom.utils import b2h, h2b -from osmocom.gsup.message import * +from osmocom.gsup.message import GsupMessage class Test_GSUP(unittest.TestCase): diff --git a/tests/test_tlv.py b/tests/test_tlv.py index 3af1e07..6d33492 100755 --- a/tests/test_tlv.py +++ b/tests/test_tlv.py @@ -18,7 +18,10 @@ import unittest from construct import Int8ub, GreedyBytes -from osmocom.tlv import * +from osmocom.tlv import COMPACT_TLV_IE, IE, TLV_IE_Collection, Transcodable, flatten_dict_lists, camel_to_snake +from osmocom.tlv import bertlv_encode_len, bertlv_parse_len, bertlv_parse_one, bertlv_parse_tag +from osmocom.tlv import comprehensiontlv_encode_tag, comprehensiontlv_parse_tag +from osmocom.tlv import dgi_encode_len, dgi_parse_len from osmocom.utils import h2b class TestBerTlv(unittest.TestCase): diff --git a/tests/test_utils.py b/tests/test_utils.py index 0f22e35..1b80011 100755 --- a/tests/test_utils.py +++ b/tests/test_utils.py @@ -18,7 +18,7 @@ import unittest -from osmocom.utils import * +from osmocom.utils import hexstr, int_bytes_required class TestHexstr(unittest.TestCase): def test_cmp(self): -- To view, visit https://gerrit.osmocom.org/c/python/pyosmocom/+/41384?usp=email To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email Gerrit-MessageType: merged Gerrit-Project: python/pyosmocom Gerrit-Branch: master Gerrit-Change-Id: I0ca76a40d47f72635682de9303ff73e9b2197266 Gerrit-Change-Number: 41384 Gerrit-PatchSet: 3 Gerrit-Owner: osmith <[email protected]> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: fixeria <[email protected]> Gerrit-Reviewer: laforge <[email protected]> Gerrit-Reviewer: pespin <[email protected]>
