Skip to content

Parsing Error When Pulling Tracks  #17

@mclopes

Description

@mclopes

Hello, I am getting the following error when trying to pull tracks from any genre.

From what I can understand, its no longer able to parse the top 100 data into a readable JSON?

has anyone else ran into this issue and resolved it?

[+] Fetching Top 100 Afro House Tracks
HTTP Status Code: 200
<!DOCTYPE html><html lang="en"><head><meta charSet="utf-8"/><meta name="viewport" content="width=device-width"/><link rel="canonical" hrefLang="en" href="https://www.beatport.com/genre/Afro-House/89/top-100"/><link rel="alternate" hrefLang="de" href="https://www.beatport.com/de/genre/Afro-House/89/top-100"/><link rel="alternate" hrefLang="fr" href="https://www.beatport.com/fr/genre/Afro-House/89/top-100"/><link rel="alternate" hrefLang="es" href="https://www.beatport.com/es/genre/Afro-House/89/t
Accessed URL: https://www.beatport.com/genre/Afro-House/89/top-100
Redirect history: []
Blob content: 
Blob is empty
Traceback (most recent call last):
  File "/Users/marcelo/beatporter.py", line 30, in <module>
    top_100_charts[genre] = beatport.get_top_100_tracks(genre)
  File "/Users/marcelo/beatport.py", line 102, in get_top_100_tracks
    return parse_tracks(raw_tracks_dict)
  File "/Users/marcelo/beatport.py", line 77, in parse_tracks
    for track in tracks_json["tracks"]:
TypeError: 'NoneType' object is not subscriptable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions