johnwmillr / LyricsGenius

Download song lyrics and metadata from Genius.com 🎶🎤
http://www.johnwmillr.com/scraping-genius-lyrics/
MIT License
892 stars 158 forks source link

NoneType error while calling genius.search_song when deployed #164

Closed prkhandelwal closed 3 years ago

prkhandelwal commented 3 years ago

Describe the bug Receiving Result: Failure Exception: TypeError: 'NoneType' object is not subscriptable when calling genius.search_song. The app is an Azure Function serverless app. The code works fine locally, but the error comes when when it is deployed.

To Reproduce

  1. Create an Azure functions app
  2. Use the call genius.search_song after initializing genius client
allerter commented 3 years ago

If the code works fine locally, but not when it's deployed, then there's probably a problem when the Azure tries to communicate with Genius. So I don't think this is an issue with the package, rather with the deployment. Setting genius.verbose=True can help with finding out which part of the search has failed.