Deal with error when there's no album data on LastFM #4
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Hirad/MetaSync#4
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
When it happens that an album has no data on LastFM (it's very new and it's not been populated yet), the sync should not throw errors and it should not interrupt an "Update all" process. It could say something like "empty album, skipping" in the log.
an example:
album: Yikes - Toadspawn
20260226 11:30:15 - metasync.services.webpage_extractor:188 - WARNING - Could not find or parse release date from URL: https://www.last.fm/music/Yikes/Toadspawn
20260226 11:30:31 - metasync.api.core.transport:187 - ERROR - API error: Invalid parameters - Your request is missing a required parameter (code: 6)
20260226 11:30:31 - metasync.gui.workers.base_worker:42 - ERROR - Error in worker UpdateWorker: API error: Invalid parameters - Your request is missing a required parameter | status=6
Traceback (most recent call last):
File "/home/lonestar/Downloads/MetaSync/src/metasync/gui/workers/base_worker.py", line 39, in run
self._do_work(*args, **kwargs)
File "/home/lonestar/Downloads/MetaSync/src/metasync/gui/workers/update_worker.py", line 44, in _do_work
elif isinstance(item, Album) and self.services.album_service.update_info(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/lonestar/Downloads/MetaSync/src/metasync/services/album_service.py", line 220, in update_info
response = self.api_client.album.update(album)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/lonestar/Downloads/MetaSync/src/metasync/api/resources/album.py", line 119, in update
return self._transport.request(
^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/lonestar/Downloads/MetaSync/src/metasync/api/core/transport.py", line 188, in request
raise APIError(f"API error: {error_msg}", status_code=error_code)
metasync.utils.exceptions.APIError: API error: Invalid parameters - Your request is missing a required parameter | status=6
^CTraceback (most recent call last):
File "/home/lonestar/Downloads/MetaSync/src/metasync/gui/managers/dialog_manager.py", line 47, in open_search_dialog
def open_search_dialog(self) -> None:
another one
album: Eyebleech - Turn The Minutes Into Finished
20260226 11:33:02 - metasync.services.webpage_extractor:188 - WARNING - Could not find or parse release date from URL: https://www.last.fm/music/Eyebleech/Turn+The+Minutes+Into+Finished
20260226 11:33:11 - metasync.api.core.transport:187 - ERROR - API error: Invalid parameters - Your request is missing a required parameter (code: 6)
20260226 11:33:11 - metasync.gui.workers.base_worker:42 - ERROR - Error in worker UpdateWorker: API error: Invalid parameters - Your request is missing a required parameter | status=6
Traceback (most recent call last):
File "/home/lonestar/Downloads/MetaSync/src/metasync/gui/workers/base_worker.py", line 39, in run
self._do_work(*args, **kwargs)
File "/home/lonestar/Downloads/MetaSync/src/metasync/gui/workers/update_worker.py", line 44, in _do_work
elif isinstance(item, Album) and self.services.album_service.update_info(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/lonestar/Downloads/MetaSync/src/metasync/services/album_service.py", line 220, in update_info
response = self.api_client.album.update(album)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/lonestar/Downloads/MetaSync/src/metasync/api/resources/album.py", line 119, in update
return self._transport.request(
^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/lonestar/Downloads/MetaSync/src/metasync/api/core/transport.py", line 188, in request
raise APIError(f"API error: {error_msg}", status_code=error_code)
metasync.utils.exceptions.APIError: API error: Invalid parameters - Your request is missing a required parameter | status=6
Fixed in #
1648c83ed2