An open API service indexing awesome lists of open source software.

https://github.com/pykit3/k3thread

utility to create thread.
https://github.com/pykit3/k3thread

thread

Last synced: 5 months ago
JSON representation

utility to create thread.

Awesome Lists containing this project

README

          

# k3thread

[![Build Status](https://travis-ci.com/pykit3/k3thread.svg?branch=master)](https://travis-ci.com/pykit3/k3thread)
![Python package](https://github.com/pykit3/k3thread/workflows/Python%20package/badge.svg)
[![Documentation Status](https://readthedocs.org/projects/k3thread/badge/?version=stable)](https://k3thread.readthedocs.io/en/stable/?badge=stable)
[![Package](https://img.shields.io/pypi/pyversions/k3thread)](https://pypi.org/project/k3thread)

utility to create thread.

k3thread is a component of [pykit3] project: a python3 toolkit set.

k3thread is utility to create and operate thread.

Start a daemon thread after 0.2 seconds::

>>> th = daemon(lambda :1, after=0.2)

Stop a thread by sending a exception::

import time

def busy():
while True:
time.sleep(0.1)

t = daemon(busy)
send_exception(t, SystemExit)

# Install

```
pip install k3thread
```

# Synopsis

```python
>>> th = daemon(lambda :1, after=0.2)

```

# Author

Zhang Yanpo (张炎泼)

# Copyright and License

The MIT License (MIT)

Copyright (c) 2015 Zhang Yanpo (张炎泼)

[pykit3]: https://github.com/pykit3