A simple library for easily working with time
Project description
chronolight
A simple library for working with timelines and delayed calls.
Installation
pip install chronolight
Quick Start
import chronolight
# Timeline
tl = chronolight.Timeline()
tl.wait(1)
tl.call(lambda: print("1 second passed"))
tl.wait(0.5)
tl.call(lambda: print("Another 0.5 seconds passed"))
tl.run()
# Delayed call
chronolight.delay(2, lambda: print("After 2 seconds"))
Methods
Timeline
| Method | Description |
|---|---|
.wait(seconds) |
Adds a delay |
.call(func) |
Adds a function call |
.run(threaded=False) |
Runs the timeline |
delay(seconds, function)
Executes a function after N seconds (in a separate thread).
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
chronolight-1.4.6.tar.gz
(3.8 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file chronolight-1.4.6.tar.gz.
File metadata
- Download URL: chronolight-1.4.6.tar.gz
- Upload date:
- Size: 3.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e7136c3968e9ecc22478d72c25ee583eafc579e9b9e39a659121d48a4b447e92
|
|
| MD5 |
c4f172cc8041aa2645d6f243ffdd969a
|
|
| BLAKE2b-256 |
9a4f1319425796a39380d076ecee00de9fe6c4ddccfe76e265fc13d265d38170
|
File details
Details for the file chronolight-1.4.6-py3-none-any.whl.
File metadata
- Download URL: chronolight-1.4.6-py3-none-any.whl
- Upload date:
- Size: 4.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b424d75066cd01d0fda5ce72d56c3fc65bbcf07b88d25b48ef15025a0dfde64
|
|
| MD5 |
67906e2831797ef331ef22be13186dec
|
|
| BLAKE2b-256 |
24a5390b78d260bcd37397ca341f90b966f333b08fe11ff87c925166cda8b125
|