diff options
| author | Robert Honz <exislow+github@gmail.com> | 2024-04-20 16:19:08 +0200 |
|---|---|---|
| committer | Robert Honz <exislow+github@gmail.com> | 2024-04-20 16:19:08 +0200 |
| commit | 8fdbb9127c8c038bb7e828201ece36cda259c147 (patch) | |
| tree | c43d8c35007d1a2140a68660a044c9cb2a458e93 | |
| parent | 68ad21276bcf6300827aceed7017ff70230fe320 (diff) | |
| download | tidal-dl-ng-8fdbb9127c8c038bb7e828201ece36cda259c147.tar.gz | |
👷 Exception handling on missing lyrics adjusted due to `tidalapi` breaking changes. Fixes #92
| -rw-r--r-- | tidal_dl_ng/download.py | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/tidal_dl_ng/download.py b/tidal_dl_ng/download.py index c8c59c2..f098327 100644 --- a/tidal_dl_ng/download.py +++ b/tidal_dl_ng/download.py @@ -144,10 +144,7 @@ class Download: # TODO: Handle Exception... self.fn_logger(e) - # Check if file is encrypted. - needs_decryption = self.is_encrypted(stream_manifest.encryption_type) - - if needs_decryption: + if stream_manifest.is_encrypted: key, nonce = decrypt_security_token(stream_manifest.encryption_key) tmp_path_file_decrypted = path_file + "_decrypted" decrypt_file(path_file, tmp_path_file_decrypted, key, nonce) @@ -289,7 +286,7 @@ class Download: lyrics = lyrics_obj.subtitles elif lyrics_obj.text: lyrics = lyrics_obj.text - except (HTTPError, AttributeError): + except: lyrics = "" # TODO: Implement proper logging. print(f"Could not retrieve lyrics for `{name_builder_item(track)}`.") |
