dc740 / AutoHotPy

AutoHotKey replacement using Incerception driver
GNU Lesser General Public License v3.0
59 stars 23 forks source link

access violation writing 0x000000007 #11

Open GiannisKyr opened 4 years ago

GiannisKyr commented 4 years ago

hello Anyway to bypass the above problem just trying to run your examples?

http://prntscr.com/pdc5g6

dc740 commented 4 years ago

Is the dll properly installed? Can you check that it's the right architecture? The error is caused by calling the dll functions with the wrong amount of parameters. Maybe the author changed the signature?

I think someone else had a similar issue in the past and submitted a PR to fix it

El mar., 1 oct. 2019 08:37, GIANNIS KYRITSIS notifications@github.com escribió:

hello Anyway to bypass the above problem just trying to run your examples?

http://prntscr.com/pdc5g6

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/dc740/AutoHotPy/issues/11?email_source=notifications&email_token=AAEFM2HQLXD2IRQXPH63TELQMMZARA5CNFSM4I4IJACKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HO2F6EA, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEFM2FVPKQPYNZRLLWVVOLQMMZARANCNFSM4I4IJACA .

byquip commented 4 years ago

Usually my code working well as python script, but when I decide to pack it to *.exe file by pyinstaller i got problems.

When i try launch *.exe i got error here in File "AutoHotPy.py" :

# Setup filters.
        self.interception.interception_set_filter(self.context, self.interception.interception_is_keyboard, InterceptionFilterKeyState.INTERCEPTION_FILTER_KEY_ALL)

I got this error:

File "InterceptionWrapper.py", line 210, in interception_set_filter
    InterceptionFilter ITERCEPTION_API interception_get_filter(InterceptionContext context, InterceptionDevice device);
ArgumentError: argument 1: <type 'exceptions.OverflowError'>: long int too long to convert

And if I change type of self.context to ctypes.c_int(self.context) or just int(self.context) I got the same error as GiannisKyr

File "main.py", line 317, in start_auto
  File "AutoHotPy.py", line 555, in start
    self.interception.interception_set_filter(self.context, self.interception.interception_is_mouse, InterceptionFilterMouseState.INTERCEPTION_FILTER_MOUSE_ALL);
  File "lib\InterceptionWrapper.py", line 210, in interception_set_filter
    InterceptionFilter ITERCEPTION_API interception_get_filter(InterceptionContext context, InterceptionDevice device);
WindowsError: exception: access violation reading 0x00000000A8088680

And as I said before, I does not have any errors if use just script. Any ideas?

byquip commented 4 years ago

Resolve last errors by using from FedyuninV/AutoHotPy in file InterceptionWrapper.py lines And of course new problem: My mouse does not move after program launch by my *exe file.

byquip commented 4 years ago

Resolve last errors by using from FedyuninV/AutoHotPy in file InterceptionWrapper.py lines And of course new problem: My mouse does not move after program launch by my *exe file.

Resolved. I used wrond dll.

Apemsking commented 3 years ago

hello Anyway to bypass the above problem just trying to run your examples?

http://prntscr.com/pdc5g6

Try changing line 188 in your InterceptionWrapper.py file: funct_type = ctypes.WINFUNCTYPE(ctypes.c_int,InterceptionDevice) -> funct_type = ctypes.CFUNCTYPE(ctypes.c_int,InterceptionDevice)