serpapi-python
serpapi-python copied to clipboard
Enforce `SerpResults.yield_pages` to start from the first page
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 I tried to update the method in this PR https://github.com/serpapi/serpapi-python/pull/13 , as well as the test to be more precise.