[Pkg-rust-maintainers] Bug#1052964: rust-ascii: FTBFS: warning: use of deprecated method `std::error::Error::description`: use the Display impl or to_string()
Lucas Nussbaum
lucas at debian.org
Tue Sep 26 14:47:04 BST 2023
Source: rust-ascii
Version: 1.0.0-1
Severity: serious
Justification: FTBFS
Tags: trixie sid ftbfs
User: lucas at debian.org
Usertags: ftbfs-20230925 ftbfs-trixie
Hi,
During a rebuild of all packages in sid, your package failed to build
on amd64.
Relevant part (hopefully):
> make[1]: Entering directory '/<<PKGBUILDDIR>>'
> dh_auto_test -- test --all
> debian cargo wrapper: options, profiles, parallel: ['parallel=8'] [] ['-j8']
> debian cargo wrapper: rust_type, gnu_type: x86_64-unknown-linux-gnu, x86_64-linux-gnu
> debian cargo wrapper: running subprocess (['env', 'RUST_BACKTRACE=1', '/usr/bin/cargo', '-Zavoid-dev-deps', 'test', '--verbose', '--verbose', '-j8', '--target', 'x86_64-unknown-linux-gnu', '--all'],) {}
> Compiling ascii v1.0.0 (/<<PKGBUILDDIR>>)
> Running `CARGO=/usr/bin/cargo CARGO_CRATE_NAME=ascii CARGO_MANIFEST_DIR=/<<PKGBUILDDIR>> CARGO_PKG_AUTHORS='Thomas Bahn <thomas at thomas-bahn.net>:Torbjørn Birch Moltu <t.b.moltu at lyse.net>:Simon Sapin <simon.sapin at exyr.org>' CARGO_PKG_DESCRIPTION='ASCII-only equivalents to `char`, `str` and `String`.' CARGO_PKG_HOMEPAGE='' CARGO_PKG_LICENSE='Apache-2.0 / MIT' CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=ascii CARGO_PKG_REPOSITORY='https://github.com/tomprogrammer/rust-ascii' CARGO_PKG_RUST_VERSION='' CARGO_PKG_VERSION=1.0.0 CARGO_PKG_VERSION_MAJOR=1 CARGO_PKG_VERSION_MINOR=0 CARGO_PKG_VERSION_PATCH=0 CARGO_PKG_VERSION_PRE='' CARGO_PRIMARY_PACKAGE=1 LD_LIBRARY_PATH='/<<PKGBUILDDIR>>/target/debug/deps:/usr/lib' rustc --crate-name ascii src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --crate-type lib --emit=dep-info,metadata,link -C embed-bitcode=no -C debuginfo=2 --cfg 'feature="default"' --cfg 'feature="std"' -C metadata=89234ed414d4cc11 -C extra-filename=-89234ed414d4cc11 --out-dir /<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps --target x86_64-unknown-linux-gnu -C incremental=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/incremental -L dependency=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps -L dependency=/<<PKGBUILDDIR>>/target/debug/deps -C debuginfo=2 --cap-lints warn -C linker=x86_64-linux-gnu-gcc -C link-arg=-Wl,-z,relro --remap-path-prefix /<<PKGBUILDDIR>>=/usr/share/cargo/registry/ascii-1.0.0 --remap-path-prefix /<<PKGBUILDDIR>>/debian/cargo_registry=/usr/share/cargo/registry`
> Running `CARGO=/usr/bin/cargo CARGO_CRATE_NAME=ascii CARGO_MANIFEST_DIR=/<<PKGBUILDDIR>> CARGO_PKG_AUTHORS='Thomas Bahn <thomas at thomas-bahn.net>:Torbjørn Birch Moltu <t.b.moltu at lyse.net>:Simon Sapin <simon.sapin at exyr.org>' CARGO_PKG_DESCRIPTION='ASCII-only equivalents to `char`, `str` and `String`.' CARGO_PKG_HOMEPAGE='' CARGO_PKG_LICENSE='Apache-2.0 / MIT' CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=ascii CARGO_PKG_REPOSITORY='https://github.com/tomprogrammer/rust-ascii' CARGO_PKG_RUST_VERSION='' CARGO_PKG_VERSION=1.0.0 CARGO_PKG_VERSION_MAJOR=1 CARGO_PKG_VERSION_MINOR=0 CARGO_PKG_VERSION_PATCH=0 CARGO_PKG_VERSION_PRE='' CARGO_PRIMARY_PACKAGE=1 LD_LIBRARY_PATH='/<<PKGBUILDDIR>>/target/debug/deps:/usr/lib' rustc --crate-name ascii src/lib.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --test --cfg 'feature="default"' --cfg 'feature="std"' -C metadata=a801788db4998630 -C extra-filename=-a801788db4998630 --out-dir /<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps --target x86_64-unknown-linux-gnu -C incremental=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/incremental -L dependency=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps -L dependency=/<<PKGBUILDDIR>>/target/debug/deps -C debuginfo=2 --cap-lints warn -C linker=x86_64-linux-gnu-gcc -C link-arg=-Wl,-z,relro --remap-path-prefix /<<PKGBUILDDIR>>=/usr/share/cargo/registry/ascii-1.0.0 --remap-path-prefix /<<PKGBUILDDIR>>/debian/cargo_registry=/usr/share/cargo/registry`
> warning: use of deprecated method `std::error::Error::description`: use the Display impl or to_string()
> --> src/ascii_string.rs:675:20
> |
> 675 | self.error.description()
> | ^^^^^^^^^^^
> |
> = note: `#[warn(deprecated)]` on by default
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_char.rs:713:17
> |
> 713 | fn from(a: AsciiChar) -> $wider {
> | ^
> ...
> 742 | impl_into_partial_eq_ord!{u8, AsciiChar::as_byte}
> | ------------------------------------------------- in this macro invocation
> |
> = note: `#[warn(bindings_with_variant_name)]` on by default
> = note: this warning originates in the macro `impl_into_partial_eq_ord` (in Nightly builds, run with -Z macro-backtrace for more info)
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_char.rs:713:17
> |
> 713 | fn from(a: AsciiChar) -> $wider {
> | ^
> ...
> 743 | impl_into_partial_eq_ord!{char, AsciiChar::as_char}
> | --------------------------------------------------- in this macro invocation
> |
> = note: this warning originates in the macro `impl_into_partial_eq_ord` (in Nightly builds, run with -Z macro-backtrace for more info)
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:204:40
> |
> 204 | &self[self.chars().take_while(|a| a.is_whitespace()).count()..]
> | ^
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:218:26
> |
> 218 | .take_while(|a| a.is_whitespace())
> | ^
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:226:51
> |
> 226 | self.chars().zip(other.chars()).all(|(a, b)| {
> | ^
>
> warning[E0170]: pattern binding `b` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:226:54
> |
> 226 | self.chars().zip(other.chars()).all(|(a, b)| {
> | ^
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:233:13
> |
> 233 | for a in self.chars_mut() {
> | ^ help: to match on the variant, qualify the path: `ascii_char::AsciiChar::a`
>
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:240:13
> |
> 240 | for a in self.chars_mut() {
> | ^ help: to match on the variant, qualify the path: `ascii_char::AsciiChar::a`
>
> warning[E0170]: pattern binding `c` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:614:52
> |
> 614 | if let Some(at) = self.chars.position(|c| c == split_on) {
> | ^
>
> warning[E0170]: pattern binding `c` is named the same as one of the variants of the type `ascii_char::AsciiChar`
> --> src/ascii_str.rs:630:53
> |
> 630 | if let Some(at) = self.chars.rposition(|c| c == split_on) {
> | ^
>
> For more information about this error, try `rustc --explain E0170`.
> warning: `ascii` (lib) generated 11 warnings
> Running `CARGO=/usr/bin/cargo CARGO_CRATE_NAME=tests CARGO_MANIFEST_DIR=/<<PKGBUILDDIR>> CARGO_PKG_AUTHORS='Thomas Bahn <thomas at thomas-bahn.net>:Torbjørn Birch Moltu <t.b.moltu at lyse.net>:Simon Sapin <simon.sapin at exyr.org>' CARGO_PKG_DESCRIPTION='ASCII-only equivalents to `char`, `str` and `String`.' CARGO_PKG_HOMEPAGE='' CARGO_PKG_LICENSE='Apache-2.0 / MIT' CARGO_PKG_LICENSE_FILE='' CARGO_PKG_NAME=ascii CARGO_PKG_REPOSITORY='https://github.com/tomprogrammer/rust-ascii' CARGO_PKG_RUST_VERSION='' CARGO_PKG_VERSION=1.0.0 CARGO_PKG_VERSION_MAJOR=1 CARGO_PKG_VERSION_MINOR=0 CARGO_PKG_VERSION_PATCH=0 CARGO_PKG_VERSION_PRE='' CARGO_PRIMARY_PACKAGE=1 CARGO_TARGET_TMPDIR=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/tmp LD_LIBRARY_PATH='/<<PKGBUILDDIR>>/target/debug/deps:/usr/lib' rustc --crate-name tests tests.rs --error-format=json --json=diagnostic-rendered-ansi,artifacts,future-incompat --emit=dep-info,link -C embed-bitcode=no -C debuginfo=2 --test --cfg 'feature="default"' --cfg 'feature="std"' -C metadata=44aa8b97a27166ac -C extra-filename=-44aa8b97a27166ac --out-dir /<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps --target x86_64-unknown-linux-gnu -C incremental=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/incremental -L dependency=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps -L dependency=/<<PKGBUILDDIR>>/target/debug/deps --extern ascii=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps/libascii-89234ed414d4cc11.rlib -C debuginfo=2 --cap-lints warn -C linker=x86_64-linux-gnu-gcc -C link-arg=-Wl,-z,relro --remap-path-prefix /<<PKGBUILDDIR>>=/usr/share/cargo/registry/ascii-1.0.0 --remap-path-prefix /<<PKGBUILDDIR>>/debian/cargo_registry=/usr/share/cargo/registry`
> warning[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii::AsciiChar`
> --> tests.rs:133:34
> |
> 133 | if case.chars().all(|a| a.is_uppercase() ) {
> | ^
> |
> = note: `#[warn(bindings_with_variant_name)]` on by default
>
> warning: `ascii` (test "tests") generated 1 warning
> warning: `ascii` (lib test) generated 11 warnings (11 duplicates)
> Finished test [unoptimized + debuginfo] target(s) in 1.83s
> Running `/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps/ascii-a801788db4998630`
>
> running 36 tests
> test ascii_char::tests::ascii_case ... ok
> test ascii_char::tests::as_byte_and_char ... ok
> test ascii_char::tests::cmp_wider ... ok
> test ascii_char::tests::fmt_ascii ... ok
> test ascii_char::tests::is_all ... ok
> test ascii_char::tests::is_digit_strange_radixes ... ok
> test ascii_char::tests::new_array_is_correct ... ok
> test ascii_str::tests::as_bytes ... ok
> test ascii_str::tests::as_mut_ascii_str ... ok
> test ascii_str::tests::chars_iter_mut ... ok
> test ascii_char::tests::to_ascii_char ... ok
> test ascii_str::tests::as_str ... ok
> test ascii_str::tests::chars_iter ... ok
> test ascii_str::tests::default ... ok
> test ascii_str::tests::cstr_as_ascii_str ... ok
> test ascii_str::tests::as_ascii_str ... ok
> test ascii_str::tests::generic_as_ascii_str ... ok
> test ascii_str::tests::generic_as_mut_ascii_str ... ok
> test ascii_str::tests::fmt_ascii_str ... ok
> test ascii_str::tests::cstring_as_ascii_str ... ok
> test ascii_str::tests::lines_iter ... ok
> test ascii_str::tests::index ... ok
> test ascii_str::tests::lines_iter_empty ... ok
> test ascii_str::tests::lines_iter_rev ... ok
> test ascii_str::tests::make_ascii_case ... ok
> test ascii_str::tests::split_str ... ok
> test ascii_str::tests::split_str_empty ... ok
> test ascii_str::tests::split_str_rev ... ok
> test ascii_str::tests::to_ascii_case ... ok
> test ascii_string::tests::fmt_ascii_string ... ok
> test ascii_string::tests::from_ascii_vec ... ok
> test ascii_string::tests::into_bytes ... ok
> test ascii_string::tests::from_cstring ... ok
> test ascii_string::tests::into_string ... ok
> test ascii_string::tests::write_fmt ... ok
> test ascii_char::tests::is_digit_bad_radix - should panic ... ok
>
> test result: ok. 36 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.01s
>
> Running `/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps/tests-44aa8b97a27166ac`
>
> running 11 tests
> test ascii_vec ... ok
> test compare_ascii_str_str ... ok
> test compare_ascii_str_slice ... ok
> test compare_ascii_str_string ... ok
> test compare_ascii_string_ascii_str ... ok
> test compare_ascii_string_slice ... ok
> test compare_ascii_string_str ... ok
> test compare_ascii_string_string ... ok
> test extend_from_iterator ... ok
> test into_ascii ... ok
> test to_ascii ... ok
>
> test result: ok. 11 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s
>
> Doc-tests ascii
> Running `rustdoc --crate-type lib --crate-name ascii --test /<<PKGBUILDDIR>>/src/lib.rs --target x86_64-unknown-linux-gnu -L dependency=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps -L dependency=/<<PKGBUILDDIR>>/target/debug/deps --extern ascii=/<<PKGBUILDDIR>>/target/x86_64-unknown-linux-gnu/debug/deps/libascii-89234ed414d4cc11.rlib -C embed-bitcode=no --cfg 'feature="default"' --cfg 'feature="std"' --error-format human`
>
> running 48 tests
> test src/ascii_char.rs - ascii_char::AsciiChar::from_ascii (line 289) ... FAILED
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_blank (line 464) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_printable (line 530) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_digit (line 434) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_control (line 499) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_hexdigit (line 603) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_graphic (line 516) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::as_printable_char (line 623) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_ascii_punctuation (line 588) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::new (line 322) - compile fail ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_lowercase (line 544) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::is_uppercase (line 566) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::new (line 316) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::new (line 309) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::to_ascii_uppercase (line 653) ... ok
> test src/ascii_char.rs - ascii_char::AsciiChar::to_ascii_lowercase (line 669) ... ok
> test src/ascii_str.rs - ascii_str::AsAsciiStr::as_ascii_str (line 756) ... ok
> test src/ascii_str.rs - ascii_str::AsAsciiStr::get_ascii (line 772) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::from_ascii_unchecked (line 101) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::from_ascii (line 82) ... ok
> test src/ascii_str.rs - ascii_str::AsAsciiStr::slice_ascii (line 743) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::is_empty (line 127) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::len (line 114) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::trim (line 186) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::split (line 155) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::trim_end (line 210) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::capacity (line 156) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::clear (line 345) ... ok
> test src/ascii_str.rs - ascii_str::AsciiStr::trim_start (line 198) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::pop (line 260) ... FAILED
> test src/ascii_string.rs - ascii_string::AsciiString::from_raw_parts (line 66) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::from_ascii (line 116) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::insert (line 303) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::is_empty (line 330) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::len (line 317) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::new (line 26) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::push (line 226) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::remove (line 282) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::push_str (line 141) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::reserve (line 173) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::reserve_exact (line 195) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::shrink_to_fit (line 209) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::truncate (line 245) ... ok
> test src/ascii_string.rs - ascii_string::AsciiString::with_capacity (line 40) ... ok
> test src/free_functions.rs - free_functions::caret_decode (line 40) ... ok
> test src/ascii_string.rs - ascii_string::FromAsciiError (line 637) ... ok
> test src/free_functions.rs - free_functions::caret_decode (line 49) ... ok
> test src/free_functions.rs - free_functions::caret_encode (line 12) ... ok
>
> failures:
>
> ---- src/ascii_char.rs - ascii_char::AsciiChar::from_ascii (line 289) stdout ----
> error[E0170]: pattern binding `a` is named the same as one of the variants of the type `ascii::AsciiChar`
> --> src/ascii_char.rs:291:5
> |
> 5 | let a = AsciiChar::from_ascii('g').unwrap();
> | ^
> |
> = note: `#[deny(bindings_with_variant_name)]` on by default
>
> error: aborting due to previous error
>
> For more information about this error, try `rustc --explain E0170`.
> Couldn't compile the test.
> ---- src/ascii_string.rs - ascii_string::AsciiString::pop (line 260) stdout ----
> error[E0170]: pattern binding `c` is named the same as one of the variants of the type `ascii::AsciiChar`
> --> src/ascii_string.rs:263:25
> |
> 6 | assert_eq!(s.pop().map(|c| c.as_char()), Some('o'));
> | ^
> |
> = note: `#[deny(bindings_with_variant_name)]` on by default
>
> error[E0170]: pattern binding `c` is named the same as one of the variants of the type `ascii::AsciiChar`
> --> src/ascii_string.rs:264:25
> |
> 7 | assert_eq!(s.pop().map(|c| c.as_char()), Some('o'));
> | ^
>
> error[E0170]: pattern binding `c` is named the same as one of the variants of the type `ascii::AsciiChar`
> --> src/ascii_string.rs:265:25
> |
> 8 | assert_eq!(s.pop().map(|c| c.as_char()), Some('f'));
> | ^
>
> error: aborting due to 3 previous errors
>
> For more information about this error, try `rustc --explain E0170`.
> Couldn't compile the test.
>
> failures:
> src/ascii_char.rs - ascii_char::AsciiChar::from_ascii (line 289)
> src/ascii_string.rs - ascii_string::AsciiString::pop (line 260)
>
> test result: FAILED. 46 passed; 2 failed; 0 ignored; 0 measured; 0 filtered out; finished in 2.87s
>
> error: doctest failed, to rerun pass `--doc`
> dh_auto_test: error: /usr/share/cargo/bin/cargo test --all returned exit code 101
The full build log is available from:
http://qa-logs.debian.net/2023/09/25/rust-ascii_1.0.0-1_unstable.log
All bugs filed during this archive rebuild are listed at:
https://bugs.debian.org/cgi-bin/pkgreport.cgi?tag=ftbfs-20230925;users=lucas@debian.org
or:
https://udd.debian.org/bugs/?release=na&merged=ign&fnewerval=7&flastmodval=7&fusertag=only&fusertagtag=ftbfs-20230925&fusertaguser=lucas@debian.org&allbugs=1&cseverity=1&ctags=1&caffected=1#results
A list of current common problems and possible solutions is available at
http://wiki.debian.org/qa.debian.org/FTBFS . You're welcome to contribute!
If you reassign this bug to another package, please mark it as 'affects'-ing
this package. See https://www.debian.org/Bugs/server-control#affects
If you fail to reproduce this, please provide a build log and diff it with mine
so that we can identify if something relevant changed in the meantime.
More information about the Pkg-rust-maintainers
mailing list