Emphasize more magic imports in the network package

This commit is contained in:
Lee Miller 2023-01-04 01:29:05 +02:00
parent f6adb46ce6
commit b99670430f
Signed by untrusted user: lee.miller
GPG Key ID: 4F97A5EA88F4AB63
4 changed files with 15 additions and 10 deletions

View File

@ -3,13 +3,13 @@ Announce addresses as they are received from other hosts
"""
from six.moves import queue
# magic imports!
import state
from helper_random import randomshuffle
from protocol import assembleAddrMessage
from queues import addrQueue # FIXME: init with queue
from network.connectionpool import BMConnectionPool
from queues import addrQueue
from threads import StoppableThread

View File

@ -3,11 +3,12 @@ Announce myself (node address)
"""
import time
# magic imports!
import state
from bmconfigparser import config
from protocol import assembleAddrMessage
from network.connectionpool import BMConnectionPool
from node import Peer
from threads import StoppableThread

View File

@ -11,6 +11,7 @@ import struct
import time
from binascii import hexlify
# magic imports!
import addresses
import connectionpool
import knownnodes
@ -18,22 +19,24 @@ import protocol
import state
from bmconfigparser import config
from inventory import Inventory
from queues import invQueue, objectProcessorQueue, portCheckerQueue
from randomtrackingdict import RandomTrackingDict
from network.advanceddispatcher import AdvancedDispatcher
from network.bmobject import (
BMObject, BMObjectAlreadyHaveError, BMObjectExpiredError,
BMObjectInsufficientPOWError, BMObjectInvalidError,
BMObjectUnwantedStreamError
)
from network.constants import (
from network.dandelion import Dandelion
from network.proxy import ProxyError
from constants import (
ADDRESS_ALIVE, MAX_MESSAGE_SIZE, MAX_OBJECT_COUNT,
MAX_OBJECT_PAYLOAD_SIZE, MAX_TIME_OFFSET
)
from network.dandelion import Dandelion
from network.proxy import ProxyError
from node import Node, Peer
from objectracker import ObjectTracker, missingObjects
from queues import invQueue, objectProcessorQueue, portCheckerQueue
from randomtrackingdict import RandomTrackingDict
logger = logging.getLogger('default')

View File

@ -9,6 +9,7 @@ import random
import socket
import time
# magic imports!
import addresses
import helper_random
import l10n
@ -23,9 +24,9 @@ from tr import _translate
import asyncore_pollchoose as asyncore
import connectionpool
import knownnodes
from constants import MAX_OBJECT_COUNT
from network.advanceddispatcher import AdvancedDispatcher
from network.bmproto import BMProto
from network.constants import MAX_OBJECT_COUNT
from network.dandelion import Dandelion
from network.objectracker import ObjectTracker
from network.socks4a import Socks4aConnection