All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
- doc: Fix typo in slog::Value docs (issue #335)
- Thank you to @larswirzenius for noticing this!
- doc: Fix "lazy continuation" in
slog::Logger
doc- This mistake was caught by a new lint
#[warn(clippy::doc_lazy_continuation)]
- This mistake was caught by a new lint
- Fix some internal warnings
- Example: Avoid the new
#[warn(unexpected_cfgs)]
lint. - None of these should affect user crates
- Example: Avoid the new
- nested-values: Fix CI failure caused by
#[deny(unused_extern_crates)]
lint- Switch
#[deny(rust_2018_idioms)]
to#[warn(...)]
to avoid unnecessary build failures in the future. - I don't think this should affect user code.
- Switch
- Add
ErrorRef
wrapper to enable logging error references (PR #327)- The
#
error formatter in macros was updated to automatically selectErrorValue
orErrorRef
(PR #328)
- The
- BIG: Updated to Rust 2018
- NOTE: Old 2015 crates will still work because of excellent 2015/2018 compatibility
- Minimum Supported Rust Version is now 1.49.0
- Add
emit_bytes
method (PR #290)- Control formatting using
BytesKind
enum
- Control formatting using
- Fix support for
feature="nothreads"
- Internal refactoring to make different feature combos much easier (PR #301)
- Switch from Travis CI to Github Actions (fixes #294)
rustfmt --check
now run by default- Require
clippy
to succeed without warnings - Require all feature combinations to pass tests.
- Make exception for
nested-values
feature on MSRV (1.49), becauseerased-serde
dependency requiresedition="2021"
(needs 1.56)
- Make exception for
- Fix
#
format when not used as a last argument. - Implement
Value
forstd::borrow::Cow
- Fix duplicate
AsRef<str>
implementations, fixing support fordynamic-keys
- Fix incorrect 'long' name for
slog::Level::Warning
(fixes issue #282)
- Implement
Hash
forLevel
andFilterLevel
- Add #% for alternate display of the value part
- Implement
Eq
for dynamicKey
s - Add
emit_error
toSerializer
,#
for serializing foreign errors, andimpl Value for std::io::Error
- Add
Serde
(ifnested-values
feature is enabled) to optionally wrap a value that implements [serde::Serialize] so it's written to the log record as an object, rather than a primitive.
- Add #? for pretty-debug printing the value part
- Use fully qualified call syntax for
Logger::log
in macros
- Restored parsing of
Level
andFilterLevel
truncated names
- Added parsing of
Level
andFilterLevel
short names
- Added
FilterLevel::accepts
- Added
as_str
,as_short_str
andDisplay
toFilterLevel
- disable support for i128/u128 types if rustc is old
- Implement Value for 128 bit integers
- Add support 2018-style macro imports
- WARNING: This is a breaking change that we couldn't avoid. Users using
explicitly macro import (like
#[macro_use(slog_o)]
) must add__slog_builtin
to the import list.
- WARNING: This is a breaking change that we couldn't avoid. Users using
explicitly macro import (like
- Bump miminum supported Rust version to 1.26
impl Value for SocketAddr
- Revert broken changes:
- Make
?
and%
formatters inkv!
more flexible - Export local inner macros to help with Rust 2018 testing
- Make
- Export local inner macros to help with Rust 2018 testing
- Stabilize
Record::new
- Make
?
and%
formatters inkv!
more flexible
- Fix (again) problems introduced by
2.2.1
- Fix problems introduced by
2.2.1
- Add
is_x_enabled()
for queering (imprecise) log-level
- Support for named format arguments in format messages. They will now become respectively named key-value pairs.
- Support for nested-values through
emit_serde
, behindnested-values
feature flag, disabled by default for backward compatibility. Note: Consider unstable for the time being. - Support for dynamic key (
String
vs&'static str
), behinddynamic-keys
feature flag, disabled by default for backward compatibility. Note: Consider unstable for the time being.
#[allow(dead_code)
on unused log statements
- Impl
Value
forstd::path::Display
- Remove unnecessary 'static bound on
FnValue
- Update README
- Fix for rust-lang/rust#42125
- Relicense under MPL/Apache/MIT
- Documentation improvements
- Documentation fixes
- Compile time logging level filtering
- Unified and simplified logging macros structure and ordering.
- Added logging Record
tags
. - Refactored key-value pairs traits and structures and overall handling.
- It's now possible to
impl KV for MyStruct
. kv!
can be used to create on stack key-value list.KV
-implementing data can appear on the key-value list directly.
- It's now possible to
- Support chaining of
OwnedKVList
s. ExistingLogger
can be used as aDrain
to allow custom handling logic for a part of the logging hierarchy. - Added associated
Ok
type toDrain
. - Support for
Drain
s unwind safety. - Refactored
Record
to optimize performance on async operations. slog-extra
has been renamed toslog-async
since that's the only functionality it contained.slog-stream
is obsoleted and won't be used inslog v2
at all. It was a wrong abstraction.Decorators
functionality was moved toslog-term
.slog-term
provides openDecorator
traits to allow multiple terminal / file writing backends.slog-term
defaultDecorator
s useterm
crate and should work correctly on all supported OSes.DrainExt
has been removed and utility methods moved directly toDrain
slog-stdlog
utilizesslog-scope
directly.- Support for "typed"
Logger
s to allow squeezing last drops of performance possible, at the cost ofT
inLogger<T>
.
- Support for
fmt::Display
values with%
inkv!
- Added support for own
KV
andValue
implementations - Streamlined the formatting syntax for
log!
and friends; BREAKING - Lazy values need explicit
FnValue
wrapper; BREKING
kv!
macro
- Bunch of trait-related fixes
- Require
MapErr
andFilter
to beUnwindSafe
- Make
Logger::root
return "erased" version - Introduce
Logger::root_typed
for "non-erased"Logger
creation
fmt::Debug
forMutexDrainError
- Parametrize
Logger
over theDrain
it holds and introduce "erased" version - Enforcing
UnwindSafe
Drain
s forLogger
s - Refactored key-value pairs traits and structures
- Renamed some types
- Support chaining of
OwnedKVList
s - Added associated
Ok
type toDrain
- Refactored
Record
to optimize performance on async operations - Minimal rustc version required:
1.15.0
DrainExt
has been removed and utility methods moved directly toDrain
- Macros to create
OwnedKV
andBorrowedKV
Logger
implementsDrain
- Order of key-value pairs is now strictly defined
Logger
implementsDrain
- Creation of
OwnedKeyValueList
- Fix an invalid syntax exposed by nightly rust change (Issue #103)
- Updated documentation
OwnedKeyValueList::id
slog_o
as an alternative name foro
- Cargo publishing mistake.
- BREAKING: Removed default
Send+Sync
fromDrain
OwnedKeyValueList::id
for owned key value unique identification
- BREAKING:
Serializer
takeskey : &'static str
now
- Corner cases in
info!(...)
and other macros
- BREAKING: Rewrite handling of owned values.
use std
ino!
- Implement
fmt::Debug
forLogger
First stable release.