Closed DenizDalkilic10 closed 4 years ago
import twint
c = twint.Config()
c.Username = "twitter"
c.Store_object = True
twint.run.Lookup(c)
user = twint.output.users_list[0]
print(user.join_date)
That test case doesn't appear to work on master post 8dbe139; it did however work on previous versions. (last working version was 2.1.18)
@minimaxir May you post a screenshot where you show the imported version of Twint of the code executed?
Hi @pielco11 , I am using 2.1.20 and I have the same problem, twint.output.users_list returns an empty list.
may you reproduce this, please?
Same here, it's empty.
[lx@host ~ 1363 ] pip3 show twint
Name: twint
Version: 2.1.20
Summary: An advanced Twitter scraping & OSINT tool.
Home-page: https://github.com/twintproject/twint
Author: Cody Zacharias
Author-email: codyzacharias@pm.me
License: MIT
Location: /usr/local/lib/python3.7/site-packages
Requires: aiohttp-socks, cchardet, aiohttp, fake-useragent, pandas, beautifulsoup4, elasticsearch, aiodns, schedule, googletransx, geopy, pysocks
Required-by:
[lx@host ~ 1364 ] python3.7 /tmp/foo.py
CRITICAL:root:twint.get:User:'NoneType' object is not subscriptable
Traceback (most recent call last):
File "/tmp/foo.py", line 7, in <module>
user = twint.output.users_list[0]
IndexError: list index out of range
[lx@host ~ 1365 ] cat /tmp/foo.py
import twint
c = twint.Config()
c.Username = "twitter"
c.Store_object = True
twint.run.Lookup(c)
user = twint.output.users_list[0]
print(user.join_date)
print(twint.__version__)
I have the same issue but I was able to reproduce both cases: failure and success. When you install pointing directly to Github repo (with editable mode or not - doesn't matter):
pip3 install --user --upgrade -e git+https://github.com/twintproject/twint.git@origin/master#egg=twint
it works but when you just execute:
pip3 install twint
it doesn't work. It seems that for both cases version is the same: 2.1.20
. As I can see last version on pypi.org has been pushed on 29th April but master on Github has been updated in last month, so probably it contains fix for this issue.
Command Ran
Description of Issue
Can not Retrieve User Object to Ram after twint.run.Lookup(c) and twint.output.users_list. I believe that using twint.output.users_list after calling Lookup is wrong but could not find a correct version in the Wiki for saving a specific account as an User object
Environment Details
Windows and Pycharm