timeitX - Function Execution Time Logger
timeitX is a Python decorator that logs the execution time of functions, both for synchronous and asynchronous functions.
Features
- Log the execution time of functions.
- Supports both synchronous and asynchronous functions.
- Customizable function names for logging.
- Precision down to milliseconds.
- Easy to integrate with your Python projects.
Installation
You can install timeitX via pip:
pip install timeitX
Usage
from timeitX import timeitX
# Define your logger
import logging
logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')
logger = logging.getLogger("timeitX")
@timeitX(name="My Function", logger=logger)
def my_function():
# Your function code here
# For asynchronous functions
@timeitX(name="Async Function", logger=logger)
async def async_function():
# Your async function code here
Release files for timeitX 1.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| timeitx-1.0.2.tar.gz | 6.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| timeitx-1.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 17.3 kB
Release files / timeitx-1.0.2.tar.gz
| Download URL | timeitx-1.0.2.tar.gz |
|---|---|
| Size | 6.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a42d519d38f27b474917c3f104ecdbfe0e07f6dc65cf777bbb2c87d7c7e81b20
|
|
BLAKE2b-256 checksum How to use checksums |
d9867568c76d5ccede491801291dca6efbbd086186f84e8c55413bf6dfcb96c4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.0 CPython/3.9.18 Linux/6.2.0-1015-azure
|
Release files / timeitx-1.0.2-py3-none-any.whl
| Download URL | timeitx-1.0.2-py3-none-any.whl |
|---|---|
| Size | 11.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dc3b34b1505f36d570f8904819f2512b5a6383a1b77b0a4c0f321bdc9c99e479
|
|
BLAKE2b-256 checksum How to use checksums |
f73033ab4fb54a7baf404c9c7a8eb5eb917f148bca32e537c64214c7435b2484
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.7.0 CPython/3.9.18 Linux/6.2.0-1015-azure
|