-
Notifications
You must be signed in to change notification settings - Fork 75
Open
Description
Hey all, trying to use this library to get some cricket data from ESPN Cricinfo.
I think they've added some kind of authentication to their API recently meaning it's impossible to scrape.
Does anybody have any ideas?
Thanks
Describe the bug
Unable to run the example from the readme
To Reproduce
>>> from espncricinfo.summary import Summary
>>> s = Summary()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/jacoboxford/.virtualenvs/espncricinfo/lib/python3.12/site-packages/espncricinfo/summary.py", line 12, in __init__
self.match_ids = self._match_ids()
^^^^^^^^^^^^^^^^^
File "/Users/jacoboxford/.virtualenvs/espncricinfo/lib/python3.12/site-packages/espncricinfo/summary.py", line 30, in _match_ids
matches = [x['id'] for x in self.summary_json()['props']['pageProps']['data']['content']['leagueEvents'][0]['matchEvents']]
~~~~~~~~~~~~~~~~~~~^^^^^^^^^
TypeError: 'NoneType' object is not subscriptable
>>>Expected behavior
I would expect something to be returned without erroring out for me!
erikw
Metadata
Metadata
Assignees
Labels
No labels