Reusable Python Utilities by McCool
Project description
Installation
pip install pymccool
Usage
-
For basic, no-nonsense console and file logging:
from pymccool.logging import Logger logger = Logger(app_name="<your app name>")
-
For more options, use LoggerKwargs
from pymccool.logging import Logger, LoggerKwargs logger = Logger( LoggerKwargs( app_name="test_logger_loki", default_level=Logger.VERBOSE, stream_level=Logger.VERBOSE, grafana_loki_endpoint="https://loki.end.point.com/loki/api/v1/push") )
-
To use the Tracer:
from uuid import uuid1 from pymccool.tracing import get_tracer, get_decorator from pymccool.logging import Logger, LoggerKwargs logger = Logger( LoggerKwargs( app_name="test_logger_loki", default_level=Logger.VERBOSE, stream_level=Logger.VERBOSE, grafana_loki_endpoint="https://loki.end.point.com/loki/api/v1/push") ) tracer = get_tracer(service_name="test_tracer", endpoint="https://otel-rec.end.point.com/v1/traces", uuid=UUID) instrument_decorator = get_decorator(e2e_tracer)
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
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 pymccool-0.5.6.tar.gz.
File metadata
- Download URL: pymccool-0.5.6.tar.gz
- Upload date:
- Size: 55.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d8baeb39e7fd7d75b5597951f7501b1765a4f6f9d66f22ee9042a7165c21cc84
|
|
| MD5 |
200a701f7a47f71000e56933b4eed00f
|
|
| BLAKE2b-256 |
146527f75f407e5540cae0132ecf87c19e87c4aa8c2ce0f095c8a1a88ce0c011
|
Provenance
The following attestation bundles were made for pymccool-0.5.6.tar.gz:
Publisher:
ci.yaml on bmccool/pyMcCool
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pymccool-0.5.6.tar.gz -
Subject digest:
d8baeb39e7fd7d75b5597951f7501b1765a4f6f9d66f22ee9042a7165c21cc84 - Sigstore transparency entry: 171938203
- Sigstore integration time:
-
Permalink:
bmccool/pyMcCool@e99811e7a1cda0049a025a1fd037ad20541f7bc8 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/bmccool
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
ci.yaml@e99811e7a1cda0049a025a1fd037ad20541f7bc8 -
Trigger Event:
push
-
Statement type:
File details
Details for the file pymccool-0.5.6-py3-none-any.whl.
File metadata
- Download URL: pymccool-0.5.6-py3-none-any.whl
- Upload date:
- Size: 7.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c4f27b639d32bd104a5e14e65a20b809e34051b5663908ce8e1eaba2adb930e4
|
|
| MD5 |
e48424ae02bd2c8b641b1850e64198a6
|
|
| BLAKE2b-256 |
bac00e3743a0358fea3e3b64e37e22af437caad7efd83aba41b1a0c13d2bcb59
|
Provenance
The following attestation bundles were made for pymccool-0.5.6-py3-none-any.whl:
Publisher:
ci.yaml on bmccool/pyMcCool
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pymccool-0.5.6-py3-none-any.whl -
Subject digest:
c4f27b639d32bd104a5e14e65a20b809e34051b5663908ce8e1eaba2adb930e4 - Sigstore transparency entry: 171938205
- Sigstore integration time:
-
Permalink:
bmccool/pyMcCool@e99811e7a1cda0049a025a1fd037ad20541f7bc8 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/bmccool
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
ci.yaml@e99811e7a1cda0049a025a1fd037ad20541f7bc8 -
Trigger Event:
push
-
Statement type: