Closed jnxr closed 1 year ago
Just checked it by running the following command: pip install --force -U https://codeload.github.com/spotDL/spotify-downloader/zip/dev
Installed version now states 4.1.4.
But is not yet going past the same 38% point.
The first half of the error is different though:
An error occurred
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:383 in search_and_download │
│ │
│ 380 │ │ reinitialized = False │
│ 381 │ │ try: │
│ 382 │ │ │ # Create the output file path │
│ > 383 │ │ │ output_file = create_file_name( │
│ 384 │ │ │ │ song, │
│ 385 │ │ │ │ self.settings["output"], │
│ 386 │ │ │ │ self.settings["format"], │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\formatter.py:321 in create_file_name │
│ │
│ 318 │ if not template.endswith(".{output-ext}"): │
│ 319 │ │ template += ".{output-ext}" │
│ 320 │ │
│ > 321 │ formatted_string = format_query( │
│ 322 │ │ song=song, │
│ 323 │ │ template=template, │
│ 324 │ │ santitize=True, │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\formatter.py:228 in format_query │
│ │
│ 225 │ │ "{duration}": song.duration, │
│ 226 │ │ "{year}": song.year, │
│ 227 │ │ "{original-date}": song.date, │
│ > 228 │ │ "{track-number}": f"{song.track_number:02d}", │
│ 229 │ │ "{tracks-count}": song.tracks_count, │
│ 230 │ │ "{isrc}": song.isrc, │
│ 231 │ │ "{track-id}": song.song_id, │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
TypeError: unsupported format string passed to NoneType.__format__
The second half is the same..
During handling of the above exception, another exception occurred:
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in console_entry_point │
│ │
│ 117 │ try: │
│ 118 │ │ # Pick the operation to perform │
│ 119 │ │ # based on the name and run it! │
│ > 120 │ │ OPERATIONS[arguments.operation]( │
│ 121 │ │ │ query=arguments.query, │
│ 122 │ │ │ downloader=downloader, │
│ 123 │ │ ) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:28 in download │
│ │
│ 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │
│ 26 │ │
│ 27 │ # Download the songs │
│ > 28 │ downloader.download_multiple_songs(songs) │
│ 29 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:253 in download_multiple_songs │
│ │
│ 250 │ │ tasks = [self.pool_download(song) for song in songs] │
│ 251 │ │ │
│ 252 │ │ # Call all task asynchronously, and wait until all are finished │
│ > 253 │ │ results = list(self.loop.run_until_complete(asyncio.gather(*tasks))) │
│ 254 │ │ │
│ 255 │ │ # Print errors │
│ 256 │ │ if self.settings["print_errors"]: │
│ │
│ C:\Program Files\Python311\Lib\asyncio\base_events.py:653 in run_until_complete │
│ │
│ 650 │ │ if not future.done(): │
│ 651 │ │ │ raise RuntimeError('Event loop stopped before Future completed.') │
│ 652 │ │ │
│ > 653 │ │ return future.result() │
│ 654 │ │
│ 655 │ def stop(self): │
│ 656 │ │ """Stop running the event loop. │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:316 in pool_download │
│ │
│ 313 │ │ # tasks that cannot acquire semaphore will wait here until it's free │
│ 314 │ │ # only certain amount of tasks can acquire the semaphore at the same time │
│ 315 │ │ async with self.semaphore: │
│ > 316 │ │ │ return await self.loop.run_in_executor(None, self.search_and_download, song) │
│ 317 │ │
│ 318 │ def search(self, song: Song) -> str: │
│ 319 │ │ """ │
│ │
│ C:\Program Files\Python311\Lib\concurrent\futures\thread.py:58 in run │
│ │
│ 55 │ │ │ return │
│ 56 │ │ │
│ 57 │ │ try: │
│ > 58 │ │ │ result = self.fn(*self.args, **self.kwargs) │
│ 59 │ │ except BaseException as exc: │
│ 60 │ │ │ self.future.set_exception(exc) │
│ 61 │ │ │ # Break a reference cycle with the exception 'exc' │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:390 in search_and_download │
│ │
│ 387 │ │ │ │ self.settings["restrict"], │
│ 388 │ │ │ ) │
│ 389 │ │ except Exception: │
│ > 390 │ │ │ song = reinit_song(song) │
│ 391 │ │ │ output_file = create_file_name( │
│ 392 │ │ │ │ song, │
│ 393 │ │ │ │ self.settings["output"], │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:271 in reinit_song │
│ │
│ 268 │ if data.get("url"): │
│ 269 │ │ new_data = Song.from_url(data["url"]).json │
│ 270 │ elif data.get("name") and data.get("artist"): │
│ > 271 │ │ new_data = Song.from_search_term(data["name"]).json │
│ 272 │ else: │
│ 273 │ │ raise QueryError("Song object is missing required data to be reinitialized") │
│ 274 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │
│ │
│ 159 │ │ raw_search_results = Song.search(search_term) │
│ 160 │ │ │
│ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │
│ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │
│ 163 │ │ │
│ 164 │ │ return Song.from_url( │
│ 165 │ │ │ "http://open.spotify.com/track/" │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
Hope this helps.
Oh I've just noticed that you are trying to download an youtube music playlist. This is very experimental, but either way I will try to fix your issue.
Greatly appreciated. I do heavily depend on it. So here's hoping it becomes much more than experimental, as time goes.
Hey there. I just finished checking it and then rechecking it again, in a VM just to be extra sure. It still stops at the same 38% mark. The error I saw is as follows:
┌────────────────────────────── Traceback (most recent call last) ───────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:383 in │
│ search_and_download │
│ │
│ 380 │ │ reinitialized = False │
│ 381 │ │ try: │
│ 382 │ │ │ # Create the output file path │
│ > 383 │ │ │ output_file = create_file_name( │
│ 384 │ │ │ │ song, │
│ 385 │ │ │ │ self.settings["output"], │
│ 386 │ │ │ │ self.settings["format"], │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\formatter.py:321 in create_file_name │
│ │
│ 318 │ if not template.endswith(".{output-ext}"): │
│ 319 │ │ template += ".{output-ext}" │
│ 320 │ │
│ > 321 │ formatted_string = format_query( │
│ 322 │ │ song=song, │
│ 323 │ │ template=template, │
│ 324 │ │ santitize=True, │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\formatter.py:228 in format_query │
│ │
│ 225 │ │ "{duration}": song.duration, │
│ 226 │ │ "{year}": song.year, │
│ 227 │ │ "{original-date}": song.date, │
│ > 228 │ │ "{track-number}": f"{song.track_number:02d}", │
│ 229 │ │ "{tracks-count}": song.tracks_count, │
│ 230 │ │ "{isrc}": song.isrc, │
│ 231 │ │ "{track-id}": song.song_id, │
└────────────────────────────────────────────────────────────────────────────────────────────────┘
TypeError: unsupported format string passed to NoneType.__format__
During handling of the above exception, another exception occurred:
┌────────────────────────────── Traceback (most recent call last) ───────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in │
│ console_entry_point │
│ │
│ 117 │ try: │
│ 118 │ │ # Pick the operation to perform │
│ 119 │ │ # based on the name and run it! │
│ > 120 │ │ OPERATIONS[arguments.operation]( │
│ 121 │ │ │ query=arguments.query, │
│ 122 │ │ │ downloader=downloader, │
│ 123 │ │ ) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:28 in download │
│ │
│ 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │
│ 26 │ │
│ 27 │ # Download the songs │
│ > 28 │ downloader.download_multiple_songs(songs) │
│ 29 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:253 in │
│ download_multiple_songs │
│ │
│ 250 │ │ tasks = [self.pool_download(song) for song in songs] │
│ 251 │ │ │
│ 252 │ │ # Call all task asynchronously, and wait until all are finished │
│ > 253 │ │ results = list(self.loop.run_until_complete(asyncio.gather(*tasks))) │
│ 254 │ │ │
│ 255 │ │ # Print errors │
│ 256 │ │ if self.settings["print_errors"]: │
│ │
│ C:\Program Files\Python311\Lib\asyncio\base_events.py:653 in run_until_complete │
│ │
│ 650 │ │ if not future.done(): │
│ 651 │ │ │ raise RuntimeError('Event loop stopped before Future completed.') │
│ 652 │ │ │
│ > 653 │ │ return future.result() │
│ 654 │ │
│ 655 │ def stop(self): │
│ 656 │ │ """Stop running the event loop. │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:316 in │
│ pool_download │
│ │
│ 313 │ │ # tasks that cannot acquire semaphore will wait here until it's free │
│ 314 │ │ # only certain amount of tasks can acquire the semaphore at the same time │
│ 315 │ │ async with self.semaphore: │
│ > 316 │ │ │ return await self.loop.run_in_executor(None, self.search_and_download, song) │
│ 317 │ │
│ 318 │ def search(self, song: Song) -> str: │
│ 319 │ │ """ │
│ │
│ C:\Program Files\Python311\Lib\concurrent\futures\thread.py:58 in run │
│ │
│ 55 │ │ │ return │
│ 56 │ │ │
│ 57 │ │ try: │
│ > 58 │ │ │ result = self.fn(*self.args, **self.kwargs) │
│ 59 │ │ except BaseException as exc: │
│ 60 │ │ │ self.future.set_exception(exc) │
│ 61 │ │ │ # Break a reference cycle with the exception 'exc' │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:390 in │
│ search_and_download │
│ │
│ 387 │ │ │ │ self.settings["restrict"], │
│ 388 │ │ │ ) │
│ 389 │ │ except Exception: │
│ > 390 │ │ │ song = reinit_song(song) │
│ 391 │ │ │ output_file = create_file_name( │
│ 392 │ │ │ │ song, │
│ 393 │ │ │ │ self.settings["output"], │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:291 in reinit_song │
│ │
│ 288 │ if data.get("url"): │
│ 289 │ │ new_data = Song.from_url(data["url"]).json │
│ 290 │ elif data.get("name") and data.get("artist"): │
│ > 291 │ │ new_data = Song.from_search_term(data["name"]).json │
│ 292 │ else: │
│ 293 │ │ raise QueryError("Song object is missing required data to be reinitialized") │
│ 294 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │
│ │
│ 159 │ │ raw_search_results = Song.search(search_term) │
│ 160 │ │ │
│ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │
│ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │
│ 163 │ │ │
│ 164 │ │ return Song.from_url( │
│ 165 │ │ │ "http://open.spotify.com/track/" │
└────────────────────────────────────────────────────────────────────────────────────────────────┘
@xnetcat I changed the title, but should I make a new issue post since this one has been closed?
I totally thought that I've fixed this...
ee319ccef843f78d41f22f03d431765a47899db1 this should resolve your issue
for now install dev version, and let me know if it works, if it's still isn't working send me link to the song that keeps breaking the download
I rechecked it with the dev branch. Here are the last few lines from the command prompt, when the error occurs:
Skipping missxcessive - mind.in.a.box - Lightforce (file already exists)
Skipping ANORAAK - Nightdrive With You (file already exists)
Skipping Chromatics - Tick of the Clock (file already exists)
Skipping The Prismer - Desire - Under Your Spell (file already exists)
Skipping burial80 - Glass Candy - Digital Versicolor (file already exists)
An error occurred
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in console_entry_point │
│ │
│ 117 │ try: │
│ 118 │ │ # Pick the operation to perform │
│ 119 │ │ # based on the name and run it! │
│ > 120 │ │ OPERATIONS[arguments.operation]( │
│ 121 │ │ │ query=arguments.query, │
│ 122 │ │ │ downloader=downloader, │
│ 123 │ │ ) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:28 in download │
│ │
│ 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │
│ 26 │ │
│ 27 │ # Download the songs │
│ > 28 │ downloader.download_multiple_songs(songs) │
│ 29 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:253 in download_multiple_songs │
│ │
│ 250 │ │ tasks = [self.pool_download(song) for song in songs] │
│ 251 │ │ │
│ 252 │ │ # Call all task asynchronously, and wait until all are finished │
│ > 253 │ │ results = list(self.loop.run_until_complete(asyncio.gather(*tasks))) │
│ 254 │ │ │
│ 255 │ │ # Print errors │
│ 256 │ │ if self.settings["print_errors"]: │
│ │
│ C:\Program Files\Python311\Lib\asyncio\base_events.py:653 in run_until_complete │
│ │
│ 650 │ │ if not future.done(): │
│ 651 │ │ │ raise RuntimeError('Event loop stopped before Future completed.') │
│ 652 │ │ │
│ > 653 │ │ return future.result() │
│ 654 │ │
│ 655 │ def stop(self): │
│ 656 │ │ """Stop running the event loop. │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:316 in pool_download │
│ │
│ 313 │ │ # tasks that cannot acquire semaphore will wait here until it's free │
│ 314 │ │ # only certain amount of tasks can acquire the semaphore at the same time │
│ 315 │ │ async with self.semaphore: │
│ > 316 │ │ │ return await self.loop.run_in_executor(None, self.search_and_download, song) │
│ 317 │ │
│ 318 │ def search(self, song: Song) -> str: │
│ 319 │ │ """ │
│ │
│ C:\Program Files\Python311\Lib\concurrent\futures\thread.py:58 in run │
│ │
│ 55 │ │ │ return │
│ 56 │ │ │
│ 57 │ │ try: │
│ > 58 │ │ │ result = self.fn(*self.args, **self.kwargs) │
│ 59 │ │ except BaseException as exc: │
│ 60 │ │ │ self.future.set_exception(exc) │
│ 61 │ │ │ # Break a reference cycle with the exception 'exc' │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:455 in search_and_download │
│ │
│ 452 │ │ │ │ song.album_artist, │
│ 453 │ │ │ ] │
│ 454 │ │ ): │
│ > 455 │ │ │ song = reinit_song(song) │
│ 456 │ │ │ reinitialized = True │
│ 457 │ │ │
│ 458 │ │ # Don't skip if the file exists and overwrite is set to force │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:291 in reinit_song │
│ │
│ 288 │ if data.get("url"): │
│ 289 │ │ new_data = Song.from_url(data["url"]).json │
│ 290 │ elif data.get("name") and data.get("artist"): │
│ > 291 │ │ new_data = Song.from_search_term(data["name"]).json │
│ 292 │ else: │
│ 293 │ │ raise QueryError("Song object is missing required data to be reinitialized") │
│ 294 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │
│ │
│ 159 │ │ raw_search_results = Song.search(search_term) │
│ 160 │ │ │
│ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │
│ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │
│ 163 │ │ │
│ 164 │ │ return Song.from_url( │
│ 165 │ │ │ "http://open.spotify.com/track/" │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
SongError: No results found for: S U R V I V E - HD009 - 1 - cschz 01
Downloaded "Cinnamon Chasers - Cinnamon Chasers - Speeder": https://music.youtube.com/watch?v=j8ApUrafImQ
Downloaded "TheToxicAvengerBand - The Toxic Avenger - Spaced": https://music.youtube.com/watch?v=vSoZqSCStfA
Downloaded "Medulla Mactabile Maculae - M/M/M - DISTANT PROJECTIONS": https://music.youtube.com/watch?v=YzTGJvhpyVE
PS C:\a>
This is what I got when I double checking it:
Total 1721/4548 complete ----------------- ----------------------------- 38% 0:02:00
Holodeck Records - S U R V I V E - HD0… Download Started ----------------------------------------------- 0% -:--:--
Chromatics - Tick of the Clock Download Started ----------------------------------------------- 0% -:--:--
The Prismer - Desire - Under Your Spell Download Started ----------------------------------------------- 0% -:--:--
burial80 - Glass Candy - Digital Versi… Download Started ----------------------------------------------- 0% -:--:--Skipping The Prismer - Desire - Under Your Spell (file already exists)
Skipping burial80 - Glass Candy - Digital Versicolor (file already exists)
An error occurred
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in console_entry_point │
│ │
│ 117 │ try: │
│ 118 │ │ # Pick the operation to perform │
│ 119 │ │ # based on the name and run it! │
│ > 120 │ │ OPERATIONS[arguments.operation]( │
│ 121 │ │ │ query=arguments.query, │
│ 122 │ │ │ downloader=downloader, │
│ 123 │ │ ) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:28 in download │
│ │
│ 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │
│ 26 │ │
│ 27 │ # Download the songs │
│ > 28 │ downloader.download_multiple_songs(songs) │
│ 29 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:253 in download_multiple_songs │
│ │
│ 250 │ │ tasks = [self.pool_download(song) for song in songs] │
│ 251 │ │ │
│ 252 │ │ # Call all task asynchronously, and wait until all are finished │
│ > 253 │ │ results = list(self.loop.run_until_complete(asyncio.gather(*tasks))) │
│ 254 │ │ │
│ 255 │ │ # Print errors │
│ 256 │ │ if self.settings["print_errors"]: │
│ │
│ C:\Program Files\Python311\Lib\asyncio\base_events.py:653 in run_until_complete │
│ │
│ 650 │ │ if not future.done(): │
│ 651 │ │ │ raise RuntimeError('Event loop stopped before Future completed.') │
│ 652 │ │ │
│ > 653 │ │ return future.result() │
│ 654 │ │
│ 655 │ def stop(self): │
│ 656 │ │ """Stop running the event loop. │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:316 in pool_download │
│ │
│ 313 │ │ # tasks that cannot acquire semaphore will wait here until it's free │
│ 314 │ │ # only certain amount of tasks can acquire the semaphore at the same time │
│ 315 │ │ async with self.semaphore: │
│ > 316 │ │ │ return await self.loop.run_in_executor(None, self.search_and_download, song) │
│ 317 │ │
│ 318 │ def search(self, song: Song) -> str: │
│ 319 │ │ """ │
│ │
│ C:\Program Files\Python311\Lib\concurrent\futures\thread.py:58 in run │
│ │
│ 55 │ │ │ return │
│ 56 │ │ │
│ 57 │ │ try: │
│ > 58 │ │ │ result = self.fn(*self.args, **self.kwargs) │
│ 59 │ │ except BaseException as exc: │
│ 60 │ │ │ self.future.set_exception(exc) │
│ 61 │ │ │ # Break a reference cycle with the exception 'exc' │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\download\downloader.py:455 in search_and_download │
│ │
│ 452 │ │ │ │ song.album_artist, │
│ 453 │ │ │ ] │
│ 454 │ │ ): │
│ > 455 │ │ │ song = reinit_song(song) │
│ 456 │ │ │ reinitialized = True │
│ 457 │ │ │
│ 458 │ │ # Don't skip if the file exists and overwrite is set to force │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:291 in reinit_song │
│ │
│ 288 │ if data.get("url"): │
│ 289 │ │ new_data = Song.from_url(data["url"]).json │
│ 290 │ elif data.get("name") and data.get("artist"): │
│ > 291 │ │ new_data = Song.from_search_term(data["name"]).json │
│ 292 │ else: │
│ 293 │ │ raise QueryError("Song object is missing required data to be reinitialized") │
│ 294 │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │
│ │
│ 159 │ │ raw_search_results = Song.search(search_term) │
│ 160 │ │ │
│ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │
│ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │
│ 163 │ │ │
│ 164 │ │ return Song.from_url( │
│ 165 │ │ │ "http://open.spotify.com/track/" │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
SongError: No results found for: S U R V I V E - HD009 - 1 - cschz 01
I think its getting stuck at this song: https://music.youtube.com/watch?v=yn3EyK3QVgw
The issue is that it exits the entire playlist whenever such an error occurs instead of going ahead with the next item in the playlist because of which playlists end up unfinished. I have seen this occur in other playlists before, but never did make a post here until now.
Should be fixed
Here's the error I just got with my latest attempt:
PS C:\a> spotdl --bitrate 0 https:/music.youtube.com/watch?v=yn3EyK3QVgw
Processing query: https:/music.youtube.com/watch?v=yn3EyK3QVgw
An error occurred
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in console_entry_point │
│ │
│ 117 │ try: │
│ 118 │ │ # Pick the operation to perform │
│ 119 │ │ # based on the name and run it! │
│ > 120 │ │ OPERATIONS[arguments.operation]( │
│ 121 │ │ │ query=arguments.query, │
│ 122 │ │ │ downloader=downloader, │
│ 123 │ │ ) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:25 in download │
│ │
│ 22 │ """ │
│ 23 │ │
│ 24 │ # Parse the query │
│ > 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │
│ 26 │ │
│ 27 │ # Download the songs │
│ 28 │ downloader.download_multiple_songs(songs) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:220 in get_simple_songs │
│ │
│ 217 │ │ │ │ │ # Append to songs │
│ 218 │ │ │ │ │ songs.append(Song.from_dict(track)) │
│ 219 │ │ else: │
│ > 220 │ │ │ songs.append(Song.from_search_term(request)) │
│ 221 │ │
│ 222 │ for song_list in lists: │
│ 223 │ │ logger.info( │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │
│ │
│ 159 │ │ raw_search_results = Song.search(search_term) │
│ 160 │ │ │
│ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │
│ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │
│ 163 │ │ │
│ 164 │ │ return Song.from_url( │
│ 165 │ │ │ "http://open.spotify.com/track/" │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
SongError: No results found for: https:/music.youtube.com/watch?v=yn3EyK3QVgw
PS C:\a>
Here's the error I just got with my latest attempt:
PS C:\a> spotdl --bitrate 0 https:/music.youtube.com/watch?v=yn3EyK3QVgw Processing query: https:/music.youtube.com/watch?v=yn3EyK3QVgw An error occurred ┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐ │ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in console_entry_point │ │ │ │ 117 │ try: │ │ 118 │ │ # Pick the operation to perform │ │ 119 │ │ # based on the name and run it! │ │ > 120 │ │ OPERATIONS[arguments.operation]( │ │ 121 │ │ │ query=arguments.query, │ │ 122 │ │ │ downloader=downloader, │ │ 123 │ │ ) │ │ │ │ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:25 in download │ │ │ │ 22 │ """ │ │ 23 │ │ │ 24 │ # Parse the query │ │ > 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │ │ 26 │ │ │ 27 │ # Download the songs │ │ 28 │ downloader.download_multiple_songs(songs) │ │ │ │ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:220 in get_simple_songs │ │ │ │ 217 │ │ │ │ │ # Append to songs │ │ 218 │ │ │ │ │ songs.append(Song.from_dict(track)) │ │ 219 │ │ else: │ │ > 220 │ │ │ songs.append(Song.from_search_term(request)) │ │ 221 │ │ │ 222 │ for song_list in lists: │ │ 223 │ │ logger.info( │ │ │ │ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │ │ │ │ 159 │ │ raw_search_results = Song.search(search_term) │ │ 160 │ │ │ │ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │ │ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │ │ 163 │ │ │ │ 164 │ │ return Song.from_url( │ │ 165 │ │ │ "http://open.spotify.com/track/" │ └─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘ SongError: No results found for: https:/music.youtube.com/watch?v=yn3EyK3QVgw PS C:\a>
This song has wrong title/artist on youtube music, song title is "artist name + album name + song title" and artist name is "label name". Really weird, that's why spotDL can't find the correct song on spotify.
spotDL can't find the correct song on spotify.
I see, indeed it is unusual. Not sure how you're gonna correct for such an edge case, but it's ideal if it continues with the rest of the playlist regardless.
but it's ideal if it continues with the rest of the playlist regardless.
Awesome!
Downloading the song is still giving the following error:
C:\a>spotdl https://music.youtube.com/watch?v=yn3EyK3QVgw
Processing query: https://music.youtube.com/watch?v=yn3EyK3QVgw
An error occurred
┌───────────────────────────────────────── Traceback (most recent call last) ─────────────────────────────────────────┐
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\entry_point.py:120 in console_entry_point │
│ │
│ 117 │ try: │
│ 118 │ │ # Pick the operation to perform │
│ 119 │ │ # based on the name and run it! │
│ > 120 │ │ OPERATIONS[arguments.operation]( │
│ 121 │ │ │ query=arguments.query, │
│ 122 │ │ │ downloader=downloader, │
│ 123 │ │ ) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\console\download.py:25 in download │
│ │
│ 22 │ """ │
│ 23 │ │
│ 24 │ # Parse the query │
│ > 25 │ songs = get_simple_songs(query, use_ytm_data=downloader.settings["ytm_data"]) │
│ 26 │ │
│ 27 │ # Download the songs │
│ 28 │ downloader.download_multiple_songs(songs) │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\utils\search.py:220 in get_simple_songs │
│ │
│ 217 │ │ │ │ │ # Append to songs │
│ 218 │ │ │ │ │ songs.append(Song.from_dict(track)) │
│ 219 │ │ else: │
│ > 220 │ │ │ songs.append(Song.from_search_term(request)) │
│ 221 │ │
│ 222 │ for song_list in lists: │
│ 223 │ │ logger.info( │
│ │
│ C:\Program Files\Python311\Lib\site-packages\spotdl\types\song.py:162 in from_search_term │
│ │
│ 159 │ │ raw_search_results = Song.search(search_term) │
│ 160 │ │ │
│ 161 │ │ if len(raw_search_results["tracks"]["items"]) == 0: │
│ > 162 │ │ │ raise SongError(f"No results found for: {search_term}") │
│ 163 │ │ │
│ 164 │ │ return Song.from_url( │
│ 165 │ │ │ "http://open.spotify.com/track/" │
└─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘
SongError: No results found for: https://music.youtube.com/watch?v=yn3EyK3QVgw
C:\a>
But with the playlist, it skipped the error causing track successfully, very nice!
PS: @xnetcat If the data can't be found in Spotify, for cases like this where we download from YouTube Music/YouTube playlists, I propose that the song/audio be converted as is without Metadata from Spotify. Perhaps, lookingup an alternative source/database, can be incorporated as a future solution/feature. But right now, just making it possible to convert without Metadata when it can't be found in Spotify would mean that it would work with all YouTube playlists, not just Music ones. That would make it a lot more versatile, since we could simply make audio mp3 playlists of everything from YouTube!
@xnetcat should I make the above post into a separate feature request? It would help a ton, if it worked across all youtube playlists.
System OS
Windows
Python Version
3.11 (CPython)
Install Source
pip / PyPi
Install version / commit hash
4.1.3, 4.1.4
Expected Behavior vs Actual Behavior
SpotDL stops abruptly with errors at the 38% mark while downloading the following playlist in Windows: https://music.youtube.com/playlist?list=PLgeWE9wvSRs7QkgMxXMEMKENilgNzQrRl
Steps to reproduce - Ensure to include actual links!
The issue can be reproduced by trying to download the following playlist via spotDL 4.1.3 in Windows [py-3.11.2]: https://music.youtube.com/playlist?list=PLgeWE9wvSRs7QkgMxXMEMKENilgNzQrRl
I also tried this in a new Windows VM just to be sure, & new installation of Python and SpotDL+ffmpeg. The errors are faithfully reproduced right at the 38% mark.
The full log is attached in the following text file. a.error.txt
Additionally, I also tried running the following upgrade command to check if issue has already been fixed in the dev branch. pip install --force -U https://codeload.github.com/spotDL/spotify-downloader/zip/dev
The issue persists.
Traceback
Other details
Could not copy full output due to gihub issue outage? I keep getting the error: "body is too long (maximum is 65536 characters)." Therefore have attached it in a separate text file.