From c6e85e5545fb94be31342d54c151012d883536b9 Mon Sep 17 00:00:00 2001 From: "jules@lens" Date: Wed, 5 Jun 2019 16:38:43 +0200 Subject: update search citations --- scraper/s2-search-deep.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'scraper/s2-search-deep.py') diff --git a/scraper/s2-search-deep.py b/scraper/s2-search-deep.py index ab44c351..b5dc640e 100644 --- a/scraper/s2-search-deep.py +++ b/scraper/s2-search-deep.py @@ -31,7 +31,7 @@ MAX_PAGES = 20 def fetch_query(query, since=None, refresh=False): clean_title = re.sub(r'[^-0-9a-zA-Z ]+', '', query) - if since and since != '#N/A': + if since: yearFilter = {'min': since, 'max': 2020 } else: yearFilter = None @@ -80,7 +80,10 @@ def search_deep(refresh): since = row['since'] if not since: continue - since = int(since) + if since == '#N/A': + since = None + else: + since = int(since) queries = [] row_paper_ids = {} for i in range(1, 6): -- cgit v1.2.3-70-g09d2