Skip to main content

arcor2_logger

The service provides logging capabilities through the network. Logging-related methods are added to ObjectTypes using a mixin class.

  • Messages are sent using the websockets protocol.
  • Calls to log_ methods are non-blocking.

Example usage

from typing import Optional

from arcor2.object_types.abstract import Generic, Settings

try:
    from .logging_mixin import LoggingMixin  # this is used within an execution package
except ImportError:
    from arcor2_logger.object_types.logging_mixin import LoggingMixin  # this is used during development
    
class MyObject(LoggingMixin, Generic):

    _ABSTRACT = False

    def __init__(self, obj_id: str, name: str, settings: Optional[Settings] = None) -> None:
        super().__init__(obj_id, name, settings)
        self.logger = self.get_logger()
        self.logger.info("Initialized.")

Environment variables

  • ARCOR2_LOGGER_URL=ws://0.0.0.0:8765 - by default, the service listens on port 8765.
  • ARCOR2_LOGGER_LEVEL=info - by default, messages from objects with level info and higher are logged.
    • Other possible values are warning, error and debug.
  • ARCOR2_LOGGER_DEBUG=1 - switches logger to the DEBUG level.
  • ARCOR2_LOGGER_ASYNCIO_DEBUG=1 - turns on asyncio debug output (helpful to debug problems related to concurrency).

Changelog

The format is based on Keep a Changelog,

[0.2.0] - 2024-04-11

Changed

  • Updated dependencies, switched to Python 3.11.

[0.1.0] - 2022-10-28

Changed

  • First version of the package.

Metadata

Release files for arcor2-logger 0.2.0

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

Source distribution (sdist)

Source distribution for arcor2-logger 0.2.0
File Size Uploaded Provenance Actions
arcor2_logger-0.2.0.tar.gz 5.1 kB Without provenance Details for arcor2_logger-0.2.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for arcor2-logger 0.2.0
File Interpreter ABI Platform Actions
arcor2_logger-0.2.0-py311-none-any.whl Python 3.11 none any Details for arcor2_logger-0.2.0-py311-none-any.whl

Total release size: 11.3 kB

Release files / arcor2_logger-0.2.0.tar.gz

Download URL arcor2_logger-0.2.0.tar.gz
Size 5.1 kB
Tags Source
SHA-256 checksum
How to use checksums
0ea3f40d21d84774552da00b265a886ff2175318f28245e9e92c76ac5deb18b9
BLAKE2b-256 checksum
How to use checksums
a8c3f84822237ec908d311c2f6d952c0ac203241dc9b6986f326a06a1de3a204
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Release files / arcor2_logger-0.2.0-py311-none-any.whl

Download URL arcor2_logger-0.2.0-py311-none-any.whl
Size 6.2 kB
Tags Python 3.11
SHA-256 checksum
How to use checksums
c1ddaa6731815d27d8aa6b75419e72be26e0e1a2955926f7597557d1df4e5461
BLAKE2b-256 checksum
How to use checksums
ffe2908ef825ba53590d8a5c39b79a6147d04e5e01ef779c2cce6cdbbc08b5dc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.10.12

Security for arcor2-logger 0.2.0

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.2.0 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