DocNow / twarc

A command line tool (and Python library) for archiving Twitter JSON
https://twarc-project.readthedocs.io
MIT License
1.36k stars 255 forks source link

discover_ids.py #375

Closed ameliameyer closed 3 years ago

ameliameyer commented 3 years ago

When I use the command 'python utils/discover_ids.py '#olympicgold' > ids.txt ', I receive the following error.

C:\Users\user\Desktop\twarc>python utils/discover_ids.py '#olympicgold' > ids.txt Traceback (most recent call last): File "utils/discover_ids.py", line 79, in main() File "utils/discover_ids.py", line 33, in main for id in discover_ids(args.query): File "utils/discover_ids.py", line 57, in discover_ids s = json.loads(r.content) File "C:\Users\user\AppData\Local\Programs\Python\Python37-32\lib\json__init__.py", line 348, in loads return _default_decoder.decode(s) File "C:\Users\user\AppData\Local\Programs\Python\Python37-32\lib\json\decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "C:\Users\usery\AppData\Local\Programs\Python\Python37-32\lib\json\decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

edsu commented 3 years ago

Unfortunately this utility is no longer supported since the undocumented API that Twitter had has been changed. twarc really is a tool designed for working with Twitter's documented API. I recommend you take a look at either of these projects since they try to keep up to date with all the changes Twitter make to their user interface.

ameliameyer commented 3 years ago

Ah, I see. Thank you!