Skip to main content

Thread utilities for daemon threads and exception sending

Project description

k3thread

Build Status Python package Documentation Status Package

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

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

Author

Zhang Yanpo (张炎泼) drdr.xp@gmail.com

Copyright and License

The MIT License (MIT)

Copyright (c) 2015 Zhang Yanpo (张炎泼) drdr.xp@gmail.com

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

k3thread-0.1.4.tar.gz (5.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

k3thread-0.1.4-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file k3thread-0.1.4.tar.gz.

File metadata

  • Download URL: k3thread-0.1.4.tar.gz
  • Upload date:
  • Size: 5.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for k3thread-0.1.4.tar.gz
Algorithm Hash digest
SHA256 5c78b79a6dd2c8feb79a58e8e72a3f85904f19a3a799510172163f4af554cd8b
MD5 a5a5765ce0b901a6d546ee689abe863f
BLAKE2b-256 63dd56126aa35b65ceab9e5db36ce2caea634dd3dbe098edd9013049e375c51d

See more details on using hashes here.

File details

Details for the file k3thread-0.1.4-py3-none-any.whl.

File metadata

  • Download URL: k3thread-0.1.4-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for k3thread-0.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 6d0f8e207c708ac12729c5b7abec4f52be08361a236dfe0b209bf16376990cd3
MD5 4794ec6be9cfc38a9ebbc5bb162330d5
BLAKE2b-256 35faf5dd991f77c0b6ac3f5cbcec23c0491d180a56d162dab75ae4461e22fc7c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page