python-loguru
Port variant v15
Summary Python logging made (stupidly) simple (3.15)
Package version 0.8.0
Homepage https://github.com/Delgan/loguru
Keywords python
Maintainer Python Automaton
License Not yet specified
Other variants v14
Ravenports Buildsheet | History
Ravensource Port Directory | History
Last modified 13 NOV 2026, 13:25:52 UTC
Port created 08 JAN 2023, 04:18:24 UTC
Subpackage Descriptions
single

[image]

[image] [image] [image] [image] [image] [image] [image]

[image]

______________________________________________________________________ **Loguru** is a library which aims to bring enjoyable logging in Python. Did you ever feel lazy about configuring a logger and used `print()` instead?... I did, yet logging is fundamental to every application and eases the process of debugging. Using **Loguru** you have no excuse not to use logging from the start, this is as simple as `from loguru import logger`. Also, this library is intended to make Python logging less painful by adding a bunch of useful functionalities that solve caveats of the standard loggers. Using logs in your application should be an automatism, **Loguru** tries to make it both pleasant and powerful. ## Installation ` pip install loguru ` ## Features - [Ready to use out of the box without boilerplate] - [No Handler, no Formatter, no Filter: one function to rule them all] - [Easier file logging with rotation / retention / compression] - [Modern string formatting using braces style] - [Exceptions catching within threads or main] - [Pretty logging with colors] - [Asynchronous, Thread-safe, Multiprocess-safe] - [Fully descriptive exceptions] - [Structured logging as needed] - [Lazy evaluation of expensive functions] - [Customizable levels] - [Better datetime handling] - [Suitable for scripts and libraries] - [Entirely compatible with standard logging] - [Personalizable defaults through environment variables] - [Convenient parser] - [Exhaustive notifier] - [10x faster than built-in logging] ## Take the tour ### Ready to use out of the box without boilerplate The main concept of Loguru is that **there is one and only one** [`logger`]. For convenience, it is pre-configured and outputs to `stderr` to begin with (but that's entirely configurable). ```python from loguru import logger logger.debug("That's it, beautiful and simple logging!") ``` The [`logger`] is just an interface which dispatches log messages to configured handlers. Simple, right? ### No Handler, no Formatter, no Filter: one function to rule them all How to add a handler? How to set up logs formatting? How to filter messages? How to set level? One answer: the [`add()`] function. ```python logger.add(sys.stderr, format="{time} {level} {message}", filter="my_module", level="INFO") ``` This function should be used to register [sinks] which are responsible for managing [log messages] contextualized with a [record dict]. A sink can take many forms: a simple function, a string path, a file-like object, a
Configuration Switches (platform-specific settings discarded)
PY314 OFF Build using Python 3.14 PY315 ON Build using Python 3.15
Package Dependencies by Type
Build (only) python315:dev:std
python-pip:single:v15
autoselect-python:single:std
Build and Runtime python315:primary:std
Download groups
main mirror://PYPIWHL/c8/00/9ee7c8da7342b1a5524bca9d036f89e7d1d1e5a6345c9623763eeeac941f
Distribution File Information
e0fba09d6f76ba2d2f4bd1757122942f5a670c702e988b5efaeab99dacba0069 69409 python-src/loguru-0.8.0-py3-none-any.whl
Ports that require python-loguru:v15
python-netbox-network-importer:v15 Tool to import network into Netbox (3.15)