Skip to main content
https://secure.travis-ci.org/jkakar/logfmt-python.png?branch=master

Logfmt

Python package for parsing log lines in the logfmt style. See the original project by Blake Mizerany and Keith Rarick for information about logfmt conventions and use: https://github.com/kr/logfmt

Using logfmt

Easily process lines from logfmt formatted input:

from logfmt import parse

input = StringIO('\n'.join(['key1=value1', 'key2=value2']))
for values in parse(input):
    print values

This program produces this output:

{'key1': 'value1'}
{'key2': 'value2'}

Easily generate lines in logfmt formatted output

from logfmt import format

for line in format({'key1': 'value1'}, {'key2': 'value2'}):
    print line

This program produces this output:

key1="value1"
key2="value2"

Installation

To install it, simply:

pip install logfmt

Metadata

Release files for logfmt 0.4

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

Source distribution (sdist)

Source distribution for logfmt 0.4
File Size Uploaded Provenance Actions
logfmt-0.4.tar.gz 3.4 kB Without provenance Details for logfmt-0.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for logfmt 0.4
File Interpreter ABI Platform Actions
logfmt-0.4-py2.py3-none-any.whl Python 2, Python 3 none any Details for logfmt-0.4-py2.py3-none-any.whl

Total release size: 6.5 kB

Release files / logfmt-0.4.tar.gz

Download URL logfmt-0.4.tar.gz
Size 3.4 kB
Tags Source
SHA-256 checksum
How to use checksums
9db2ba67519a968c5c3d2230e79ab68e6cfac791daa516bbca9e2606eb02a4c6
BLAKE2b-256 checksum
How to use checksums
4640a3b1d774c8b919d9bcfbfe211c20f1b8f4d7478457c0cd831e8f4f17774c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.4.1 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6

Release files / logfmt-0.4-py2.py3-none-any.whl

Download URL logfmt-0.4-py2.py3-none-any.whl
Size 3.1 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
0914b7ca93e75d841e6eb8a680fef4475a322f91be2c1883c0e9582e6620dc41
BLAKE2b-256 checksum
How to use checksums
f5fc143f15b9347c2e42a5c726a04defed086c543ddd541419c31baef01c6a17
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.4.1 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.6

Security for logfmt 0.4

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.

Release history Release notifications | RSS feed

This release

0.4 This release

2 release files No provenance

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