Releases: tokio-rs/tracing
tracing-core 0.1.32
tracing-attributes 0.1.27
tracing 0.1.39
This release adds several additional features to the tracing macros. In
addition, it updates the tracing-core dependency to v0.1.32 and
the tracing-attributes dependency to v0.1.27.
Added
- Allow constant field names in macros (#2617)
- Allow setting event names in macros (#2699)
- core: Allow
ValueSets of any length (#2508)
Changed
tracing-attributes: updated to 0.1.27tracing-core: updated to 0.1.32- attributes: Bump minimum version of proc-macro2 to 1.0.60 (#2732)
- attributes: Generate less dead code for async block return type hint (#2709)
Fixed
- Use fully qualified names in macros for items exported from std prelude
(#2621, #2757) - attributes: Allow [
clippy::let_with_type_underscore] in macro-generated
code ([#2609]) - attributes: Allow
unknown_lintsin macro-generated code (#2626) - attributes: Fix a compilation error in
#[instrument]when the"log"
feature is enabled (#2599)
Documented
tracing-attributes 0.1.26
tracing-attributes 0.1.25
This release of tracing-attributes fixes the Clippy lint
let_with_type_underscore in code generated by the #[instrument]
attribute in Rust 1.70+.
Fixed
- Allow [
clippy::let_with_type_underscore] in macro-generated code (#2609)
Thanks to @coolreader19 for contributing to this release!
tracing-core 0.1.31
This release of tracing-core fixes a bug that caused threads which call
dispatcher::get_default before a global default subscriber is set to never
see the global default once it is set. In addition, it includes improvements for
instrumentation performance in some cases, especially when using a global
default dispatcher.
Fixed
- Fixed incorrect thread-local caching of
Dispatch::noneif
dispatcher::get_defaultis called beforedispatcher::set_global_default
(#2593)
Changed
- Cloning a
Dispatchthat points at a global default subscriber no longer
requires anArcreference count increment, improving performance
substantially (#2593) dispatcher::get_defaultno longer attempts to access a thread local if the
scoped dispatcher is not in use, improving performance when the default
dispatcher is global (#2593)- Added
#[inline]annotations called by theevent!andspan!macros to
reduce the size of macro-generated code and improve recording performance
(#2555)
Thanks to new contributor @ldm0 for contributing to this release!
tracing 0.1.38
This tracing release changes the Drop implementation for Instrumented
Futures so that the attached Span is entered when dropping the Future. This
means that events emitted by the Future's Drop implementation will now be
recorded within its Span. It also adds #[inline] hints to methods called in
the event! macro's expansion, for an improvement in both binary size and
performance.
Additionally, this release updates the tracing-attributes dependency to
v0.1.24, which updates the syn dependency to v2.x.x.
tracing-attributes v0.1.24 also includes improvements to the #[instrument]
macro; see the tracing-attributes 0.1.24 release notes for
details.
Added
Instrumentedfutures will now enter the attachedSpanin theirDrop
implementation, allowing events emitted when dropping the future to occur
within the span (#2562)#[inline]attributes for methods called by theevent!macros, making
generated code smaller (#2555)- attributes:
levelargument to#[instrument(err)]and
#[instrument(ret)]to override the level of
the generated return value event (#2335) - attributes: Improved compiler error message when
#[instrument]is added to aconst fn
(#2418)
Changed
tracing-attributes: updated to 0.1.24- Removed unneeded
cfg-ifdependency (#2553) - attributes: Updated
syndependency to 2.0 (#2516)
Fixed
- attributes: Fix
clippy::unreachablewarnings in#[instrument]-generated code (#2356) - attributes: Removed unused "visit" feature flag from
syndependency (#2530)
Documented
- attributes: Documented default level for
#[instrument(err)](#2433) - attributes: Improved documentation for levels in
#[instrument](#2350)
Thanks to @nitnelave, @jsgf, @Abhicodes-crypto, @LukeMathWalker, @andrewpollack,
@quad, @klensy, @davidpdrsn, @dbidwell94, @ldm0, @NobodyXu, @ilsv, and @daxpedda
for contributing to this release!
tracing-attributes 0.1.24
This release of tracing-attributes adds support for passing an optional
level to the err and ret arguments to #[instrument], allowing the level
of the generated return-value event to be overridden. For example,
#[instrument(err(level = "info"))]
fn my_great_function() -> Result<(), &'static str> {
// ...
}will emit an INFO-level event if the function returns an Err.
In addition, this release updates the syn dependency to v2.x.x.
Added
levelargument toerrandretto override the level of the generated
return value event (#2335)- Improved compiler error message when
#[instrument]is added to aconst fn
(#2418)
Changed
- Updated
syndependency to 2.0 (#2516)
Fixed
- Fix
clippy::unreachablewarnings in#[instrument]-generated code (#2356) - Removed unused "visit" feature flag from
syndependency (#2530)
Documented
Thanks to @nitnelave, @jsgf, @Abhicodes-crypto, @LukeMathWalker, @andrewpollack,
@quad, @klensy, @davidpdrsn, and @dbidwell94 for contributign to this release!
tracing-subscriber 0.3.17
This release of tracing-subscriber fixes a build error when using env-filter
with recent versions of the regex crate. It also introduces several minor API
improvements.
Fixed
- env-filter: Add "unicode-case" and "unicode-perl" to the
regex
dependency, fixing a build error with recent versions ofregex(#2566) - A number of minor documentation typos and other fixes (#2384, #2378,
#2368, #2548)
Added
- filter: Add
fmt::Displayimpl forfilter::Targets(#2343) - fmt: Made
with_ansi(false)no longer require the "ansi" feature, so that
ANSI formatting escapes can be disabled without requiring ANSI-specific
dependencies (#2532)
Changed
- fmt: Dim targets in the
Compactformatter, matching the default
formatter (#2409)
Thanks to @keepsimple1, @andrewhalle, @LeoniePhiline, @LukeMathWalker,
@howardjohn, @daxpedda, and @dbidwell94 for contributing to this release!
tracing-subscriber 0.3.16
This release of tracing-subscriber fixes a regression introduced in
v0.3.15 where Option::None's Layer implementation would
set the max level hint to OFF. In addition, it adds several new APIs,
including the Filter::event_enabled method for filtering events based on
fields values, and the ability to log internal errors that occur when writing a
log line.
This release also replaces the dependency on the unmaintained [ansi-term]
crate with the [nu-ansi-term] crate, resolving an informational security
advisory (RUSTSEC-2021-0139) for [ansi-term]'s maintainance status. This
increases the minimum supported Rust version (MSRV) to Rust 1.50+, although the
crate should still compile for the previous MSRV of Rust 1.49+ when the ansi
feature is not enabled.
Fixed
- layer:
Option::None'sLayerimpl always setting themax_level_hint
toLevelFilter::OFF(#2321) - Compilation with
-Z minimal versions(#2246) - env-filter: Clarify that disabled level warnings are emitted by
tracing-subscriber(#2285)
Added
- fmt: Log internal errors to
stderrif writing a log line fails (#2102) - fmt:
FmtLayer::log_internal_errorsand
FmtSubscriber::log_internal_errorsmethods for configuring whether internal
writer errors are printed tostderr(#2102) - fmt:
#[must_use]attributes on builders to warn if aSubscriberis
configured but not set as the default subscriber (#2239) - filter:
Filter::event_enabledmethod for filtering an event based on its
fields (#2245, #2251) - filter:
Targets::default_levelaccessor ([#2242])
Changed
- ansi: Replaced dependency on unmaintained
ansi-termcrate with
nu-ansi-term((#2287, fixes informational advisory RUSTSEC-2021-0139) tracing-core: updated to 0.1.30- Minimum Supported Rust Version (MSRV) increased to Rust 1.50+ (when the
ansi) feature flag is enabled (#2287)
Documented
- fmt: Correct inaccuracies in
fmt::initdocumentation (#2224) - filter: Fix incorrect doc link in
filter::Notcombinator (#2249)
Thanks to new contributors @cgbur, @DesmondWillowbrook, @RalfJung, and
@poliorcetics, as well as returning contributors @CAD97, @connec, @jswrenn,
@guswynn, and @bryangarza, for contributing to this release!