Format code with yapf

This commit fixes the style issues introduced in 4635bf8 according to the output
from yapf.

Details: https://deepsource.io/gh/kokarare1212/librespot-python/transform/556eb7b2-7632-467e-b1b4-8e463d91a708/
This commit is contained in:
deepsource-autofix[bot]
2021-05-21 03:34:15 +00:00
committed by GitHub
parent 4635bf8d24
commit fc57a76aa0
5 changed files with 34 additions and 21 deletions

View File

@@ -63,8 +63,7 @@ class AbsChunkedInputStream(InputStream, HaltListener):
raise IOError("Stream is closed!")
self._pos = where
self.check_availability(int(self._pos / (128 * 1024)),
False, False)
self.check_availability(int(self._pos / (128 * 1024)), False, False)
def skip(self, n: int) -> int:
if n < 0:

View File

@@ -31,7 +31,8 @@ class CdnFeedHelper:
streamer = session.cdn().stream_file(file, key, url, halt_listener)
input_stream = streamer.stream()
normalization_data = NormalizationData.NormalizationData.read(input_stream)
normalization_data = NormalizationData.NormalizationData.read(
input_stream)
if input_stream.skip(0xa7) != 0xa7:
raise IOError("Couldn't skip 0xa7 bytes!")
return PlayableContentFeeder.PlayableContentFeeder.LoadedStream(

View File

@@ -159,7 +159,8 @@ class CdnManager:
else:
self._expiration = -1
class Streamer(GeneralAudioStream.GeneralAudioStream, GeneralWritableStream.GeneralWritableStream):
class Streamer(GeneralAudioStream.GeneralAudioStream,
GeneralWritableStream.GeneralWritableStream):
_session: Session = None
_streamId: StreamId = None
_executorService = concurrent.futures.ThreadPoolExecutor()

View File

@@ -245,7 +245,8 @@ class Session(Closeable, SubListener, DealerClient.MessageListener):
self._channelManager = ChannelManager(self)
self._api = ApiClient.ApiClient(self)
self._cdnManager = CdnManager(self)
self._contentFeeder = PlayableContentFeeder.PlayableContentFeeder(self)
self._contentFeeder = PlayableContentFeeder.PlayableContentFeeder(
self)
self._cacheManager = CacheManager(self)
self._dealer = DealerClient(self)
self._search = SearchManager.SearchManager(self)