Registry / devops / pynput-robocorp-fork

pynput-robocorp-fork

JSON →
library5.0.0pypypi✓ verified 85d ago

This is a maintained fork of the original `pynput` library (by TheMouseOrTheKeyboard), designed specifically for Robocorp's automation needs. It provides cross-platform control and monitoring of user input devices like keyboards and mice, essential for Robotic Process Automation (RPA). Version 5.0.0, released recently, focuses on Python 3.10+ compatibility and Linux environment improvements. Releases align with Robocorp's product development, typically with minor versions for bug fixes and improvements.

pip install pynput-robocorp-fork
INSTALL
IMPORT
SIG · PYNPUT-ROBOCORP-FO
P
pynput-robocorp-fork
devopspythonv5.0.0
Install
1.7s avg
Import
Disk
18MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v5.0.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.920 runs
installs and imports cleanly · install 0.0s · import 0.000s · 20MB
glibc
py 3.103.920 runs
installs and imports cleanly · install 1.7s · import 0.000s · 20MB
18MB installed
● package 18MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Controller
from pynput_robocorp.keyboard import Controller
from pynput.keyboard import Controller
keyboard
from pynput_robocorp import keyboard
from pynput import keyboard
mouse
from pynput_robocorp import mouse
from pynput import mouse

This example demonstrates how to use the keyboard controller to type a string, press and release a special key (Enter), and perform a key combination (Ctrl+C).

from pynput.keyboard import Controller, Key import time keyboard = Controller() print("Typing 'Hello World'...") keyboard.type('Hello World') time.sleep(1) print("Pressing Enter...") keyboard.press(Key.enter) keyboard.release(Key.enter) time.sleep(1) print("Pressing Ctrl+C...") with keyboard.pressed(Key.ctrl): keyboard.press('c') keyboard.release('c') print("Keyboard actions completed.")
Debug
Known issues
gotchaPermissions are required for controlling input devices. On macOS, grant 'Accessibility' permissions to your terminal or IDE. On Linux (X11), ensure your user has appropriate X server access.
fix
Consult your operating system's documentation for granting accessibility/input control permissions to applications or users.
affects: All versions
gotchaWhen using `Listener` objects, `listener.join()` will block the current thread. For non-blocking behavior in GUI applications or concurrent tasks, run listeners in separate threads or manage them asynchronously.
fix
Use `threading.Thread` to run the listener in the background, or ensure `join()` is called only when the main thread can afford to block.
affects: All versions
breakingOlder versions of the `pynput-robocorp-fork` (prior to 5.0.0) may have had compatibility issues with Python 3.10 and newer versions.
fix
Upgrade to `pynput-robocorp-fork` version 5.0.0 or newer to ensure full compatibility with Python 3.10+.
affects: <5.0.0
gotchaThis is a fork of the original `pynput` library. While it maintains a high degree of API compatibility, it may have subtle differences, specific fixes, or updated dependencies not present in the original `pynput`. Avoid mixing `pynput` and `pynput-robocorp-fork` in the same environment or project.
fix
Always use `pynput-robocorp-fork` for projects intended for Robocorp environments. Refer to the Robocorp fork's GitHub repository for any specific divergences or feature sets.
affects: All versions
Upgrade
Version history
5.0.0latest on PyPI · released Dec 29, 2022
Audit
Dependencies
python-xliboptionalRequired for some advanced features on Linux.
Agent activity
11 hits · last 30 days
node
10
Resources
pynput-robocorp-fork — pip install pynput-robocorp-fork · libregistry