arr-scripts icon indicating copy to clipboard operation
arr-scripts copied to clipboard

[BUG] - Lidarr - Tidal downloads broken

Open PixNyb opened this issue 2 months ago • 9 comments

Application Lidarr

Host platform Any

Script tidal-dl

Script Version 2.48 (main)

Describe the bug It appears that Tidal has finally changed it's API enough for tidal-dl to be unable to function. An update to use tidal-dl-ng might be a solution to this problem, as this seems to function just fine.

When making a download attempt to any album the following occurs:

Starting login process...
[ERR] Login failed.Device authorization failed. Please choose another apikey.
[INFO] Download path:/config/extended/downloads/audio/incomplete
[ERR] No result. [248123865]

I've tried re-authenticating manually, and picking different API keys to no avail.

To Reproduce Steps to reproduce the behavior:

  1. Start lidarr with the extended scripts installed
  2. Wait for the Audio script to kick off and download missing/unmet albums

Expected behavior Tidal should be using my authentication to download lossless official albums

Logs/Screenshots During startup:

...
x :: Audio :: 2.48 :: TIDAL :: Verifying tidal-dl configuration
x :: Audio :: 2.48 :: TIDAL :: No default config found, importing default config "tidal.json"
/usr/lib/python3.12/site-packages/aigpy/tagHelper.py:211: SyntaxWarning: invalid escape sequence '\c'
  self.copyright = self.__getTagItem__('\cprt')
/usr/lib/python3.12/site-packages/tidal_dl/printf.py:47: SyntaxWarning: invalid escape sequence '\_'
  def logo():
x :: Audio :: 2.48 :: TIDAL :: Purging album list cache...
...

Randomly when kicking off the script:

x :: Audio :: 2.48 :: TIDAL :: Verifying tidal-dl configuration
x :: Audio :: 2.48 :: TIDAL :: No default config found, importing default config "tidal.json"
x :: Audio :: 2.48 :: TIDAL :: ERROR :: Loading client for required authentication, please authenticate, then exit the client...

 /$$$$$$$$ /$$       /$$           /$$               /$$ /$$
|__  $$__/|__/      | $$          | $$              | $$| $$
   | $$    /$$  /$$$$$$$  /$$$$$$ | $$          /$$$$$$$| $$
   | $$   | $$ /$$__  $$ |____  $$| $$ /$$$$$$ /$$__  $$| $$
   | $$   | $$| $$  | $$  /$$$$$$$| $$|______/| $$  | $$| $$
   | $$   | $$| $$  | $$ /$$__  $$| $$        | $$  | $$| $$
   | $$   | $$|  $$$$$$$|  $$$$$$$| $$        |  $$$$$$$| $$
   |__/   |__/ \_______/ \_______/|__/         \_______/|__/
   
       https://github.com/yaronzz/Tidal-Media-Downloader 
       
                        2022.10.31.1

+-------------------------------+-----------------------------------------------------------+
| SETTINGS                      | VALUE                                                     |
+-------------------------------+-----------------------------------------------------------+
| Settings path                 | /config/xdg/.tidal-dl.json                                |
| Download path                 | /config/extended/downloads/audio/incomplete               |
| Album folder format           | atd                                                       |
| Playlist folder format        | Playlist/{PlaylistName} [{PlaylistUUID}]                  |
| Track file format             | {TrackNumber} - {TrackTitle}                              |
| Video file format             | {VideoNumber} - {ArtistName} - {VideoTitle}{ExplicitFlag} |
| Audio quality                 | AudioQuality.HiFi                                         |
| Video quality                 | VideoQuality.P1080                                        |
| Use playlist folder           | False                                                     |
| Check exist                   | True                                                      |
| Show progress                 | False                                                     |
| Show Track Info               | True                                                      |
| Save AlbumInfo.txt            | False                                                     |
| Save covers                   | True                                                      |
| Include singles & EPs         | True                                                      |
| Language                      | English                                                   |
| Save timed lyrics (.lrc file) | True                                                      |
| Multi thread download         | False                                                     |
| APIKey support                | [4]Normal/High/HiFi/Master                                |
| Use Download Delay            | None                                                      |
+-------------------------------+-----------------------------------------------------------+
Starting login process...
[ERR] Login failed.Device authorization failed. Please choose another apikey.
====================================================
CHOICE                 FUNCTION                     
Enter '0':             Exit                         
Enter '1':             Check AccessToken            
Enter '2':             Logout                       
Enter '3':             Set AccessToken              
Enter '4':             Settings-Path                
Enter '5':             Settings-Quality             
Enter '6':             Settings-Else                
Enter '7':             Select APIKey                
Enter 'Url/ID':        Download by url or ID        
====================================================
Traceback (most recent call last):
  File "/usr/bin/tidal-dl", line 10, in <module>
    sys.exit(main())
             ^^^^^^
  File "/usr/lib/python3.12/site-packages/tidal_dl/__init__.py", line 92, in main
    choice = Printf.enter(LANG.select.PRINT_ENTER_CHOICE)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/tidal_dl/printf.py", line 135, in enter
    ret = input("")
          ^^^^^^^^^
EOFError: EOF when reading a line
Enter Choice:x :: Audio :: 2.48 :: TIDAL :: Purging album list cache...

During downloads:

x :: Audio :: 2.48 :: 1 :: missing :: 6 of 62 :: Kaleo :: Surface Sounds :: Album :: Download Attempt number 1
Starting login process...
[ERR] Login failed.Device authorization failed. Please choose another apikey.
[INFO] Download path:/config/extended/downloads/audio/incomplete
[ERR] No result. [179016368]

Additional context Tidal-dl has been end of life for quite a while and tidal-dl-ng has replaced it in many cases. It should be rather easy to update the scripts to use the ng variant rather than the original tidal-dl

PixNyb avatar Oct 17 '25 19:10 PixNyb

Is there any update for this? I am having the issue as well.

TechSakima avatar Oct 31 '25 15:10 TechSakima

Hello, I’m encountering the same issue with the script version 2.48 (main) where tidal-dl stops working due to the API changes in Tidal. Could you please advise if a fix or update will be released in the near term? Thank you for your time and effort.

Tubeman-cell avatar Oct 31 '25 18:10 Tubeman-cell

This indeed would be great as Tidal is now basically broken for both audio and video.

Someone had looked into this before: https://github.com/RandomNinjaAtk/arr-scripts/issues/289

If anyone knows how to do, maybe help with a pull request?

steve1977 avatar Nov 01 '25 13:11 steve1977

Any chance of getting this updated?? There seems to be a fix to the API and Tidal-dl exe is now working again as referenced here: https://github.com/yaronzz/Tidal-Media-Downloader-PRO/issues/327#issuecomment-3425765326

SeadogsBooty avatar Nov 03 '25 15:11 SeadogsBooty

FYI: I haven't been actively working on this project because I haven't been actively using it, especially when Lidarr broke many months ago. I do plan to circle back to this but have been mostly waiting for Lidarr to be fully functional again. Which I believe the metadata service is still a work in progress, even though it is working at this time

RandomNinjaAtk avatar Nov 05 '25 18:11 RandomNinjaAtk

Thanks @RandomNinjaAtk , great you are planning to eventually get back to it. This will be great!

I've been following the metadata issue. It is actually fully functioning again by now and quite stable. There remain issues with spotify playlists and also the Apple Music / Itunes playlists as well as artist art not being displayed. But that feels minor to me.

The broken tidal-dl support is quite annoying. And the fix isn't as easy and less in your hands. Not sure what the effort would be to move to tidal-dl-ng, which would solve it. The other solution would be for someone to send a fix or fork tidal-dl. Tidal-dl seems abandoned.

Out of curiosity, what feature will you be using and is the video support with tidal & imvdb among them? Maybe the video support could be added as a plugin to lidarr plugin branch? The plugin branch is quite clean and stable.

steve1977 avatar Nov 05 '25 22:11 steve1977

Thank you @RandomNinjaAtk for your plug-ins that I have been using for many years now. I hopped back into this project now that the Lidarr metadata server is back up but was devastated to see that tidal-dl functionality had broken in the meantime. Hopefully the solution is somewhat easy!

manifoldcuriosity avatar Nov 06 '25 18:11 manifoldcuriosity

Can confirm that the Lidarr metadata server is up for the most part! Personally my Lidarr instance works as expected again and I have no trouble finding any of my more obscure artists/albums

PixNyb avatar Nov 08 '25 18:11 PixNyb

Someone has fixed tidal-dl, so we should be game again. Can you use the forked branch with the fix?

https://github.com/devicelocksmith/Tidal-Media-Downloader

steve1977 avatar Nov 15 '25 09:11 steve1977

Someone has fixed tidal-dl, so we should be game again. Can you use the forked branch with the fix?

https://github.com/devicelocksmith/Tidal-Media-Downloader

i tried dropping this in as a direct replacement for the deprecated tidal-dl, but i cannot get it to log in successfully. i keep getting blocked on tidals end. Has anyone else been able to log in with the new tidal-dl by @devicelocksmith ?

mrlespaulman avatar Nov 17 '25 16:11 mrlespaulman

I've tried this as well, altered the startup script to use the fork instead but was also unable to log in even doing it manually from within the lidarr container

PixNyb avatar Nov 17 '25 16:11 PixNyb

I may try rewriting my local files in my container to use tidal-dl-ng instead, but i suspect that will be a major rewrite. has anyone tried logging in with tidal-dl-ng lately?

mrlespaulman avatar Nov 17 '25 16:11 mrlespaulman

@mrlespaulman tidal-dl-ng works just fine for me, but the commands and configuration are a bit different so it would be quite the rewrite I believe

PixNyb avatar Nov 17 '25 18:11 PixNyb

It seems @devicelocksmith fork will be our best bet and should work without any adjustments a Did anyone succeed to get it running? I don’t even know how to do so. I ran it independent of this script and it works flawlessly.

steve1977 avatar Nov 20 '25 02:11 steve1977

It seems @devicelocksmith fork will be our best bet and should work without any adjustments a Did anyone succeed to get it running? I don’t even know how to do so. I ran it independent of this script and it works flawlessly.

I had no luck with authorization. I ran it independently and could not get it authorized with my Tidal account--keeps saying "You have been blocked" both on and off VPN. What user-agent are you using to authorize? I tried TV, and a few others with no luck.

mrlespaulman avatar Nov 20 '25 04:11 mrlespaulman

It seems @devicelocksmith fork will be our best bet and should work without any adjustments a Did anyone succeed to get it running? I don’t even know how to do so. I ran it independent of this script and it works flawlessly.

I had no luck with authorization. I ran it independently and could not get it authorized with my Tidal account--keeps saying "You have been blocked" both on and off VPN. What user-agent are you using to authorize? I tried TV, and a few others with no luck.

Do you know how I can download and use the forked tidal-dl file in this script instead? I am happy to troubleshoot and am quite confident that things will work again once the fork is installed. I couldn't find in the code though where tidal-dl is being downloaded / installed inside the docker.

https://github.com/devicelocksmith/Tidal-Media-Downloader

steve1977 avatar Nov 21 '25 23:11 steve1977

I've tried this as well, altered the startup script to use the fork instead but was also unable to log in even doing it manually from within the lidarr container

Mind sharing how you altered the startup script? Curious how to install the fork in the container.

steve1977 avatar Nov 22 '25 01:11 steve1977

And here is a link clarifying how to use the fork

https://github.com/yaronzz/Tidal-Media-Downloader/issues/1204

steve1977 avatar Nov 22 '25 01:11 steve1977