Skip to content

Commit

Permalink
Fixed lint issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Peter-Schorn authored and dieser-niko committed Oct 8, 2024
1 parent fb58b10 commit 28cc19d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
1 change: 0 additions & 1 deletion spotipy/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,6 @@ def __init__(
else: # Use the Requests API module as a "session".
self._session = requests.api


def __del__(self):
"""Make sure the connection (pool) gets closed"""
try:
Expand Down
3 changes: 2 additions & 1 deletion tests/integration/user_endpoints/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import unittest
from tests import helpers


def _make_spotify(scopes=None, retries=None):

retries = retries or Spotify.max_retries
Expand All @@ -27,6 +28,7 @@ def _make_spotify(scopes=None, retries=None):

return spotify


class SpotipyPlaylistApiTest(unittest.TestCase):
@classmethod
def setUpClass(cls):
Expand Down Expand Up @@ -66,7 +68,6 @@ def setUpClass(cls):
cls.spotify = _make_spotify(scopes=scope)
cls.spotify_no_retry = _make_spotify(scopes=scope, retries=0)


cls.new_playlist_name = 'spotipy-playlist-test'
cls.new_playlist = helpers.get_spotify_playlist(
cls.spotify, cls.new_playlist_name, cls.username) or \
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/test_oauth.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,9 @@
import urllib.parse as urllibparse

from spotipy import SpotifyOAuth, SpotifyPKCE
from spotipy.cache_handler import CacheHandler
from spotipy.oauth2 import SpotifyClientCredentials, SpotifyOauthError
from spotipy.oauth2 import SpotifyStateError
from spotipy import CacheFileHandler
from spotipy import MemoryCacheHandler, CacheFileHandler

patch = mock.patch
DEFAULT = mock.DEFAULT
Expand Down Expand Up @@ -228,6 +227,7 @@ def test_spotify_client_credentials_get_access_token(self):
oauth.get_access_token(check_cache=False)
self.assertEqual(error.exception.error, 'invalid_client')


class SpotifyPKCECacheTest(unittest.TestCase):

@patch.multiple(SpotifyPKCE,
Expand Down

0 comments on commit 28cc19d

Please sign in to comment.