DLL load failed when importing PySide2, only while debugging

capitan

Im facing a strange issue. I have downloaded and installed the Qt for Python library (PySide2) in the virtual environment of my project in PyCharm. I have created a dummy GUI using the Qt Designer and Im loading (.ui file) and displaying the GUI through my python code. Whenever I run the code, I can see the GUI without errors. However, whenever I debug the code, I get an error:

File "...\gui_pyside2.py", line 5, in

from PySide2.QtWidgets import QApplication, QLabel, QLineEdit

ImportError: DLL load failed: The specified procedure could not be found.

Pydev crashes on this line:

#execute the script (note: it's important to compile first to have the filename set in debug mode)
exec(compile(contents+"\n", file, 'exec'), glob, loc)

Im pretty lost on what could be the cause. It seems like pydev is interfering with the imports? I have tried using import statements instead of from import but the problem persists. Any ideas?

Versions installed:

  • PyCharm Community 2018.1.4
  • pydev debugger (build 181.5087.37)
  • Python 3.6.6 (v3.6.6:4cf1f54eb7, Jun 27 2018, 03:37:03) [MSC v.1900 64 bit (AMD64)]
  • PySide2-5.11.1a1.dev1530373667-5.11.1.dist (technical preview, python binding to Qt 5.11)
capitan

Answering to my own question:

Turns out there's a compatibility setting in Pycharm for Pyside:

PySide compatibility

Set it to PySide and debugger runs.

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Java

DLL load failed error when importing cv2

From Dev

"ImportError: DLL load failed" when importing tensorflow

From Dev

PySide2: DLL load failed: The specified procedure could not be found

From Dev

"ImportError: DLL load failed while importing" while using PyInstaller

From Dev

ImportError: DLL load failed while importing numpy_ops: The specified module could not be found. when importing spacy in Python

From Dev

"ImportError: DLL load failed while importing _openmp_helpers"?

From Dev

DLL load failed: The specified module could not be found while importing scipy

From Dev

Jupyter notebook does not launch (ImportError: DLL load failed while importing)

From Dev

How to fix "DLL load failed while importing QtWidgets"?

From Dev

DLL load failed while importing ft2font: The specified module could not be found

From Java

DLL load failed when importing PyQt5

From Dev

DLL load failed when importing TensorFlow with GPU support

From Dev

How to find which DLL failed in "ImportError: DLL load failed while importing" in python?

From Dev

ImportError while importing PySide2

From Dev

cx_Freeze ImportError: DLL load failed failed while importing _ctypes: The specified module could not be found

From Dev

Exception has occurred: ImportError DLL load failed while importing pdftotext: The specified module could not be found

From Dev

ImportError: DLL load failed while importing _psycopg: The specified module could not be found

From Dev

ImportError: DLL load failed while importing pyexpat: The specified module could not be found

From Dev

DLL load failed while importing aggregations: The specified module could not be found pyhton pandas excel files merging

From Dev

How to fix "ImportError: DLL load failed" while importing win32api

From Dev

Pyinstaller ImportError : DLL load failed while importing win32gui

From Dev

How to fix 'ImportError: DLL load failed: The specified procedure could not be found.' while importing tensorflow-gpu?

From Dev

(ibm_db) ImportError: DLL load failed while importing ibm_db: The specified module could not be found

From Dev

Tensorflow installation on Windows: DLL load failed while importing _pywrap_tensorflow_internal

From Dev

ImportError: DLL load failed while importing QtWebKit: Le module spécifié est introuvable

From Dev

SWIG doesn't work on Windows with MinGW-w64 when binding C++ and Python: DLL load failed while importing: The specified module could not be found

From Dev

Failed to load file while importing modules in python

From Dev

TensorFlow Error: ImportError: DLL load failed with error code 3221225501 while importing _pywrap_ tensorflow_internal in Python3.8

From Python

Cannot import from pywinauto: ImportError: DLL load failed while importing win32ui: A dynamic link library (DLL) initialization routine failed

Related Related

  1. 1

    DLL load failed error when importing cv2

  2. 2

    "ImportError: DLL load failed" when importing tensorflow

  3. 3

    PySide2: DLL load failed: The specified procedure could not be found

  4. 4

    "ImportError: DLL load failed while importing" while using PyInstaller

  5. 5

    ImportError: DLL load failed while importing numpy_ops: The specified module could not be found. when importing spacy in Python

  6. 6

    "ImportError: DLL load failed while importing _openmp_helpers"?

  7. 7

    DLL load failed: The specified module could not be found while importing scipy

  8. 8

    Jupyter notebook does not launch (ImportError: DLL load failed while importing)

  9. 9

    How to fix "DLL load failed while importing QtWidgets"?

  10. 10

    DLL load failed while importing ft2font: The specified module could not be found

  11. 11

    DLL load failed when importing PyQt5

  12. 12

    DLL load failed when importing TensorFlow with GPU support

  13. 13

    How to find which DLL failed in "ImportError: DLL load failed while importing" in python?

  14. 14

    ImportError while importing PySide2

  15. 15

    cx_Freeze ImportError: DLL load failed failed while importing _ctypes: The specified module could not be found

  16. 16

    Exception has occurred: ImportError DLL load failed while importing pdftotext: The specified module could not be found

  17. 17

    ImportError: DLL load failed while importing _psycopg: The specified module could not be found

  18. 18

    ImportError: DLL load failed while importing pyexpat: The specified module could not be found

  19. 19

    DLL load failed while importing aggregations: The specified module could not be found pyhton pandas excel files merging

  20. 20

    How to fix "ImportError: DLL load failed" while importing win32api

  21. 21

    Pyinstaller ImportError : DLL load failed while importing win32gui

  22. 22

    How to fix 'ImportError: DLL load failed: The specified procedure could not be found.' while importing tensorflow-gpu?

  23. 23

    (ibm_db) ImportError: DLL load failed while importing ibm_db: The specified module could not be found

  24. 24

    Tensorflow installation on Windows: DLL load failed while importing _pywrap_tensorflow_internal

  25. 25

    ImportError: DLL load failed while importing QtWebKit: Le module spécifié est introuvable

  26. 26

    SWIG doesn't work on Windows with MinGW-w64 when binding C++ and Python: DLL load failed while importing: The specified module could not be found

  27. 27

    Failed to load file while importing modules in python

  28. 28

    TensorFlow Error: ImportError: DLL load failed with error code 3221225501 while importing _pywrap_ tensorflow_internal in Python3.8

  29. 29

    Cannot import from pywinauto: ImportError: DLL load failed while importing win32ui: A dynamic link library (DLL) initialization routine failed

HotTag

Archive