crawling with python algorithm