Import Error:DLL failed when using scrapy in command prompt
I am getting the below issue when trying to create a folder using the scrapy command. I tried searching for this issue and found a solution at https://groups.google.com/forum/#!topic/scrapy-users/8N6V_OGUqtI I tried the steps provided there and still I am getting this issue.
Any help in getting this resolved would be appreciated.
(C:\Users\dell\Anaconda3) C:\Users\dell>activate scrapy-env (scrapy-env) C:\Users\dell>scrapy startproject tutorial Traceback (most recent call last): File "C:\Users\dell\Anaconda3\envs\scrapy-env\Scripts\scrapy-script.py", line 5, in <module> sys.exit(scrapy.cmdline.execute()) File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\scrapy\cmdline.py", line 128, in execute cmds = _get_commands_dict(settings, inproject) File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\scrapy\cmdline.py", line 46, in _get_commands_dict cmds = _get_commands_from_module('scrapy.commands', inproject) File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\scrapy\cmdline.py", line 29, in _get_commands_from_module for cmd in _iter_command_classes(module): File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\scrapy\cmdline.py", line 19, in _iter_command_classes for module in walk_modules(module_name): File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\scrapy\utils\misc.py", line 71, in walk_modules submod = import_module(fullpath) File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\importlib\__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 994, in _gcd_import File "<frozen importlib._bootstrap>", line 971, in _find_and_load File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 665, in _load_unlocked File "<frozen importlib._bootstrap_external>", line 678, in exec_module File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\scrapy\commands\version.py", line 6, in <module> import OpenSSL File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\OpenSSL\__init__.py", line 8, in <module> from OpenSSL import rand, crypto, SSL File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\OpenSSL\rand.py", line 10, in <module> from OpenSSL._util import ( File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\OpenSSL\_util.py", line 6, in <module> from cryptography.hazmat.bindings.openssl.binding import Binding File "C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages\cryptography\hazmat\bindings\openssl\binding.py", line 13, in <module> from cryptography.hazmat.bindings._openssl import ffi, lib ImportError: DLL load failed: The operating system cannot run %1.
Just In case someone else end up here this is what worked for me: I had same error while running scrapy from anaconda prompt. By seeing on process monitor, it caused by both dll files cannot be found inside Anaconda3\Lib\site-packages\cryptography\hazmat\bindings. Copy both files from Anaconda3\pkgs\openssl-1.0.2o-h8ea7d77_0\Library\bin into Anaconda3\Lib\site-packages\cryptography\hazmat\bindings, and it works
Get "ImportError: DLL load failed: The operating system cannot run , _openssl import ffi, lib ImportError: DLL load failed: The specified via command line on my own computer and (b) running the exe program Use dependency walker to figure out which DLLs it's missing. Try patching twisted to use pywin32-ctypes if that has the necessary functions. Avoid using twisted or anything else which depends on pywin32.
I had the same problem and found the solution at https://github.com/scrapy/scrapy/issues/3447
conda update -n base conda
And as it turns out, the error occured only within PyCharm and the solution was to install OpenSSL according to https://github.com/conda/conda/issues/8046#issuecomment-450515815
Issues with scrapy (cryptography) in application · Issue #120 , So I installed Pytorch with the help of the instructions specified on their website: _C import * ImportError: DLL load failed: The specified procedure could not be found. May I have the output of the following script in CMD? System information Windows 10 Pro Tensorflow 1.13.1 (didn't work with 2.0.0a0 or 1.10.0) python 3.6.8 installed using pip I installed using pip following the instructions on the website. The on
Make sure you installed the right library that matches your Python installation. If you're running Python 32-bit, install the library's 32-bit version. If you're Python x64, install the x64 version of the library. That's the most common cause of this error.
DLL load failed: The specified module could not be found. After , _openssl import ffi, lib ImportError: DLL load failed: The operating system cannot run %1. 1; 2. Solution: Just install a package cryptography , open cmd, enter Are you using deb packages? It is not directly related to Scrapy 1.0 vs Scrapy 0.24 - likely you also updated PyOpenSSL and/or cryptography packages along with Scrapy, and they stopped working for some reason.
Scrapy startproject xxx error, ImportError: DLL load failed: The , from cmd on windows 10, or using python console (Not through pycharm); However, I cannot run this command from any module in pycharm or likely you are trying to import a failed build of numpy. If you're working with a numpy git repo, try git clean -xdf (removes all files not under version control).
ImportError: DLL load failed: The specified procedure could not be , I cannot successfully run the first command in the Scrapy tutorial Getting error: DLL load failed: The operating system cannot run %1 - Python 2.7; Scrapy Module; line 9, in <module> from scrapy.crawler import CrawlerProcess File Home » Python » ImportError: DLL load failed: %1 is not a valid Win32 application. But the DLL's are there But the DLL's are there ImportError: DLL load failed: %1 is not a valid Win32 application.
Swig dll load failed, Working code signing on OS X. Bundles MS Visual C++ DLLs on Windows. (#4166, #4173); New command-line option --upx-exclude, which allows the user to Now prints a more descriptive error when running a tool fails (instead of dumping a This includes bootloader messages, Python's “verbose imports” and store Win10: ImportError: DLL load failed: The specified module could not be found #22794. damcclane opened this issue on Oct 6, 2018 · 177 comments. subtype:windows type:build/install. damcclane commented on Oct 6, 2018 • System information: Have I written custom code: No. OS Platform and Distribution: Windows 10 Pro updated. Mobile device: None.
- Thank you for providing the information. I checked and I am using a 64bit Python. I installed scrapy using pip and conda. Is there any way to install the x64 version of the library
pythonwith no arguments at all. In the first line that describes the version you should see
64 bit (AMD64)or
32 bit. Ignore
win32as it doesn't necessarily mean you're running on 32-bit.
- I checked and I am using a 64bit Python. I installed scrapy using pip and conda. Is there any way to install the x64 version of the library
- If you used (the right) pip, it should already be the right version. But it's not complaining about scrapy, it's complaining about
cryptography.hazmat.bindings._openssl. Did you install that one using pip? Do you have
C:\Users\dell\Anaconda3\envs\scrapy-env\lib\site-packages? Try reinstalling the right
- I have the file _openssl.pyd in the folder C:\Users\dell\Anaconda3\pkgs\cryptography-2.0.3-py36_0\Lib\site-packages\cryptography\hazmat\bindings