Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Freyr failed when using Apple Music with [Request failed with status code 401] #497

Closed
sjvolkmann opened this issue Apr 25, 2023 · 7 comments

Comments

@sjvolkmann
Copy link

sjvolkmann commented Apr 25, 2023

I tried it both with single titles and with playlists, both keeps failing.

sjvolkmann@Killarnees-iMac ~ % freyr "https://music.apple.com/de/album/dont-talk-to-me-that-way-instrumental-version/1494882527?i=1494882538&l=en"
    ____                    
   / __/_______  __  _______
  / /_/ ___/ _ \/ / / / ___/
 / __/ /  /  __/ /_/ / /    
/_/ /_/   \___/\__, /_/     
              /____/ v0.9.0

freyr - (c) Miraculous Owonubi <omiraculous@gmail.com>
------------------------------------------------------
Checking directory permissions...[done] 
[https://music.apple.com/de/album/dont-talk-to-me-that-way-instrumental-version/1494882527?i=1494882538&l=en]
 [•] Identifying service...[Apple Music]
 [•] Checking authentication...[authenticated]
 Detected [track]
 Obtaining track metadata...(failed: [Request failed with status code 401]) 
 [i] An error occurred while processing the query
============ Stats ============
 [•] Runtime: [1.1s]
 [•] Total queries: [01]
 [•] Total tracks: [00]
     » Skipped: [00]
     ✓ Passed:  [00]
     ✕ Failed:  [00]
 [•] Output directory: [.]
 [•] Total Output size: 0.00 B
 [•] Total Network Usage: 0.00 B
     ♫ Media: 0.00 B
     ➤ Album Art: 0.00 B
 [•] Output bitrate: 320k
===============================

Freyr v0.9.0 via Docker on macOS 12.6.5

@canpoyrazoglu
Copy link

Same. I'm trying Freyr for the first time, I'm logged in to Apple Music, but I'm getting 401 errors. I don't know what to do.

@miraclx
Copy link
Owner

miraclx commented Apr 29, 2023

Duplicate of #452. Pull freyr from master.

npm install miraclx/freyr-js

@miraclx miraclx closed this as completed Apr 29, 2023
@sjvolkmann
Copy link
Author

@miraclx Okay, thanks.

For those who don't know how to (on Mac):

  1. install homebrew (Link),
  2. install npm brew npm and atomicparsley brew atomicparsley using homebrew,
  3. and run freyr npx freyr [link] (music will be saved to home folder).

Maybe would be good to add this to the repo's README.

But now there is another issue:

sjvolkmann@Killarnees-iMac ~ % npx freyr "https://music.apple.com/de/album/where-the-wind-will-blow-feat-zandra-ernebro/1584625980?i=1584625983&l=en"
    ____                    
   / __/_______  __  _______
  / /_/ ___/ _ \/ / / / ___/
 / __/ /  /  __/ /_/ / /    
/_/ /_/   \___/\__, /_/     
              /____/ v0.9.1

freyr - (c) Miraculous Owonubi <omiraculous@gmail.com>
------------------------------------------------------
Checking directory permissions...[done] 
[https://music.apple.com/de/album/where-the-wind-will-blow-feat-zandra-ernebro/1584625980?i=1584625983&l=en]
 [•] Identifying service...[Apple Music]
 [•] Checking authentication...[authenticated]
 Detected [track]
 Obtaining track metadata...[done] 
  ➤ Title: Where the Wind Will Blow (feat. Zandra Ernebro)
  ➤ Album: Little by Little
  ➤ Artist: LAYN
  ➤ Year: 2016
  ➤ Playtime: 02:53
 [•] Collating...
 • [03 Where the Wind Will Blow (feat. Zandra Ernebro)]
    | ➤ Collating sources...
    |  ➤ [•] YouTube Music...[success, found 1 source]
    | ➤ Awaiting audiofeeds...[done] 
    | [✓] Got album art 
    | [✓] Got raw track file 
    | [•] Post Processing...
 [•] Download Complete
 [•] Embedding Metadata...
  • [✓] 03 Where the Wind Will Blow (feat. Zandra Ernebro)
[•] Collation Complete
============ Stats ============
 [•] Runtime: [25m 7.6s]
 [•] Total queries: [01]
 [•] Total tracks: [01]
     » Skipped: [00]
     ✓ Passed:  [01]
     ✕ Failed:  [00]
 [•] Output directory: [.]
 [•] Total Output size: 536.75 MB
 [•] Total Network Usage: 3.37 MB
     ♫ Media: 3.27 MB
     ➤ Album Art: 101.21 KB
 [•] Output bitrate: 320k
===============================

25 minutes runtime with an output of 537 MB for a three minutes title, is this reproducible? The moment when it got stuck and added all these bytes was at Embedding Metadata...

@sjvolkmann
Copy link
Author

Same. I'm trying Freyr for the first time, I'm logged in to Apple Music, but I'm getting 401 errors. I don't know what to do.

@canpoyrazoglu Does it work for you when using npm?

@miraclx
Copy link
Owner

miraclx commented Apr 30, 2023

@sjvolkmann, that issue was reported and addressed in #437 (comment).

This was caused by buffer overflows in AtomicParsley, which have now been resolved. The docker images have been updated following #476. You can download binaries from https://github.com/miraclx/atomicparsley/releases/tag/20230114.175602.21bde60.

@sjvolkmann
Copy link
Author

Then replacing the binary inside /usr/local/Cellar/atomicparsley/20221229.172126.d813aa6 does solve the problem.

Thanks a lot.

@miraclx
Copy link
Owner

miraclx commented Aug 8, 2023

v0.10.0 has been released with this fix.

https://github.com/miraclx/freyr-js/releases/tag/v0.10.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants