tracing
tracing copied to clipboard
`with_ansi(false)` has no effect to event in span with arg on 2nd layer
Bug Report
Version
tracing v0.1.40 tracing-appender v0.2.3 tracing-subscriber v0.3.18 (*) features = ["env-filter"]
Platform
Windows 64bit
Description
Sorry I'm not sure which sub-crate this issue belongs to.
Please check the code at https://gist.github.com/wesley800/7192074d665243adc47b8216a540aa16 . After compile and running (with --release, I didn't test it in debug mode), one should see a new file named test.log
and some escape characters in it, only on the second log line. I believe the extra chars are the same within console which add color and bold style to the log.
The problem disappears by doing ANY of the following:
- Swap
.with(file_layer)
and.with(console_layer)
, which makesfile_layer
become the first (inner, I guess?) layer. - Delete the span argument
arg
. - Delete the span. (Of course, cause the first log line behaves normally)