sonoramac / Sonora

A minimal, beautifully designed music player for OS X.
http://getsonora.com
Other
932 stars 135 forks source link

Fix last.fm API key #48

Open enrique-ramirez opened 11 years ago

enrique-ramirez commented 11 years ago

After downloading the latest version of sonora (to get rid of the expiry message), last.fm integration has stopped working. Sonora's preferences tab showed I was connected, but the songs would not scrobble.

After clicking on Sign out and then Sign in (which, by the way, is still a Sign Out button) I get taken to last.fm/s homepage and greeted with this warning:

Screen Shot 2012-12-10 at 1.57.20 PM.png

(Check the URL!)

I miss my scrobbling. :( Please bring it back!

macchina50 commented 11 years ago

Hi,

The API keys are not included in the code ("_LASTFM_APIKEY " in the url is a placeholder). I think they were removed because the app is open source and last.fm recommends not distributing keys. (However, according to this this thread, I think it would be permissible to include keys in the Sonora code.)

Anyway, if you want to scrobble with Sonora, here is what you need to do:

  1. Register an API account with last.fm
  2. Fill out your account info however you wish, but be sure to specify "sonora://lastfmauth/" as the callback url
  3. Download the source code, insert your API/Secret keys in SNRConstants.m and remove the warning
  4. Compile the source in Xcode according to the instructions in the readme

Hopefully, that makes sense. This took me forever to figure out myself (especially step 2), mainly because I'd never touched a line of code before and therefore had no clue what I was doing. However, my Sonora scrobbler now works, and it's actually pretty easy to set up once you have the above info.

Cheers!

enrique-ramirez commented 11 years ago

Hi macchina,

Thanks for the info! Will do this for the time being. :) It does make sense that they don't want to spread the API key... will await for a response from Indragie.

indragiek commented 11 years ago

Hey guys,

Thanks for pointing this out. I'll have to think a bit about whether publicizing the API key is the best option, but I'll get back to this soon!

metbril commented 11 years ago

Wouldn't it be an option to only include the API key AND secret in the comiled version that is made available through getsonora.com?

florianeckerstorfer commented 11 years ago

@indragiek Or make it possible to enter my personal API key and secret in the preferences window?

wwqrd commented 11 years ago

+1 florianeckerstorfer's idea

yuvadm commented 9 years ago

+1 @florianeckerstorfer

Ardakilic commented 9 years ago

+1 @florianeckerstorfer