Skip to main content

provides a standardised, easy to import and use logging method with mcap

Project description

MCAP Logger 🧢

Project description

This python package to provide a standardised, easy to import and use logging method.

The package is...

  • a logger module that leverages the existing MCAP and Foxglove packages
  • provides a plugin replacement for standard Python login
  • provides console logging with configurable log level and handled separately from the file's

Links:

Example usage

Installing the library

pip install mcap-logger

Creating a simple log

# Import the library
from mcap_logger.mcap_logger import get_logger

# Get MCAP logger instance
logger = get_logger(__name__)

logger.info("Hello, World!")

Log Protobuf data

ℹ️ Protocol buffers are Google's language-neutral mechanism for serializing structured data. More info about it and its syntax: Protocol Buffers

# Import the library
from mcap_logger.mcap_logger import get_logger

# Import Protobuf class
from mcap_logger.demo.sensor_data_pb2 import SensorData

# Get MCAP logger instance
logger = get_logger(__name__)

# Log Protobuf data
sensor_message = SensorData(temperature=25, humidity=65)
logger.topic("/sensor_data").write(sensor_message)

Call for Contributions

The MCAP-Logger project welcomes your expertise and enthusiasm!

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mcap_logger-0.1.18.tar.gz (6.4 kB view details)

Uploaded Source

Built Distribution

mcap_logger-0.1.18-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file mcap_logger-0.1.18.tar.gz.

File metadata

  • Download URL: mcap_logger-0.1.18.tar.gz
  • Upload date:
  • Size: 6.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for mcap_logger-0.1.18.tar.gz
Algorithm Hash digest
SHA256 a979f269784aa343b858af9a625cf27cc3a08d0a225e5fc7f03c8cd13af272a2
MD5 c9901db250a9b7db855859817c7611e5
BLAKE2b-256 bba3ea4de4e76b1e296cd01bcd63d424ca708d414609bfc1344f8a9a92c86161

See more details on using hashes here.

Provenance

The following attestation bundles were made for mcap_logger-0.1.18.tar.gz:

Publisher: publishing.yml on 8-bit-hunters/mcap_logger

Attestations:

File details

Details for the file mcap_logger-0.1.18-py3-none-any.whl.

File metadata

File hashes

Hashes for mcap_logger-0.1.18-py3-none-any.whl
Algorithm Hash digest
SHA256 f92edd9acc9827fc44c5406af213a9560f66d34443f70d3492995ca95b00e89b
MD5 75ea450321eca606fc1e2c890e033b93
BLAKE2b-256 bd2e9afef0182bef1721cc1ff78aedad38117ae25db8218096bfe2aff4a4be02

See more details on using hashes here.

Provenance

The following attestation bundles were made for mcap_logger-0.1.18-py3-none-any.whl:

Publisher: publishing.yml on 8-bit-hunters/mcap_logger

Attestations:

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page