twint
twint copied to clipboard
Wiki Mistakes: attributes for custom formatting
trafficstars
Wiki needs a minor update
Using datestamp from tweet attributes returns and error. It works when using date instead.
Code to test
This works
import twint
import nest_asyncio
nest_asyncio.apply()
c = twint.Config()
c.Search = "bitcoin"
c.Min_likes = 2500
c.Custom["tweet"] = ["date", "tweet"]
twint.run.Search(c)
This doesn't
import twint
import nest_asyncio
nest_asyncio.apply()
c = twint.Config()
c.Search = "bitcoin"
c.Min_likes = 2500
c.Custom["tweet"] = ["datestamp", "tweet"]
twint.run.Search(c)
Update
| In Wiki | What Actually Works | Where |
|---|---|---|
datestamp |
date |
tweet attributes |
timestamp |
time |
tweet attributes |
avatar |
profile_image_url |
user attributes |
~Hi all, looks like the "created_at" attribute doesn't work either~
Cancel cancel, I didn't realise that the attributes you use in the .Format() sub don't match with the ones you use in the .custom sub