Skip to main content

File logs for Sloth CI apps

Project description

Add file logging to Sloth CI apps.

You can customize your logging in a number of ways: set the output dir and filename, set log level and format, toggle and configure log rotation.


Installation
------------

.. code-block:: bash

$ pip install sloth-ci.ext.file_logs


Usage
-----

.. code-block:: yaml
:caption: file_logs.yml

extensions:
logs:
# Use the module sloth_ci.ext.file_logs.
module: file_logs

# Set the log path. Default is the current dir.
path: debug_logs

# Log filename. If not given, the app's listen point is used.
filename: test_debug.log

# Log level (number or valid Python logging level name).
level: DEBUG

# Log format (refer to the https://docs.python.org/3/library/logging.html#logrecord-attributes).
# By default, this format is used:
# format: '%(asctime)s | %(name)30s | %(levelname)10s | %(message)s'

# Make logs rotating. Default is false.
# rotating: true

# If rotating, maximum size of a log file in bytes.
# max_bytes: 500

# If rotating, maximum number or log files to keep.
# backup_count: 10

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

sloth-ci.ext.file_logs-1.1.3.zip (5.2 kB view details)

Uploaded Source

Built Distributions

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

sloth_ci.ext.file_logs-1.1.3-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

sloth-ci.ext.file_logs-1.1.3.win-amd64.exe (141.4 kB view details)

Uploaded Source

File details

Details for the file sloth-ci.ext.file_logs-1.1.3.zip.

File metadata

File hashes

Hashes for sloth-ci.ext.file_logs-1.1.3.zip
Algorithm Hash digest
SHA256 b186a4a0b129623b55a95161cf4ef5eff3c55a1631c351c26600dcaf9189c791
MD5 1ea3da2f471f327961226184a419eb20
BLAKE2b-256 b78ceb6084dc8507cbbc5ba22fe9c506b734cbcd1009586e8244b3235b6ed796

See more details on using hashes here.

File details

Details for the file sloth_ci.ext.file_logs-1.1.3-py3-none-any.whl.

File metadata

File hashes

Hashes for sloth_ci.ext.file_logs-1.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 e6c55c7301c95db8fced956ecfaa7df1851da4fda40599a0c7c9acfadcfe99c9
MD5 fd665fceee396357205136b08f1a950a
BLAKE2b-256 2c69fef0bfdc576c329f80c2dedc261699ebf0153716777d2e0919525dc24dd8

See more details on using hashes here.

File details

Details for the file sloth-ci.ext.file_logs-1.1.3.win-amd64.exe.

File metadata

File hashes

Hashes for sloth-ci.ext.file_logs-1.1.3.win-amd64.exe
Algorithm Hash digest
SHA256 06b06a1f83b48e8199e67b7815658b901b4ee376cd676e25f43d74f86c77b9d6
MD5 72257e9d825835ed48782a0918c34aed
BLAKE2b-256 67ca3d08ea2422fc1f3b35148f187082398b83095e887409b7025408e5eb54e2

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