serpapi-python icon indicating copy to clipboard operation
serpapi-python copied to clipboard

Enforce `‎SerpResults.yield_pages` to start from the first page

Open ilyazub opened this issue 7 months ago • 1 comments

Currently, ‎SerpResults.yield_pages skips the first page. Because of that, it's required to duplicate the results processing in the clients' code.

https://github.com/serpapi/serpapi-python/blob/44e41d36723da1e95e4ac165c08b6c98e6a95027/serpapi/models.py#L74-L78

Let's yield current_page before entering the pagination loop.

@kennethreitz @jvmvik

ilyazub avatar Nov 17 '23 12:11 ilyazub