After running the scrapy shell with the defined url, I am getting the attribute error showing the following error: AttributeError: module 'OpenSSL.SSL' has no attribute 'SSLv3_METHOD'
scrapy shell "https://quotes.toscrape.com/tag/humor/"
Can anyone please help me solving the error?
2022-09-27 01:38:38 [scrapy.utils.log] INFO: Versions: lxml 4.9.1.0, libxml2 2.9.12, cssselect 1.1.0, parsel 1.6.0, w3lib 2.0.1, Twisted 22.8.0, Python 3.9.2 (tags/v3.9.2:1a79785, Feb 19 2021, 13:44:55) [MSC v.1928 64 bit (AMD64)], pyOpenSSL 22.1.0 (OpenSSL 3.0.5 5 Jul 2022), cryptography 38.0.1, Platform Windows-10-10.0.19041-SP0
2022-09-27 01:38:38 [scrapy.crawler] INFO: Overridden settings:
{'DUPEFILTER_CLASS': 'scrapy.dupefilters.BaseDupeFilter',
'LOGSTATS_INTERVAL': 0}
2022-09-27 01:38:38 [scrapy.utils.log] DEBUG: Using reactor: twisted.internet.selectreactor.SelectReactor
2022-09-27 01:38:38 [scrapy.extensions.telnet] INFO: Telnet Password: d760ab2d8573ec57
2022-09-27 01:38:38 [scrapy.middleware] INFO: Enabled extensions:
['scrapy.extensions.corestats.CoreStats',
'scrapy.extensions.telnet.TelnetConsole']
2022-09-27 01:38:39 [scrapy.core.downloader.handlers] ERROR: Loading "scrapy.core.downloader.handlers.http.HTTPDownloadHandler" for scheme "http"
Traceback (most recent call last):
File "d:\python\scraping-project\scrapy\venv\lib\site-packages\scrapy\core\downloader\handlers\__init__.py", line 49, in _load_handler
dhcls = load_object(path)
File "d:\python\scraping-project\scrapy\venv\lib\site-packages\scrapy\utils\misc.py", line 61, in load_object
mod = import_module(module)
File "C:\Users\DELL\AppData\Local\Programs\Python\Python39\lib\importlib\__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 790, in exec_module
File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
File "d:\python\scraping-project\scrapy\venv\lib\site-packages\scrapy\core\downloader\handlers\http.py", line 2, in <module>
from scrapy.core.downloader.handlers.http11 import (
File "d:\python\scraping-project\scrapy\venv\lib\site-packages\scrapy\core\downloader\handlers\http11.py", line 23, in <module>
from scrapy.core.downloader.contextfactory import load_context_factory_from_settings
File "d:\python\scraping-project\scrapy\venv\lib\site-packages\scrapy\core\downloader\contextfactory.py", line 11, in <module>
from scrapy.core.downloader.tls import DEFAULT_CIPHERS, openssl_methods, ScrapyClientTLSOptions
File "d:\python\scraping-project\scrapy\venv\lib\site-packages\scrapy\core\downloader\tls.py", line 23, in <module>
METHOD_SSLv3: SSL.SSLv3_METHOD, # SSL 3 (NOT recommended)
AttributeError: module 'OpenSSL.SSL' has no attribute 'SSLv3_METHOD'