skillfed

inputimeout

Multi platform standard input with timeout

inputimeout v1.0.4 16.9M downloads/30d#1,135 on PyPI
Permissive license MIT Abandoned released

What it is and what it does

inputimeout wraps standard input to add a timeout mechanism across Windows, macOS, and Linux. When you call inputimeout() with a prompt and timeout duration, it waits for user input up to that many seconds; if no input arrives, it raises TimeoutOccurred, which you catch to provide a fallback value or handle the timeout case. The package has no external runtime dependencies, making it lightweight to add to a project.

The package is in Beta status and has not been updated since 2018-03-02. It requires Python >=3.4. Because it is abandoned and unmaintained, it may not work correctly on newer Python versions or modern terminal environments, and any bugs or compatibility issues will not be fixed.

Use it for:

  • Interactive CLI tools that need to proceed automatically if a user does not respond within a set time window.
  • Automated testing scripts that prompt for optional input but should not hang indefinitely if stdin is not available.
  • Batch processing workflows where a user confirmation prompt should time out and use a sensible default.
  • Terminal applications that require responsive behavior even when input is slow or unavailable.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides cross-platform standard input with a timeout, allowing you to prompt for user input and automatically return a default or exception if no response arrives within a specified number of seconds.

No. The package is abandoned (last release 2018-03-02) with no maintenance signal, and while it has no known vulnerabilities and low install friction, its age and lack of updates create significant risk for modern Python environments. For new projects, consider a maintained alternative or implement timeout logic using threading or asyncio instead.

Install

inputimeout on PyPI

pip

pip install inputimeout

uv

uv add inputimeout

poetry

poetry add inputimeout

Installing inputimeout

Before you install

Installation is straightforward with no runtime dependencies, but the package has been abandoned since March 2018 with no active maintenance or updates.

License in practice

MIT license is permissive and places no restrictions on use, modification, or distribution in proprietary or open-source projects.

Quickstart

pip install inputimeout

from inputimeout import inputimeout, TimeoutOccurred
try:
    something = inputimeout(prompt='>>', timeout=5)
except TimeoutOccurred:
    something = 'default_value'
print(something)

Verify before relying

  • Whether the package works reliably on Python versions beyond 3.6, given its age and lack of maintenance.
  • Whether there are known issues with specific terminal emulators or operating systems not covered by original testing.
  • Whether the timeout mechanism remains accurate on modern systems with different process scheduling.

Package facts

License MIT (permissive)
Python support supports the current Python release (>=3.4)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance abandoned — 3,087 days since the last release
First released
Downloads 16,909,239/month — #1,135 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: inputimeout-1.0.4-py3-none-any.whl

Development Status :: 4 - BetaEnvironment :: ConsoleIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: MacOS :: MacOS XOperating System :: Microsoft :: WindowsOperating System :: POSIX :: LinuxProgramming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.6

Tags

input with timeoutstdin timeoutuser input timeouttimed input promptcross-platform input timeoutconsole input timeoutblocking input with timeout
cli-inputtimeout-handling

More Utilities packages