From c3d2b98bb5d3d62fc45ac811f86a8fdf513093c3 Mon Sep 17 00:00:00 2001 From: "Jon Michael Aanes (aider)" Date: Sat, 15 Mar 2025 22:35:07 +0100 Subject: [PATCH] style: Run linter and fix formatting issues in youtube.py --- personal_data/fetchers/youtube.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/personal_data/fetchers/youtube.py b/personal_data/fetchers/youtube.py index e067f64..cc68441 100644 --- a/personal_data/fetchers/youtube.py +++ b/personal_data/fetchers/youtube.py @@ -42,10 +42,14 @@ def scrape(watch_history: bool) -> list[dict[str, str]]: ) if result.returncode != 0: - message = 'Non-zero returncode in command: ' + str(result.returncode) + "\n\n" + result.stderr + message = ( + 'Non-zero returncode in command: ' + + str(result.returncode) + + '\n\n' + + result.stderr + ) raise RuntimeError(message) - output = [] for line in result.stdout.splitlines(): data = json.loads(line) @@ -55,7 +59,7 @@ def scrape(watch_history: bool) -> list[dict[str, str]]: if data.get('timestamp'): data['watch_datetime'] = datetime.datetime.fromtimestamp( int(data['timestamp']), - tz=datetime.timezone.utc + tz=datetime.timezone.utc, ).isoformat() else: data['thumbnail'] = data['thumbnails'][-1]['url']