A simple file logger configuration for Python
Project description
ems-simple-logger-config
This is a simple (file) logger configuration for Python.
Installation:
pip install ems-simple-logger-config
On app level: Initialize logger with default values to get a common console output:
from logger import logger
log = logger.setup_logger()
log.info('Some text')
On app level: Alternatively initialize logger with some configuration. If file_name is added a log file will be created.
from logger import logger
log = logger.setup_logger(logger_name = 'SomeLoggerName', log_level = logging.DEBUG, file_name = 'log.txt')
log.info('Some text')
On module level get the logger by
from logger import logger
log = logger.get_logger(__name__)
log.info('Some text')
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ems-simple-logger-config-0.0.3.tar.gz.
File metadata
- Download URL: ems-simple-logger-config-0.0.3.tar.gz
- Upload date:
- Size: 2.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ac94788e76386964cfdebe019857410db5d8000bfa160190d3e3bcc87370b280
|
|
| MD5 |
c7f344d9ff8cd98d6c2da74f492015a9
|
|
| BLAKE2b-256 |
506bef3ef5be7b6bccdfe8e9b3079073e1dba5e80c817de879d1301c239768d6
|
File details
Details for the file ems_simple_logger_config-0.0.3-py3-none-any.whl.
File metadata
- Download URL: ems_simple_logger_config-0.0.3-py3-none-any.whl
- Upload date:
- Size: 3.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
25dc852b7385812a42ce0320b742f650af3daf3f28d21a061f309572d861c9dd
|
|
| MD5 |
cd8834940c7a5cfbe41dac4d3c94d38a
|
|
| BLAKE2b-256 |
f7ecd0d1b9c237449aeabc43631f004c22d2883e944ec5eef98d1d5067477cf4
|