Skip to main content

Library for retrieving configurations for DKIST services

Project description

codecov

A configuration for the loguru logger and base configuration object using pydantic base settings.

It is important that it be the first import to run so the standard logging basicConfig method has an effect.

Features

  • Stderr output

  • Intercepted logging from client libraries

  • Disabled better exceptions for log levels above debug to mitigate secret leaking

  • Configuration logging with secrets redacted

  • DKIST Mesh Service configuration parsing

Installation

pip install dkist-service-configuration

Examples

config.py

from dkist_service_configuration.logging import logger
from dkist_service_configuration import MeshServiceConfigurationBase
logger.debug('hello world)
class NewConfiguration(MeshServiceConfigurationBase):
    username: str = "me"
    password: str = "pass"
new_configuration = NewConfiguration()
new_configuration.log_configurations()

The code above will register the existing loggers, retrieve mesh configuration and custom configuration from the environment and log it while redacting the password.

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

dkist_service_configuration-4.3.0.tar.gz (18.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dkist_service_configuration-4.3.0-py3-none-any.whl (18.7 kB view details)

Uploaded Python 3

File details

Details for the file dkist_service_configuration-4.3.0.tar.gz.

File metadata

File hashes

Hashes for dkist_service_configuration-4.3.0.tar.gz
Algorithm Hash digest
SHA256 e5aa558e91740d9ec2530e859762b6abe1bfcf9850a21575f53fae4661ff7086
MD5 b2113ccfb964688626e7ff59d6df8340
BLAKE2b-256 099d8e13837c04b887626f10ba6160f9b572c09e47cd6cb8dc588fa00b33e929

See more details on using hashes here.

File details

Details for the file dkist_service_configuration-4.3.0-py3-none-any.whl.

File metadata

File hashes

Hashes for dkist_service_configuration-4.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 e4fe07355030b2ddb9ac2fef253f1138dd54a94694a3c3fe79bd22d2e309ce7b
MD5 e71a7ce67e1913bcbf09221c043dc21e
BLAKE2b-256 afba7abe3a8120d5c3776f9f13c68f2dd6adc1d4916b9258bc07805ea5bcf0b9

See more details on using hashes here.

Supported by

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