Ask.fm crawler
askfm.py is no longer maintained. Please consider using other library if you want to crawl ask.fm.
$ pip install askfm.py
This program shows recent 25 answers of ezoeryou.
import askfm
crawler = askfm.Crawler('ezoeryou')
for pair in crawler.crawl():
print(pair.question, '->', pair.answer)
Initializes ask.fm crawler.
username
: the username you want to crawl answers.
Fetches at most 25 answers and returns iterator of list of answers.
page
: the offset page. The default value is0
, this means crawing at the top of answers.
A generator that yields askfm.Crawler.crawl(page)
continuously.
Uses like this:
# offset_page is given
for page in crawler.pager(offset_page):
for pair in page:
print(pair.question, pair.answer)
page
: the offset page. The default value is0
, this means crawing at the top of answers.
An iterator of continuous askfm.Pair
objects.
An object representing for pair of question and answer.
You can get them with askfm.Pair.question
and askfm.Pair.answer
.