{"id":34104098,"url":"https://github.com/srfoster65/simple_logging_config","last_synced_at":"2026-03-12T19:15:44.112Z","repository":{"id":201215114,"uuid":"680098071","full_name":"srfoster65/simple_logging_config","owner":"srfoster65","description":"Simple Logging Configuration","archived":false,"fork":false,"pushed_at":"2023-11-17T22:10:53.000Z","size":663,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-12-17T01:09:49.736Z","etag":null,"topics":["logging"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/srfoster65.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-08-18T10:36:13.000Z","updated_at":"2023-10-19T12:32:23.000Z","dependencies_parsed_at":"2025-12-14T18:01:13.825Z","dependency_job_id":null,"html_url":"https://github.com/srfoster65/simple_logging_config","commit_stats":null,"previous_names":["srfoster65/simple_logging_config"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/srfoster65/simple_logging_config","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srfoster65%2Fsimple_logging_config","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srfoster65%2Fsimple_logging_config/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srfoster65%2Fsimple_logging_config/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srfoster65%2Fsimple_logging_config/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/srfoster65","download_url":"https://codeload.github.com/srfoster65/simple_logging_config/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/srfoster65%2Fsimple_logging_config/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30439658,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-12T14:34:45.044Z","status":"ssl_error","status_checked_at":"2026-03-12T14:09:33.793Z","response_time":114,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["logging"],"created_at":"2025-12-14T18:00:15.116Z","updated_at":"2026-03-12T19:15:44.075Z","avatar_url":"https://github.com/srfoster65.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Overview\n\n[![tests][tests_badge]][tests_url]\n[![codecov][codecov_badge]][codecov_url]\n[![Docs][docs_badge]][docs_url]\n[![PyPI][pypi_badge]][pypi_url]\n[![PyPI - License][license_badge]][license_url]\n\n## Installation\n\nWith Pip:\n\n```text\npip install simple_logging_config\n```\n\n## Usage\n\nThe simple_logging_config package provides a simplified logging configuration.\n\nTo use with the default configuration, only 2 lines of code are required.\n\n```python\nfrom simple_logging_config import configure_logging\n\nconfigure_logging()\n```\n\nOr\n\n```python\nfrom simple_logging_config import SimpleLoggingConfig\n\nSimpleLoggingConfig()\n```\n\nThis will enable **info** level logging to the console and **debug** level logging to a file.\n\nInformation logged to the console is just the log message with no additional detail.  \nInformation logged to file includes the timestamp, log_level, module and message\n\nFor a slightly more complex usecase, using a few additional lines of code, configure_logging is configurable using command line parameters.\n\n```python\n# myscript.py\n\nfrom argparse import ArgumentParser\nfrom simple_logging_config import configure_logging, add_logging_arguments\n\nparser = ArgumentParser(description=\"Test Program\")\nadd_logging_arguments(parser)\nargs = parser.parse_args()\n\nconfigure_logging(**vars(args))\n```\n\nYour script will now accept additional CLI paramaters to configure logging at runtime as shown below.\n\n```text\nusage: myscript.py [-h] [-v | --slc-level LEVELS] [--slc-modules [MODULES ...]] [--slc-log-file-path LOG_FILE_PATH]\n               [--slc-backup-count BACKUP_COUNT] [--slc-config {dual,dual_rotating,dual_detailed,console,file,rotating_file}]      \n\nTest Program\n\noptions:\n  -h, --help            show this help message and exit\n  -v, --verbose         The level of logging verbosity for the default handler. Use multiple times (up to -vvv) for increased      \n                        verbosity.\n  --slc-level LEVELS, --slc-levels LEVELS\n                        The log level(s) to be applied to attached handlers. This value can be a single integer or a string        \n                        representing a defined log level. Or it can be a string representing a dictionary where key/value pairs    \n                        are handler names and the log level to be associated with that handler\n  --slc-modules [MODULES ...]\n                        The names of the modules to be logged. If omitted all modules are logged.\n  --slc-log-file-path LOG_FILE_PATH\n                        The path the log file will be saved to. If this is a folder, the log file will be saved to this folder     \n                        with the file name derived from the name of the calling script. Otherwise, assume this is a full path to   \n                        a named log file.\n  --slc-backup-count BACKUP_COUNT\n                        An integer specifying The number of backup log files to retain.\n  --slc-config {dual,dual_rotating,dual_detailed,console,file,rotating_file}\n                        The name of the logging config to be used.\n\n```\n\n[tests_badge]: https://github.com/srfoster65/simple_logging_config/actions/workflows/build.yml/badge.svg\n[tests_url]: https://github.com/srfoster65/simple_logging_config/actions/workflows/build.yml\n[codecov_badge]: https://codecov.io/gh/srfoster65/simple_logging_config/graph/badge.svg?token=FFNWSCS4BB\n[codecov_url]: https://codecov.io/gh/srfoster65/simple_logging_config\n[docs_badge]: https://github.com/srfoster65/simple_logging_config/actions/workflows/docs.yml/badge.svg\n[docs_url]: https://srfoster65.github.io/simple_logging_config/\n[pypi_badge]: https://img.shields.io/pypi/v/simple-logging-config?logo=python\u0026logoColor=%23cccccc\n[pypi_url]: https://pypi.org/project/simple-logging-config\n[license_badge]: https://img.shields.io/pypi/l/simple-logging-config\n[license_url]: https://srfoster65.github.io/simple_logging_config/license/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsrfoster65%2Fsimple_logging_config","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsrfoster65%2Fsimple_logging_config","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsrfoster65%2Fsimple_logging_config/lists"}