Hello, I'm new to github so I'm not sure if this is the correct spot for this, but I'm having an issue trying to write some data to a CSV.
I keep receiving "TypeError: 'NoneType' object is not subscriptable."
Here is the full error I am getting.
Traceback (most recent call last):
File "spoti_api.py", line 199, in
main()
File "spoti_api.py", line 53, in main
write_playlist(playlist[1], playlist[0], mode)
File "spoti_api.py", line 81, in write_playlist
old_total = write_csv(filename, tracks)
File "spoti_api.py", line 177, in write_csv
track_url = track['external_urls']['spotify']
TypeError: 'NoneType' object is not subscriptable
I entered my valid CLI_ID & CLI_KEY and set the mode to CSV, as well as entered the filepath correctly for the output. I apologize I am pretty new to python, and have never worked with an API before so I am fairly clueless about what I'm doing here.
Am I missing something? Thanks.