Skip to content

Show colored error messages with newer tracing-subscriber versions #4736

@rami3l

Description

@rami3l

Follow up of #4731.

TLDR: Newer versions of tracing-subscriber won't accept color codes as-is, so we had to pin to an older version in #4735.

$ cargo run -- show --jkhjkh
warning: ignoring 'build.analysis' config, pass `-Zbuild-analysis` to enable it
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.09s
     Running `target/debug/rustup-init show --jkhjkh`
error: \x1b[1m\x1b[91merror:\x1b[0m unexpected argument '\x1b[1m\x1b[33mshow\x1b[0m' found

\x1b[1m\x1b[92mUsage:\x1b[0m \x1b[1m\x1b[96mrustup-init[EXE]\x1b[0m \x1b[36m[OPTIONS]\x1b[0m

For more information, try '\x1b[1m\x1b[96m--help\x1b[0m'.
$ cargo run --config env.RUSTUP_FORCE_ARG0=\'rustup\' -- check --no-self-update=foo
warning: ignoring 'build.analysis' config, pass `-Zbuild-analysis` to enable it
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.08s
     Running `target/debug/rustup-init check --no-self-update=foo`
error: unexpected value 'foo' for '--no-self-update' found; no more were expected

Usage: rustup[EXE] check --no-self-update

For more information, try '--help'.

#4731

Upstream issue: tokio-rs/tracing#3369
Same issue in UV: astral-sh/uv#15840

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions