Skip to main content

Python LINZ Logger

GitHub Actions Status Kodiak Dependabot Status License Conventional Commits Code Style

Why?

LINZ has a standard logging format based loosely on the pinojs logging format:

{
  "level": 30,
  "time": 1571696532994,
  "pid": 10671,
  "hostname": "Ubuntu1",
  "id": "01DQR6KQG0K60TP4T1C4VC5P74",
  "msg": "SomeMessage",
  "v": 1
}

Usage

pip install --upgrade linz-logger
from os import environ

from linz_logger import get_log, set_level, LogLevel

set_level(LogLevel[environ.get("LOGLEVEL", "WARNING").lower()].value)
set_contextvars({"country": "NZ"}) # remove_contextvars(["country"]) to remove a key
get_log().error('Hello World', key="value")
# {"key": "value", "level": 50, "time": 1601555605017, "v": 1, "pid": 311800, "id": "01G9XAA1MCMX2K9NZN9GJJHN71", "msg": "Hello World", "hostname": "Ubuntu1", "country": "NZ"}

Metadata

Release files for linz_logger 0.13.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for linz_logger 0.13.1
File Size Uploaded Provenance Actions
linz_logger-0.13.1.tar.gz 4.6 kB Without provenance Details for linz_logger-0.13.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for linz_logger 0.13.1
File Interpreter ABI Platform Actions
linz_logger-0.13.1-py3-none-any.whl Python 3 none any Details for linz_logger-0.13.1-py3-none-any.whl

Total release size: 9.9 kB

Release files / linz_logger-0.13.1.tar.gz

Download URL linz_logger-0.13.1.tar.gz
Size 4.6 kB
Tags Source
SHA-256 checksum
How to use checksums
69fbc39d3a4f59c522db9313d1ecd749b9c21921dc7e6ce889b1591216e36bf2
BLAKE2b-256 checksum
How to use checksums
6da66df47b73f3c7f98fbe7575bc9e7e8377cd0a8e47bd7a801335972796bca0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / linz_logger-0.13.1-py3-none-any.whl

Download URL linz_logger-0.13.1-py3-none-any.whl
Size 5.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
8f6f06ebb1c6fa565175894aa0dc7f055a200caa169eeb74bcef8547ee0dbc34
BLAKE2b-256 checksum
How to use checksums
fe9524a3881423077748bc8516572cc870e4dd8eb31bb57a7f419bba16ae214e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.6 {"installer":{"name":"uv","version":"0.13.6","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for linz_logger 0.13.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page