[GH-ISSUE #37] Error when using keyboard.py in the file to convert #36

Closed
opened 2026-02-26 12:20:15 +03:00 by kerem · 3 comments
Owner

Originally created by @EMJzero on GitHub (Dec 11, 2018).
Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/37

"ctypes.ArgumentError: argument 3: <class 'OverflowError'>: int too long to convert" this is the error i get from site-packages\keyboard_winkeyboard.py in line 553, prepare_intercept. After this obviusly the .exe doesn't complete its run.

The file i'm tring to make in a .exe is pretty simple, nothing more than a script which records a sequence of keypresses and repeats them, i can post it if needed, but the thing which cause the bug is the only use of keyboard.py, cause the bug comes out also in different script which use it!
In this particular case the .exe run is interrupted after the first command which involve keyboard.py, cause every other python command before runs ok. (note: i'm on pyhon 3.6.7)

This is in case a link to the keyboard.py page: https://pypi.org/project/keyboard/

Originally created by @EMJzero on GitHub (Dec 11, 2018). Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/37 "ctypes.ArgumentError: argument 3: <class 'OverflowError'>: int too long to convert" this is the error i get from site-packages\keyboard\_winkeyboard.py in line 553, prepare_intercept. After this obviusly the .exe doesn't complete its run. The file i'm tring to make in a .exe is pretty simple, nothing more than a script which records a sequence of keypresses and repeats them, i can post it if needed, but the thing which cause the bug is the only use of keyboard.py, cause the bug comes out also in different script which use it! In this particular case the .exe run is interrupted after the first command which involve keyboard.py, cause every other python command before runs ok. (note: i'm on pyhon 3.6.7) This is in case a link to the keyboard.py page: https://pypi.org/project/keyboard/
kerem closed this issue 2026-02-26 12:20:15 +03:00
Author
Owner

@brentvollebregt commented on GitHub (Dec 11, 2018):

I created a template for bug reports, please use this next time.

Could you provide a small example or steps to reproduce? Also say what you expect to occur and what did actually occur when performing these steps / running the example.

If you go to keyboard's GitHub page and search in issues for OverflowError, you would notice that this issue has already been raised in boppreh/keyboard#186. This is not a bug with auto-py-to-exe and I don't feel like this is an issue with PyInstaller either. Please take the issue up with keyboard as this project is not the root cause, it is the third party library you are trying to use.

Also as a side note, have you tried the master branch of keyboard? Possibly older versions of PyInstaller may work.

<!-- gh-comment-id:446313988 --> @brentvollebregt commented on GitHub (Dec 11, 2018): I created a template for bug reports, please use this next time. Could you provide a small example or steps to reproduce? Also say what you expect to occur and what did actually occur when performing these steps / running the example. If you go to [keyboard's GitHub page](https://github.com/boppreh/keyboard) and [search in issues for `OverflowError`](https://github.com/boppreh/keyboard/issues?utf8=%E2%9C%93&q=OverflowError), you would notice that this issue has already been raised in boppreh/keyboard#186. This is not a bug with auto-py-to-exe and I don't feel like this is an issue with PyInstaller either. Please take the issue up with keyboard as this project is not the root cause, it is the third party library you are trying to use. Also as a side note, have you tried the master branch of keyboard? Possibly older versions of PyInstaller may work.
Author
Owner

@brentvollebregt commented on GitHub (Dec 11, 2018):

If you feel I have missed something or am wrong in general, feel free to say and I will look further into this with your help. I will close the issue now but if something happens we can open it back up.

<!-- gh-comment-id:446319064 --> @brentvollebregt commented on GitHub (Dec 11, 2018): If you feel I have missed something or am wrong in general, feel free to say and I will look further into this with your help. I will close the issue now but if something happens we can open it back up.
Author
Owner

@EMJzero commented on GitHub (Dec 16, 2018):

Thank you for the tip, I'll ask for help in the keyboard.py's github page. I have to apologise for not using the template, I forgot it, sorry, however don't worry, your choise to close the issue is fine!

<!-- gh-comment-id:447644679 --> @EMJzero commented on GitHub (Dec 16, 2018): Thank you for the tip, I'll ask for help in the keyboard.py's github page. I have to apologise for not using the template, I forgot it, sorry, however don't worry, your choise to close the issue is fine!
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/auto-py-to-exe#36
No description provided.