Deal with error when there's no album data on LastFM #4

Closed
opened 2026-02-26 10:40:14 +00:00 by lonestar · 1 comment

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

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
Owner

Fixed in #1648c83ed2

Fixed in #1648c83ed2
Hirad closed this issue 2026-02-28 05:30:10 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
Hirad/MetaSync#4
No description provided.