Bump RLL and improve logging (#5044)

* version bump

* - bump RLL
- logging changes
- player.channel.guild->player.guild
- small cleanup around logging changes

* missed one

* here this one too

* Apply suggestions from code review

Co-authored-by: jack1142 <6032823+jack1142@users.noreply.github.com>

* add one missing player log

* missed one

* Format with Black

Co-authored-by: jack1142 <6032823+jack1142@users.noreply.github.com>
This commit is contained in:
Draper
2021-05-18 23:56:10 +01:00
committed by GitHub
parent c9431f7d90
commit 38da7370ec
19 changed files with 164 additions and 148 deletions

View File

@@ -102,7 +102,7 @@ class SpotifyWrapper:
async with self.session.request("GET", url, params=params, headers=headers) as r:
data = await r.json(loads=json.loads)
if r.status != 200:
log.debug(f"Issue making GET request to {url}: [{r.status}] {data}")
log.debug("Issue making GET request to %r: [%d] %r", url, r.status, data)
return data
async def update_token(self, new_token: Mapping[str, str]):
@@ -146,7 +146,7 @@ class SpotifyWrapper:
except KeyError:
return None
self.spotify_token = token
log.debug(f"Created a new access token for Spotify: {token}")
log.debug("Created a new access token for Spotify: %s", token)
return self.spotify_token["access_token"]
async def post(
@@ -156,7 +156,7 @@ class SpotifyWrapper:
async with self.session.post(url, data=payload, headers=headers) as r:
data = await r.json(loads=json.loads)
if r.status != 200:
log.debug(f"Issue making POST request to {url}: [{r.status}] {data}")
log.debug("Issue making POST request to %r: [%d] %r", url, r.status, data)
return data
async def make_get_call(self, url: str, params: MutableMapping) -> MutableMapping: