Restyled by reorder-python-imports

This commit is contained in:
Restyled.io 2021-05-26 10:58:25 +00:00
parent cf92934c82
commit 40919edd60
12 changed files with 73 additions and 33 deletions

View File

@ -4,13 +4,16 @@ import concurrent.futures
import random
import socket
from zeroconf import ServiceBrowser, ServiceInfo, Zeroconf
from zeroconf import ServiceBrowser
from zeroconf import ServiceInfo
from zeroconf import Zeroconf
from librespot.common import Utils
from librespot.core import Session
from librespot.crypto import DiffieHellman
from librespot.proto import Connect_pb2 as Connect
from librespot.standard import Closeable, Runnable
from librespot.standard import Closeable
from librespot.standard import Runnable
class ZeroconfServer(Closeable):

View File

@ -10,7 +10,8 @@ from librespot.common import Utils
from librespot.core import Session
from librespot.core.PacketsReceiver import PacketsReceiver
from librespot.crypto import Packet
from librespot.standard import ByteArrayOutputStream, BytesInputStream
from librespot.standard import ByteArrayOutputStream
from librespot.standard import BytesInputStream
class AudioKeyManager(PacketsReceiver):

View File

@ -3,12 +3,15 @@ from __future__ import annotations
import logging
import typing
from librespot.audio import GeneralAudioStream, HaltListener, NormalizationData
from librespot.audio import GeneralAudioStream
from librespot.audio import HaltListener
from librespot.audio import NormalizationData
from librespot.audio.cdn import CdnFeedHelper
from librespot.audio.format import AudioQualityPicker
from librespot.common.Utils import Utils
from librespot.core import Session
from librespot.metadata import PlayableId, TrackId
from librespot.metadata import PlayableId
from librespot.metadata import TrackId
from librespot.proto import Metadata_pb2 as Metadata
from librespot.proto import StorageResolve_pb2 as StorageResolve

View File

@ -1,4 +1,8 @@
from librespot.audio import (AbsChunkedInputStream, AudioKeyManager,
GeneralAudioStream, GeneralWritableStream,
HaltListener, NormalizationData,
PlayableContentFeeder, StreamId)
from librespot.audio import AbsChunkedInputStream
from librespot.audio import AudioKeyManager
from librespot.audio import GeneralAudioStream
from librespot.audio import GeneralWritableStream
from librespot.audio import HaltListener
from librespot.audio import NormalizationData
from librespot.audio import PlayableContentFeeder
from librespot.audio import StreamId

View File

@ -5,8 +5,9 @@ import random
import time
import typing
from librespot.audio import (HaltListener, NormalizationData,
PlayableContentFeeder)
from librespot.audio import HaltListener
from librespot.audio import NormalizationData
from librespot.audio import PlayableContentFeeder
from librespot.common import Utils
from librespot.core import Session
from librespot.proto import Metadata_pb2 as Metadata

View File

@ -8,9 +8,12 @@ import time
import typing
import urllib.parse
from librespot.audio import GeneralAudioStream, GeneralWritableStream, StreamId
from librespot.audio import GeneralAudioStream
from librespot.audio import GeneralWritableStream
from librespot.audio import StreamId
from librespot.audio.AbsChunkedInputStream import AbsChunkedInputStream
from librespot.audio.decrypt import AesAudioDecrypt, NoopAudioDecrypt
from librespot.audio.decrypt import AesAudioDecrypt
from librespot.audio.decrypt import NoopAudioDecrypt
from librespot.audio.format import SuperAudioFormat
from librespot.audio.storage import ChannelManager
from librespot.common import Utils

View File

@ -8,10 +8,13 @@ import typing
from librespot.audio.storage import AudioFile
from librespot.common import Utils
from librespot.core import PacketsReceiver, Session
from librespot.core import PacketsReceiver
from librespot.core import Session
from librespot.crypto import Packet
from librespot.standard import (BytesInputStream, BytesOutputStream, Closeable,
Runnable)
from librespot.standard import BytesInputStream
from librespot.standard import BytesOutputStream
from librespot.standard import Closeable
from librespot.standard import Runnable
class ChannelManager(Closeable, PacketsReceiver.PacketsReceiver):

View File

@ -13,25 +13,35 @@ import typing
import defusedxml.ElementTree
import requests
from Crypto.Hash import HMAC, SHA1
from Crypto.Hash import HMAC
from Crypto.Hash import SHA1
from Crypto.PublicKey import RSA
from Crypto.Signature import PKCS1_v1_5
from librespot.audio import AudioKeyManager, PlayableContentFeeder
from librespot.audio import AudioKeyManager
from librespot.audio import PlayableContentFeeder
from librespot.audio.cdn import CdnManager
from librespot.audio.storage import ChannelManager
from librespot.cache import CacheManager
from librespot.common.Utils import Utils
from librespot.core import (ApResolver, EventService, SearchManager,
TokenProvider)
from librespot.crypto import CipherPair, DiffieHellman, Packet
from librespot.dealer import ApiClient, DealerClient
from librespot.mercury import MercuryClient, SubListener
from librespot.core import ApResolver
from librespot.core import EventService
from librespot.core import SearchManager
from librespot.core import TokenProvider
from librespot.crypto import CipherPair
from librespot.crypto import DiffieHellman
from librespot.crypto import Packet
from librespot.dealer import ApiClient
from librespot.dealer import DealerClient
from librespot.mercury import MercuryClient
from librespot.mercury import SubListener
from librespot.proto import Authentication_pb2 as Authentication
from librespot.proto import Connect_pb2 as Connect
from librespot.proto import Keyexchange_pb2 as Keyexchange
from librespot.proto.ExplicitContentPubsub_pb2 import UserAttributesUpdate
from librespot.standard import BytesInputStream, Closeable, Proxy
from librespot.standard import BytesInputStream
from librespot.standard import Closeable
from librespot.standard import Proxy
from librespot.Version import Version

View File

@ -4,7 +4,11 @@ import typing
import requests
from librespot.core.ApResolver import ApResolver
from librespot.metadata import AlbumId, ArtistId, EpisodeId, ShowId, TrackId
from librespot.metadata import AlbumId
from librespot.metadata import ArtistId
from librespot.metadata import EpisodeId
from librespot.metadata import ShowId
from librespot.metadata import TrackId
from librespot.proto import Connect_pb2 as Connect
from librespot.proto import Metadata_pb2 as Metadata
from librespot.standard import Closeable

View File

@ -7,13 +7,17 @@ import threading
import typing
from librespot.common import Utils
from librespot.core import PacketsReceiver, Session
from librespot.core import PacketsReceiver
from librespot.core import Session
from librespot.crypto import Packet
from librespot.mercury import (JsonMercuryRequest, RawMercuryRequest,
SubListener)
from librespot.mercury import JsonMercuryRequest
from librespot.mercury import RawMercuryRequest
from librespot.mercury import SubListener
from librespot.proto import Mercury_pb2 as Mercury
from librespot.proto import Pubsub_pb2 as Pubsub
from librespot.standard import BytesInputStream, BytesOutputStream, Closeable
from librespot.standard import BytesInputStream
from librespot.standard import BytesOutputStream
from librespot.standard import Closeable
class MercuryClient(PacketsReceiver.PacketsReceiver, Closeable):

View File

@ -2,7 +2,8 @@ from __future__ import annotations
import re
from librespot.common import Base62, Utils
from librespot.common import Base62
from librespot.common import Utils
from librespot.proto.ContextTrack_pb2 import ContextTrack

View File

@ -4,11 +4,14 @@ import typing
from librespot.core import Session
from librespot.dealer import DealerClient
from librespot.player import Player, PlayerConfiguration
from librespot.player import Player
from librespot.player import PlayerConfiguration
from librespot.player.state import DeviceStateHandler
from librespot.proto import Connect_pb2 as Connect
from librespot.proto.Player_pb2 import (ContextPlayerOptions, PlayerState,
Restrictions, Suppressions)
from librespot.proto.Player_pb2 import ContextPlayerOptions
from librespot.proto.Player_pb2 import PlayerState
from librespot.proto.Player_pb2 import Restrictions
from librespot.proto.Player_pb2 import Suppressions
class StateWrapper(DeviceStateHandler.Listener, DealerClient.MessageListener):