SerpScrap icon indicating copy to clipboard operation
SerpScrap copied to clipboard

num_results_per_page is not working as expected

Open kodfactory opened this issue 5 years ago • 1 comments

Hi,

First of all thank you for making such a great library.

I am trying to play around with it using python 3.

Below is my sample code but i am not able to limit the number of searches.

import pprint
import serpscrap

keywords = ['Virendra Sahewag']

config = serpscrap.Config()
config.set('scrape_urls', False)
config.set('num_pages_for_keyword', 2)
config.set('num_results_per_page', 3)

scrap = serpscrap.SerpScrap()
scrap.init(config=config.get(), keywords=keywords)
results = scrap.run()

for result in results:
    pprint.pprint(result)

I tried to change num_pages_for_keyword and num_results_per_page but in most of case, it is giving me 30 results always.

If anyone can help me about it.

Thanks! Jayesh

kodfactory avatar Nov 27 '19 05:11 kodfactory

Hi,

Anyone here can assist me?

kodfactory avatar Dec 07 '19 06:12 kodfactory