Installation problem: Couldn't load plugin 'AequilibraE' due to an error when calling its classFactory() method

1,786 views
Skip to first unread message

Andrés Abarca

unread,
Sep 8, 2020, 8:49:00 AM9/8/20
to AequilibraE
Hi everyone!

I upgraded my QGIS version to 3.10.9 (A Coruña) so that I could use AequilibraE but when I install I get the error:

"Couldn't load plugin 'AequilibraE' due to an error when calling its classFactory() method"

I'm running on Windows 10. Any ideas on how to solve this?

Thank you very very much for any help!

Andres

Andrés Abarca

unread,
Sep 8, 2020, 10:15:34 AM9/8/20
to AequilibraE
By the way, the complete error is:

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

Traceback (most recent call last):
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 334, in _startPlugin
    plugins[packageName] = package.classFactory(iface)
  File "C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\AequilibraE\__init__.py", line 32, in classFactory
    from .AequilibraEMenu import AequilibraEMenu
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\AequilibraE\AequilibraEMenu.py", line 24, in
    from .common_tools import ParameterDialog, GetOutputFileName, LogDialog
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\AequilibraE\common_tools\__init__.py", line 5, in
    from .load_graph_layer_setting_dialog import LoadGraphLayerSettingDialog
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\AequilibraE\common_tools\load_graph_layer_setting_dialog.py", line 33, in
    from aequilibrae.project import Project
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\AequilibraE\aequilibrae\aequilibrae\__init__.py", line 3, in
    from aequilibrae import distribution
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\AequilibraE\aequilibrae\aequilibrae\distribution\__init__.py", line 1, in
    from .ipf import Ipf
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\AequilibraE\aequilibrae\aequilibrae\distribution\ipf.py", line 26, in
    from ..matrix import AequilibraeData
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\AequilibraE\aequilibrae\aequilibrae\matrix\__init__.py", line 1, in
    from .aequilibrae_matrix import AequilibraeMatrix, matrix_export_types
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\AequilibraE\aequilibrae\aequilibrae\matrix\aequilibrae_matrix.py", line 16, in
    import openmatrix as omx
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\Python\Python37\site-packages\openmatrix\__init__.py", line 3, in
    import tables
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
  File "C:\Users\andre\AppData\Roaming\Python\Python37\site-packages\tables\__init__.py", line 99, in
    from .utilsextension import (
  File "C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python\qgis\utils.py", line 737, in _import
    mod = _builtin_import(name, globals, locals, fromlist, level)
ImportError: DLL load failed: The specified module could not be found.


Python version: 3.7.0 (v3.7.0:1bf9cc5093, Jun 27 2018, 04:59:51) [MSC v.1914 64 bit (AMD64)]
QGIS version: 3.8.3-Zanzibar Zanzibar, 685d8b15d2

Python Path:

  • C:\Users\andre\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\AequilibraE\aequilibrae
  • C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python
  • C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python
  • C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins
  • C:/PROGRA~1/QGIS3~1.8/apps/qgis/./python/plugins
  • C:\Program Files\QGIS 3.8\bin\python37.zip
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37\DLLs
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37\lib
  • C:\Program Files\QGIS 3.8\bin
  • C:\Users\andre\AppData\Roaming\Python\Python37\site-packages
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37\lib\site-packages
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37\lib\site-packages\win32
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37\lib\site-packages\win32\lib
  • C:\PROGRA~1\QGIS3~1.8\apps\Python37\lib\site-packages\Pythonwin
  • C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python

Pedro Camargo

unread,
Sep 8, 2020, 9:19:57 PM9/8/20
to "Andrés Abarca", AequilibraE
Andrés,
                     I would try going to C:/Users/andre/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ and deleting the entire AequilibraE folder (with QGIS closed) and then trying again.

Cheers,
Pedro​


---- On Wed, 09 Sep 2020 00:15:34 +1000 Andrés Abarca <andres...@gmail.com> wrote ----

--
You received this message because you are subscribed to the Google Groups "AequilibraE" group.
To unsubscribe from this group and stop receiving emails from it, send an email to aequilibrae...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/aequilibrae/6c19adc7-abd2-447f-b02f-02a6469beac5n%40googlegroups.com.


Andrés Abarca

unread,
Sep 9, 2020, 9:46:13 AM9/9/20
to Pedro Camargo, AequilibraE
Dear Pedro,

I did a hard reinstall or all QGIS packages and now it works, thank you very much for your help!

Best regards,

Andres

Monika Gribl

unread,
Oct 5, 2020, 9:18:34 AM10/5/20
to AequilibraE

Hello Andres,

 

how did you do the reinstall? I currently have the same problem. I reinstalled QGIS already with the Revo Uninstaller and then deleted all the data in the folder C:\Users\Monika-HP-840\AppData\Roaming\QGIS.

But I still get the same Error after installing AequilibraE' again.

 

Thank you in advance for your help.

Best regards,

Monika

Pedro Camargo

unread,
Oct 5, 2020, 7:00:14 PM10/5/20
to Monika Gribl, AequilibraE
Have you tried a newer version of QGIS, Monika?




---- On Mon, 05 Oct 2020 23:18:34 +1000 Monika Gribl <monika...@gmail.com> wrote ----

Andrés Abarca

unread,
Oct 6, 2020, 4:46:22 AM10/6/20
to Pedro Camargo, Monika Gribl, AequilibraE
Hi Monika,

I had that same problem. After the AequilibraE installation my DLLs got messed up and some plugins were not working.

I solved it by installing using the OSGeo4W Network Installer, and choosing QGIS during installation. It is the same software except it installs in a different location in the system root and that made it work.

Just by curiosity, do you remember if the plugin started giving problems after some point? Mine seemed ok until I tried to install the OMX thing.

Hope this helps.

Best regards,

Andres

Monika Gribl

unread,
Oct 7, 2020, 10:03:55 AM10/7/20
to AequilibraE
Hi Andres, Hi Pedro,

I now tried your tipp to install it using OSGeo4W Network Installer but I still have the same result after installing the plugin.
I am always trying to reinstall the newest QGIS Version QGIS 3.14.16 'Pi.

I have the same problem. AequilibraE worked before but after running QGIS as Administrator to install OpenMatrix (with click on install extra packages) it's not working anymore.
Do you have some further tipps to fix the DLLs?

I would really appreciate your help.

Best regards,
Monika

Andrés Abarca

unread,
Oct 7, 2020, 11:28:48 AM10/7/20
to Monika Gribl, AequilibraE
Hi Monika,

Sorry to hear about that. I tried so many things I don't even remember, the new executable worked for me. Though I have not tried to install the OMX parts again, for fear of having to go through the process again. 

It's important that you fix this, not just for AequilibraE but because other plugins might give you problems now.

I think the key is to really make sure you delete all traces of QGIS and reinstall. Try this:

1. Go to QGIS, Plugins, Python Console
2. In the console type: import sys 
3. Then on the next line type: sys.path (this will give you a list of locations in your PC where QGIS stores and checks DLLs for multiple plugins, save this list somewhere)
4. Uninstall QGIS
5. Go back to the list you got on step 4 and make sure those locations do not exist anymore on your computer. Anything that says QGIS needs to go. 
6. Cross your fingers and reinstall QGIS

Then install the plugin again (maybe skip the OMX installation for now while Pedro figures out what is going on).

Good luck! Let me know how it goes.

Best,

Andres

Monika Gribl

unread,
Oct 11, 2020, 3:02:07 PM10/11/20
to AequilibraE
Hi Andre,

thank you for your tips. But I still have the same problem.

I used the command you recommended. I got the following info:
['C:\\Users\\Monika-HP-840\\AppData\\Roaming\\QGIS\\QGIS3\\profiles\\default\\python\\plugins\\AequilibraE\\aequilibrae', 'C:/OSGEO4~1/apps/qgis/./python', 'C:/Users/Monika-HP-840/AppData/Roaming/QGIS/QGIS3\\profiles\\default/python', 'C:/Users/Monika-HP-840/AppData/Roaming/QGIS/QGIS3\\profiles\\default/python/plugins', 'C:/OSGEO4~1/apps/qgis/./python/plugins', 'C:\\OSGEO4~1\\apps\\Python37', 'C:\\OSGEO4~1\\apps\\Python37\\Scripts', 'C:\\OSGeo4W64\\bin\\python37.zip', 'C:\\OSGEO4~1\\apps\\Python37\\DLLs', 'C:\\OSGEO4~1\\apps\\Python37\\lib', 'C:\\OSGeo4W64\\bin', 'C:\\Users\\Monika-HP-840\\AppData\\Roaming\\Python\\Python37\\site-packages', 'C:\\OSGEO4~1\\apps\\Python37\\lib\\site-packages', 'C:\\OSGEO4~1\\apps\\Python37\\lib\\site-packages\\win32', 'C:\\OSGEO4~1\\apps\\Python37\\lib\\site-packages\\win32\\lib', 'C:\\OSGEO4~1\\apps\\Python37\\lib\\site-packages\\Pythonwin', 'C:/Users/Monika-HP-840/AppData/Roaming/QGIS/QGIS3\\profiles\\default/python']

I uninstalled QGIS and the OSGeo4W things with REVO uninstall. I checked for the links above. And used the trace destroyer from REVO uninstall to delete everything.
Then I checked the registry and deleted all the qgis and OSGeo4W data (I seached for it with Ctrl+F
After that I installed QGIS 3.14 again. But I still have the same result after installing AequilibraE.

Could not load extension 'AequilibraE' due to an error when calling the classFactory () method

I don't know what I can do more. I am thinking about resetting windows but that is so much work. I am at the end of my master thesis and I am really desperate. I just want my old QGIS back.

Best regards,
Monika

Andrés Abarca

unread,
Oct 12, 2020, 4:17:10 AM10/12/20
to Monika Gribl, AequilibraE
Dear Monika,

I'm really sorry to hear about that, it must be very frustrating, sadly I'm out of ideas.

If you are in a hurry I would go for installing and running QGIS in a virtual machine (Oracle VirtualBox is free) before resetting Windows.  

Out of curiosity, when you reinstalled QGIS with the OSGeo4W executable, did you reinstall the plugin all the way? With the OMX part and everything, or did it give you problems just after reinstalling QGIS? 

Best wishes,

Andres Abarca

You received this message because you are subscribed to a topic in the Google Groups "AequilibraE" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/aequilibrae/MtY-dmVsqko/unsubscribe.
To unsubscribe from this group and all its topics, send an email to aequilibrae...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/aequilibrae/7521913c-f95a-42d1-b2ae-568e10ce38b5n%40googlegroups.com.

Pedro Camargo

unread,
Oct 12, 2020, 5:37:49 AM10/12/20
to "Andrés Abarca", Monika Gribl, AequilibraE
It is likely that the issue sits in the AppData folder, so I would remove all contents from C:\\Users\\Monika-HP-840\\AppData\\Roaming\\QGIS\\QGIS3\\profiles\\default\\python\\plugins

Cheers,
Pedro

---- On Mon, 12 Oct 2020 18:16:57 +1000 Andrés Abarca <andres...@gmail.com> wrote ----

Monika Gribl

unread,
Oct 12, 2020, 10:41:48 AM10/12/20
to AequilibraE

Hallo Andres! Hallo Pedro!

So I think I fix it! 😊 Thank you for your help.

I searched everything for Qgis and OSGeo4W in regedit and deleted everything in appdata mentioning qgis.

But in the end I think I missed this path:

C:\Users\Monika-HP-840\AppData\Roaming\Python\Python37\site-packages\OpenMatrix-0.3.5.0.dist-info

That path is also in the output of the sys.path command, I don’t know how I missed it, I guess I was to focused on deleting everything with the phrase qgis and forgot about python.

So your way Andres of deleting everything from the output of sys.path and reinstalling QGIS works. I can now use the AequilibraE panel again. 👍

But I also skipped the OMX installation. I don’t want to risk it.

I really appreciate your help. I was good to know I am not alone with my problem.

Best regards

Monika

Pedro Camargo

unread,
Oct 12, 2020, 2:55:12 PM10/12/20
to monika...@gmail.com, aequi...@googlegroups.com
That is great, Monika! 

If you feel like you need OMX, you need to run QGIS as an administrator to proper install it. 

Cheers, 
Pedro 



---- On Tue, 13 Oct 2020 00:41:47 +1000 monika...@gmail.com wrote ----

Andrés Abarca

unread,
Oct 13, 2020, 4:16:13 AM10/13/20
to Monika Gribl, AequilibraE
Awesome! Very happy to hear that! Good luck with the rest of your thesis! 💪

Best regards,

Andres Abarca

Pedro Camargo

unread,
Oct 13, 2020, 4:21:27 AM10/13/20
to "Andrés Abarca", Monika Gribl, AequilibraE
Monika & Others,

Andrés mention to your (Monika) thesis reminded me to ask you all to please share whatever you can from your work here and/or on AequilibraE's group on LinkedIn (https://www.linkedin.com/groups/13910813/).

The types of analysis you made and how you approached it might help tremendously other users and it also helps guide the development of AequilibraE, as we can see what you had to get around of and what tools could be useful for the type of work currently being done.

Cheers,
Pedro


---- On Tue, 13 Oct 2020 18:16:01 +1000 Andrés Abarca <andres...@gmail.com> wrote ----

Sahand Asgarpour

unread,
Nov 5, 2020, 5:21:57 PM11/5/20
to AequilibraE
Hi all,

I am facing the same problem. I went through the steps, reinstalled QGIS and still facing the issue.

I even deleted the folder in C:\Users\Monika-HP-840\AppData\Roaming\Python\Python37\site-packages\OpenMatrix-0.3.5.0.dist-info  

AequilibraE works on another laptop that I have, but not on my main laptop.

this is the sys.path list:

['C:/PROGRA~1/QGIS3~1.10/apps/qgis-ltr/./python', 'C:/Users/AsgarpourS/AppData/Roaming/QGIS/QGIS3\\profiles\\default/python', 'C:/Users/AsgarpourS/AppData/Roaming/QGIS/QGIS3\\profiles\\default/python/plugins', 'C:/PROGRA~1/QGIS3~1.10/apps/qgis-ltr/./python/plugins', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\Scripts', 'C:\\Program Files\\QGIS 3.10\\bin\\python37.zip', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\DLLs', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\lib', 'C:\\Program Files\\QGIS 3.10\\bin', 'C:\\Users\\AsgarpourS\\AppData\\Roaming\\Python\\Python37\\site-packages', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\lib\\site-packages', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\lib\\site-packages\\win32', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\lib\\site-packages\\win32\\lib', 'C:\\PROGRA~1\\QGIS3~1.10\\apps\\Python37\\lib\\site-packages\\Pythonwin', 'C:/Users/AsgarpourS/AppData/Roaming/QGIS/QGIS3\\profiles\\default/python']

 I appreciate it if you could help me further.

Best,
Sahand

VANESSA SANDOVAL

unread,
Jan 12, 2021, 10:06:45 PM1/12/21
to AequilibraE
Hello  Sahand,

I erase the folder  C:\Users\Name\AppData\Roaming\Python\Python37
And all other files of QGIS, and installed the last version, whit that I solved the problem.

Atte,
Vanessa 

Reply all
Reply to author
Forward
0 new messages