alex-i07 commited on
Commit
355ad4a
·
1 Parent(s): b3cdce6

verify = false

Browse files
Files changed (1) hide show
  1. tools.py +3 -3
tools.py CHANGED
@@ -266,9 +266,9 @@ def _fetch_ddg_search_result_links(query: str) -> ResultSet[PageElement | Tag |
266
  'kl': 'us-en'
267
  }
268
 
269
- ddg_response = requests.get(url, headers=headers, params=params, verify=certifi.where())
270
  ddg_response.raise_for_status()
271
-
272
  soup = BeautifulSoup(ddg_response.text, 'html.parser')
273
  return soup.find_all('a', {'class': 'result-link'})
274
 
@@ -280,7 +280,7 @@ def _fetch_specific_page(url: str) -> str:
280
  'Accept-Language': 'en-US,en;q=0.5',
281
  }
282
 
283
- wiki_response = requests.get(url, headers=headers, verify=certifi.where())
284
  wiki_response.raise_for_status()
285
 
286
  soup = BeautifulSoup(wiki_response.text, 'html.parser')
 
266
  'kl': 'us-en'
267
  }
268
 
269
+ ddg_response = requests.get(url, headers=headers, params=params, verify=False)
270
  ddg_response.raise_for_status()
271
+ print(ddg_response.text)
272
  soup = BeautifulSoup(ddg_response.text, 'html.parser')
273
  return soup.find_all('a', {'class': 'result-link'})
274
 
 
280
  'Accept-Language': 'en-US,en;q=0.5',
281
  }
282
 
283
+ wiki_response = requests.get(url, headers=headers, verify=False)
284
  wiki_response.raise_for_status()
285
 
286
  soup = BeautifulSoup(wiki_response.text, 'html.parser')