All Versions
18
Latest Version
Avg Release Cycle
95 days
Latest Release
422 days ago
Changelog History
Page 1
Changelog History
Page 1
-
v0.6.0 Changes
January 29, 2022- Remove internal use of
pickle.loads()
to fix the (finally rejected) security vulnerability referenced asCVE-2022-0329 <https://nvd.nist.gov/vuln/detail/CVE-2022-0329>
_ (#563 <https://github.com/Delgan/loguru/issues/563>
_). - โ Modify coroutine sink to make it discard log messages when
loop=None
and no event loop is running (due to internally usingasyncio.get_running_loop()
in place ofasyncio.get_event_loop()
). - โ Remove the possibility to add a coroutine sink with
enqueue=True
ifloop=None
and no event loop is running. - ๐ Change default encoding of file sink to be
utf8
instead oflocale.getpreferredencoding()
(#339 <https://github.com/Delgan/loguru/issues/339>
_). - Prevent non-ascii characters to be escaped while logging JSON message with
serialize=True
(#575 <https://github.com/Delgan/loguru/pull/575>
, thanks@ponponon <https://github.com/ponponon>
). - Fix
flake8
errors and improve code readability (#353 <https://github.com/Delgan/loguru/issues/353>
, thanks@AndrewYakimets <https://github.com/AndrewYakimets>
).
- Remove internal use of
-
v0.5.3 Changes
September 20, 2020- Fix child process possibly hanging at exit while combining
enqueue=True
with third party library likeuwsgi
(#309 <https://github.com/Delgan/loguru/issues/309>
, thanks@dstlmrk <https://github.com/dstlmrk>
). - ๐ Fix possible exception during formatting of non-string messages (
#331 <https://github.com/Delgan/loguru/issues/331>
_).
- Fix child process possibly hanging at exit while combining
-
v0.5.2 Changes
September 06, 2020- ๐ Fix
AttributeError
within handlers usingserialize=True
when callinglogger.exception()
outside of the context of an exception (#296 <https://github.com/Delgan/loguru/issues/296>
_). - ๐ Fix error while logging an exception containing a non-picklable
value
to a handler withenqueue=True
(#298 <https://github.com/Delgan/loguru/issues/298>
_). - Add support for async callable classes (with
__call__
method) used as sinks (#294 <https://github.com/Delgan/loguru/pull/294>
, thanks@jessekrubin <https://github.com/jessekrubin>
).
- ๐ Fix
-
v0.5.1 Changes
June 12, 2020- ๐ฒ Modify the way the
extra
dict is used byLogRecord
in order to prevent possibleKeyError
with standardlogging
handlers (#271 <https://github.com/Delgan/loguru/issues/271>
_). - โ Add a new
default
optional argument tologger.catch()
, it should be the returned value by the decorated function in case an error occurred (#272 <https://github.com/Delgan/loguru/issues/272>
_). - ๐ Fix
ValueError
when usingserialize=True
in combination withlogger.catch()
orlogger.opt(record=True)
due to circular reference of therecord
dict (#286 <https://github.com/Delgan/loguru/issues/286>
_).
- ๐ฒ Modify the way the
-
v0.5.0 Changes
May 17, 2020- โ Remove the possibility to modify the severity
no
of levels once they have been added in order to prevent surprising behavior (#209 <https://github.com/Delgan/loguru/issues/209>
_). - Add better support for "structured logging" by automatically adding
**kwargs
to theextra
dict besides using these arguments to format the message. This behavior can be disabled by setting the new.opt(capture=False)
parameter (#2 <https://github.com/Delgan/loguru/issues/2>
_). - โ Add a new
onerror
optional argument tologger.catch()
, it should be a function which will be called when an exception occurs in order to customize error handling (#224 <https://github.com/Delgan/loguru/issues/224>
_). - โ Add a new
exclude
optional argument tologger.catch()
, is should be a type of exception to be purposefully ignored and propagated to the caller without being logged (#248 <https://github.com/Delgan/loguru/issues/248>
_). - Modify
complete()
to make it callable from non-asynchronous functions, it can thus be used ifenqueue=True
to make sure all messages have been processed (#231 <https://github.com/Delgan/loguru/issues/231>
_). - ๐ Fix possible deadlocks on Linux when
multiprocessing.Process()
collides withenqueue=True
orthreading
(#231 <https://github.com/Delgan/loguru/issues/231>
_). - ๐ Fix
compression
function not executable concurrently due to file renaming (to resolve conflicts) being performed after and not before it (#243 <https://github.com/Delgan/loguru/issues/243>
_). - Fix the filter function listing files for
retention
being too restrictive, it now matches files based on the pattern"basename(.*).ext(.*)"
(#229 <https://github.com/Delgan/loguru/issues/229>
_). - ๐ Fix the impossibility to
remove()
a handler if an exception is raised while the sink'stop()
function is called (#237 <https://github.com/Delgan/loguru/issues/237>
_). - ๐ Fix file sink left in an unstable state if an exception occurred during
retention
orcompression
process (#238 <https://github.com/Delgan/loguru/issues/238>
_). - ๐ Fix situation where changes made to
record["message"]
were unexpectedly ignored whenopt(colors=True)
, causing "out-of-date"message
to be logged due to implementation details (#221 <https://github.com/Delgan/loguru/issues/221>
_). - ๐ Fix possible exception if a stream having an
isatty()
method returningTrue
but not being compatible withcolorama
is used on Windows (#249 <https://github.com/Delgan/loguru/issues/249>
_). - ๐ Fix exceptions occurring in coroutine sinks never retrieved and hence causing warnings (
#227 <https://github.com/Delgan/loguru/issues/227>
_).
- โ Remove the possibility to modify the severity
-
v0.4.1 Changes
January 19, 2020- ๐ Deprecate the
ansi
parameter of.opt()
in favor ofcolors
which is a name more appropriate. - Prevent unrelated files and directories to be incorrectly collected thus causing errors during the
retention
process (#195 <https://github.com/Delgan/loguru/issues/195>
, thanks@gazpachoking <https://github.com/gazpachoking>
). - ๐ฒ Strip color markups contained in
record["message"]
when logging with.opt(ansi=True)
instead of leaving them as is (#198 <https://github.com/Delgan/loguru/issues/198>
_). - Ignore color markups contained in
*args
and**kwargs
when logging with.opt(ansi=True)
, leave them as is instead of trying to use them to colorize the message which could cause undesirable errors (#197 <https://github.com/Delgan/loguru/issues/197>
_).
- ๐ Deprecate the
-
v0.4.0 Changes
December 02, 2019- โ Add support for coroutine functions used as sinks and add the new
logger.complete()
asynchronous method toawait
them (#171 <https://github.com/Delgan/loguru/issues/171>
_). - โ Add a way to filter logs using one level per module in the form of a
dict
passed to thefilter
argument (#148 <https://github.com/Delgan/loguru/issues/148>
_). - โ Add type hints to annotate the public methods using a
.pyi
stub file (#162 <https://github.com/Delgan/loguru/issues/162>
_). - โ Add support for
copy.deepcopy()
of thelogger
allowing multiple independent loggers with separate set of handlers (#72 <https://github.com/Delgan/loguru/issues/72>
_). - โ Add the possibility to convert
datetime
to UTC before formatting (in logs and filenames) by adding"!UTC"
at the end of the time format specifier (#128 <https://github.com/Delgan/loguru/issues/128>
_). - โ Add the level
name
as the first argument of namedtuple returned by the.level()
method. - โ Remove
class
objects from the list of supported sinks and restrict usage of**kwargs
in.add()
to file sink only. User is in charge of instantiating sink and wrapping additional keyword arguments if needed, before passing it to the.add()
method. - ๐ง Rename the
logger.configure()
keyword argumentpatch
topatcher
so it better matches the signature oflogger.patch()
. - ๐ Fix incompatibility with
multiprocessing
on Windows by entirely refactoring the internal structure of thelogger
so it can be inherited by child processes along with added handlers (#108 <https://github.com/Delgan/loguru/issues/108>
_). - Fix
AttributeError
while using a file sink on some distributions (like Alpine Linux) missing theos.getxattr
andos.setxattr
functions (#158 <https://github.com/Delgan/loguru/pull/158>
, thanks@joshgordon <https://github.com/joshgordon>
). - ๐ Fix values wrongly displayed for keyword arguments during exception formatting with
diagnose=True
(#144 <https://github.com/Delgan/loguru/issues/144>
_). - ๐ Fix logging messages wrongly chopped off at the end while using standard
logging.Handler
sinks with.opt(raw=True)
(#136 <https://github.com/Delgan/loguru/issues/136>
_). - ๐ Fix potential errors during rotation if destination file exists due to large resolution clock on Windows (
#179 <https://github.com/Delgan/loguru/issues/179>
_). - ๐ Fix an error using a
filter
function "by name" while receiving a log withrecord["name"]
equals toNone
. - ๐ Fix incorrect record displayed while handling errors (if
catch=True
) occurring because of non-picklable objects (ifenqueue=True
). - Prevent hypothetical
ImportError
if a Python installation is missing the built-indistutils
module (#118 <https://github.com/Delgan/loguru/issues/118>
_). - Raise
TypeError
instead ofValueError
when alogger
method is called with argument of invalid type. - Raise
ValueError
if the built-informat()
andfilter()
functions are respectively used asformat
andfilter
arguments of theadd()
method. This helps the user to understand the problem, as such a mistake can quite easily occur (#177 <https://github.com/Delgan/loguru/issues/177>
_). - โ Remove inheritance of some record dict attributes to
str
(for"level"
,"file"
,"thread"
and"process"
). - Give a name to the worker thread used when
enqueue=True
(#174 <https://github.com/Delgan/loguru/pull/174>
, thanks@t-mart <https://github.com/t-mart>
).
- โ Add support for coroutine functions used as sinks and add the new
-
v0.3.2 Changes
July 21, 2019- Fix exception during import when executing Python with
-s
and-S
flags causingsite.USER_SITE
to be missing (#114 <https://github.com/Delgan/loguru/issues/114>
_).
- Fix exception during import when executing Python with
-
v0.3.1 Changes
July 13, 2019- ๐ Fix
retention
androtation
issues when file sink initiliazed withdelay=True
(#113 <https://github.com/Delgan/loguru/issues/113>
_). - ๐ Fix
"sec"
no longer recognized as a valid duration unit for filerotation
andretention
arguments. - ๐ป Ensure stack from the caller is displayed while formatting exception of a function decorated with
@logger.catch
whenbacktrace=False
. - Modify datetime used to automatically rename conflicting file when rotating (it happens if file already exists because
"{time}"
not presents in filename) so it's based on the file creation time rather than the current time.
- ๐ Fix
-
v0.3.0 Changes
June 29, 2019- โ Remove all dependencies previously needed by
loguru
(on Windows platform, it solely remainscolorama
andwin32-setctime
). - โ Add a new
logger.patch()
method which can be used to modify the record dict on-the-fly before it's being sent to the handlers. - Modify behavior of sink option
backtrace
so it only extends the stacktrace upward, the display of variables values is now controlled with the newdiagnose
argument (#49 <https://github.com/Delgan/loguru/issues/49>
_). - ๐ Change behavior of
rotation
option in file sinks: it is now based on the file creation time rather than the current time, note that proper support may differ depending on your platform (#58 <https://github.com/Delgan/loguru/issues/58>
_). - ๐ฉ Raise errors on unknowns color tags rather than silently ignoring them (
#57 <https://github.com/Delgan/loguru/issues/57>
_). - โ Add the possibility to auto-close color tags by using
</>
(e.g.<yellow>message</>
). - โ Add coloration of exception traceback even if
diagnose
andbacktrace
options areFalse
. - โ Add a way to limit the depth of formatted exceptions traceback by setting the conventional
sys.tracebacklimit
variable (#77 <https://github.com/Delgan/loguru/issues/77>
_). - Add
__repr__
value to thelogger
for convenient debugging (#84 <https://github.com/Delgan/loguru/issues/84>
_). - โ Remove colors tags mixing directives (e.g.
<red,blue>
) for simplification. - ๐ป Make the
record["exception"]
attribute unpackable as a(type, value, traceback)
tuple. - Fix error happening in some rare circumstances because
frame.f_globals
dict did not contain"__name__"
key and hence prevented Loguru to retrieve the module's name. From now,record["name"]
will be equal toNone
in such case (#62 <https://github.com/Delgan/loguru/issues/62>
_). - ๐ Fix logging methods not being serializable with
pickle
and hence raising exception while being passed to somemultiprocessing
functions (#102 <https://github.com/Delgan/loguru/issues/102>
_). - ๐ Fix exception stack trace not colorizing source code lines on Windows.
- ๐ Fix possible
AttributeError
while formatting exceptions within acelery
task (#52 <https://github.com/Delgan/loguru/issues/52>
_). - ๐ Fix
logger.catch
decorator not working with generator and coroutine functions (#75 <https://github.com/Delgan/loguru/issues/75>
_). - ๐ Fix
record["path"]
case being normalized for no necessary reason (#85 <https://github.com/Delgan/loguru/issues/85>
_). - ๐ Fix some Windows terminal emulators (mintty) not correctly detected as supporting colors, causing ansi codes to be automatically stripped (
#104 <https://github.com/Delgan/loguru/issues/104>
_). - ๐ Fix handler added with
enqueue=True
stopping working if exception was raised in sink althoughcatch=True
. - ๐ Fix thread-safety of
enable()
anddisable()
being called during logging. - โ
Use Tox to run tests (
#41 <https://github.com/Delgan/loguru/issues/41>
_).
- โ Remove all dependencies previously needed by