0

Django project which examines the frequency of occurrence of words on the blog.

the project is not finished yet but the scraper did not give any errors before. The error appeared after switching to another komupter, but I'm not sure if it matters

when I try to run my scraping script I get this error:

ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:852)

ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:852)

I tried to use the time function but it didn't help

import time
time.sleep(5)
tbone
  • 1,148
  • 5
  • 19
  • 35

2 Answers2

1

Make sure that you've got the root certificates installed on the new machine.

I cannot tell from the screenshot on what kind of system you work. If it's a Mac, see
Mac OSX python ssl.SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:749)

Roland Weber
  • 1,865
  • 2
  • 17
  • 27
0

import ssl

ssl._create_default_https_context = ssl._create_unverified_context