Metadata-Version: 2.4
Name: input-with-timeout
Version: 2.3.1
Summary: Cross-platform user input with timeout support.
Project-URL: Homepage, https://github.com/mamahoos/input-with-timeout
Project-URL: Repository, https://github.com/mamahoos/input-with-timeout
Project-URL: Issues, https://github.com/mamahoos/input-with-timeout/issues
Author-email: mamahoos <m4m4hoos@gmail.com>
License-Expression: MIT
License-File: LICENSE
Keywords: console,cross-platform,input,timeout,user input
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Typing :: Typed
Requires-Python: >=3.8
Description-Content-Type: text/markdown

# Input with Timeout

`input_with_timeout` captures user input with a timeout. If the user does not
respond in time, it raises `TimeoutError`.

## Installation

```bash
pip install input-with-timeout
```

or with uv:

```bash
uv add input-with-timeout
```

## Features

- Customizable timeout for user input
- Cross-platform support (Windows and Unix)
- Typed public API (`py.typed`)
- Compatible with Python 3.8+

## Usage

```python
from input_with_timeout import input_with_timeout

try:
    user_input = input_with_timeout("Enter your input: ", timeout=10)
    print(f"Input received: '{user_input}'.")
except TimeoutError:
    print("No input received within the timeout period.")
```

Use `timeout=None` for normal blocking `input()` behavior.

## Contact

https://t.me/mamahoos
