OSError: Unsupported platform 'CYGWIN_NT-10.0-19044'
Brian Inglis
Brian.Inglis@Shaw.ca
Wed Feb 22 16:54:44 GMT 2023
On 2023-02-20 11:04, Jose Isaias Cabrera via Cygwin wrote:
> Python 3 apparently does not support the python keyboard library in Cygwin:
> $ python3
> Python 3.9.10 (main, Jan 20 2022, 21:37:52)
> [GCC 11.2.0] on cygwin
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import keyboard
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File "/usr/local/lib/python3.9/site-packages/keyboard/__init__.py", line 128, in <module>
> raise OSError("Unsupported platform '{}'".format(_platform.system()))
> OSError: Unsupported platform 'CYGWIN_NT-10.0-19044'
>>>>
> Any ideas on how I can make this work?
Post a bug that given the script runs in python, it works and is supported!
You may want to mention that uname -m (ARCH) and -o (Cygwin) are the safe
options, -p and -i are optional, and uname -s may contain unexpected qualifiers
(like Windows version and patch).
Perhaps on Cygwin platform.system() should return uname -o instead of -s?
If you want to try and fix it you could have it use a regex or a different
method and make it work like some generic POSIX API platform:
https://docs.python.org/3/library/platform.html
--
Take care. Thanks, Brian Inglis Calgary, Alberta, Canada
La perfection est atteinte Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut
-- Antoine de Saint-Exupéry
More information about the Cygwin
mailing list