A package designed to kill a function after a specified amount of time.
Project description
timeoutcall
A package designed to kill a function after a specified amount of time.
Usage
Killing a function after a specified amount of time:
from timeoutcall import timeout
from time import sleep
@timeout(2, "error: took too long")
def foo():
sleep(3) # will raise TimeoutError
foo()
Running a test/preview:
$ python3 -m timeoutcall.test
Developers
Build and Source Distributions
To build the wheel and source distributions, cd into the repositories root directory and run the following command:
python3 -m build
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
timeoutcall-1.0rc2.tar.gz
(2.2 kB
view hashes)
Built Distribution
Close
Hashes for timeoutcall-1.0rc2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | eb11127e4b5a4d45d2ce16c68e54e243a0f4646f96bc95d0a2f2d64d5a107106 |
|
MD5 | b7cbe2e0b852b2784c8428d2f1b701b6 |
|
BLAKE2b-256 | 4d28206b61966cbb589e870b3e155fdf33cfd4b3d720279a6b6a09a916d93952 |