RUST-2019 Formatter for Bson
ignores pretty printing {:#}
#491
Labels
tracked-in-jira
Ticket filed in Mongo's Jira system
Bson
ignores pretty printing {:#}
#491
Versions/Environment
rustc 1.82.0-nightly (506052d49 2024-08-16)
Linux
cargo pkgid mongodb
&cargo pkgid bson
)bson
:registry+https://github.com/rust-lang/crates.io-index#[email protected]
mongodb
: N/Adb.version()
)N/A
N/A
Describe the bug
A clear and concise description of what the bug is.
BE SPECIFIC:
Expected behaviour:
Bson
formatting outputs the following:What actually happens:
Bson
formatting outputs the following:clue in the right direction?
If you implemented
Display
manually, then you need to manually check if the user passed in pretty-printingas a parameter and then change your formatting based on that.
You can check it using
formatter.alternate()
in yourDisplay
implementation.server, and/or Rust)?
The issue has likely existed for as long as the crate has.
function produce a crash)?
Nope. Only one, specifically. Formatting with
{:#?}
produces correctly-formatted output.Thank you.
The text was updated successfully, but these errors were encountered: