Skip to content

Error Message After Installing Package on Python 3.7.5 and Having MinGW on Path (OSError: [WinError 193] %1 is not a valid Win32 application and 'XRotor' object has no attribute '_lib') #2

@marcosaantos

Description

@marcosaantos

I ran this line after successfully downloading the XRotor package.

from xrotor import XRotor
xr=XRotor()

I have downloaded all the pre-requisites (Python and MinGW as gcc and fortran compiler), but still get problems in running the code above, as is shown in the message below. Do you know what could be causing the error? I have Python 3.7.5 64-bit installed (I tried having its 32-bit version, but the XRotor package could not be downloaded with it).

C:\Users\msantos43\PycharmProjects\Test03\venv\Scripts\python.exe C:/Users/msantos43/PycharmProjects/Test03/Test03.py
Traceback (most recent call last):
File "C:/Users/msantos43/PycharmProjects/Test03/Test03.py", line 2, in
xr=XRotor()
File "C:\Users\msantos43\PycharmProjects\Test03\venv\lib\site-packages\xrotor\xrotor.py", line 55, in init
self._lib = cdll.LoadLibrary(self.lib_path)
File "C:\Users\msantos43\AppData\Local\Programs\Python\Python37\lib\ctypes_init
.py", line 442, in LoadLibrary
return self.dlltype(name)
File "C:\Users\msantos43\AppData\Local\Programs\Python\Python37\lib\ctypes_init
.py", line 364, in init
self._handle = _dlopen(self._name, mode)
OSError: [WinError 193] %1 is not a valid Win32 application
Exception ignored in: <function XRotor.del at 0x000001C6E2CC0A68>
Traceback (most recent call last):
File "C:\Users\msantos43\PycharmProjects\Test03\venv\lib\site-packages\xrotor\xrotor.py", line 69, in del
handle = self._lib._handle
AttributeError: 'XRotor' object has no attribute '_lib'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions