Skip to content

[Bug]: boxscore.BoxScore() fails with Access Denied / JSONDecodeError for liveData endpoint #672

@ori-n

Description

@ori-n

NBA API Version

1.11.4

Issue

The following code used to work:

`
from nba_api.live.nba.endpoints import boxscore

boxscore.BoxScore("0042500234")
`

but now fails with:

json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

The failure happens in:

nba_api/live/nba/endpoints/boxscore.py", line 334, in load_response
data_sets = self.nba_response.get_dict()

The underlying response is HTML instead of JSON with:

You don't have permission to access "http://cdn.nba.com/static/json/liveData/boxscore/boxscore_0042500234.json" on this server.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriageResearching into a possible bug

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions