Skip to content

feat(traits/authn): add log information #44

feat(traits/authn): add log information

feat(traits/authn): add log information #44

GitHub Actions / clippy failed Nov 18, 2024 in 0s

clippy

2 errors, 1 warning

Details

Results

Message level Amount
Internal compiler error 0
Error 2
Warning 1
Note 0
Help 0

Versions

  • rustc 1.82.0 (f6e511eec 2024-10-15)
  • cargo 1.82.0 (8f40fc59f 2024-08-21)
  • clippy 0.1.82 (f6e511e 2024-10-15)

Annotations

Check failure on line 112 in traits/authn/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

`<<Self as UserAuthenticator>::Challenger as Challenger>::Context` doesn't implement `std::fmt::Debug`

error[E0277]: `<<Self as UserAuthenticator>::Challenger as Challenger>::Context` doesn't implement `std::fmt::Debug`
   --> traits/authn/src/lib.rs:112:85
    |
112 |         log::trace!(target: LOG_TARGET, "Check challenge for context ({:?}): {:?}", &cx, &challenge);
    |                                                                                     ^^^ `<<Self as UserAuthenticator>::Challenger as Challenger>::Context` cannot be formatted using `{:?}` because it doesn't implement `std::fmt::Debug`
    |
    = help: the trait `std::fmt::Debug` is not implemented for `<<Self as UserAuthenticator>::Challenger as Challenger>::Context`, which is required by `&<<Self as UserAuthenticator>::Challenger as Challenger>::Context: std::fmt::Debug`
    = note: this error originates in the macro `$crate::__private_api::format_args` which comes from the expansion of the macro `log::trace` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting the associated type
    |
101 |     fn verify_user(&self, credential: &Self::Credential) -> Option<()> where <<Self as UserAuthenticator>::Challenger as Challenger>::Context: std::fmt::Debug {
    |                                                                        +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Check failure on line 80 in traits/authn/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

`<<Self as Authenticator>::Challenger as Challenger>::Context` doesn't implement `std::fmt::Debug`

error[E0277]: `<<Self as Authenticator>::Challenger as Challenger>::Context` doesn't implement `std::fmt::Debug`
  --> traits/authn/src/lib.rs:80:85
   |
80 |         log::trace!(target: LOG_TARGET, "Check challenge for context ({:?}): {:?}", &cx, &challenge);
   |                                                                                     ^^^ `<<Self as Authenticator>::Challenger as Challenger>::Context` cannot be formatted using `{:?}` because it doesn't implement `std::fmt::Debug`
   |
   = help: the trait `std::fmt::Debug` is not implemented for `<<Self as Authenticator>::Challenger as Challenger>::Context`, which is required by `&<<Self as Authenticator>::Challenger as Challenger>::Context: std::fmt::Debug`
   = note: this error originates in the macro `$crate::__private_api::format_args` which comes from the expansion of the macro `log::trace` (in Nightly builds, run with -Z macro-backtrace for more info)
help: consider further restricting the associated type
   |
69 |     fn verify_device(attestation: Self::DeviceAttestation) -> Option<Self::Device> where <<Self as Authenticator>::Challenger as Challenger>::Context: std::fmt::Debug {
   |                                                                                    +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Check warning on line 11 in traits/authn/src/lib.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

constants have by default a `'static` lifetime

warning: constants have by default a `'static` lifetime
  --> traits/authn/src/lib.rs:11:20
   |
11 | const LOG_TARGET: &'static str = "authn";
   |                   -^^^^^^^---- help: consider removing `'static`: `&str`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_static_lifetimes
   = note: `#[warn(clippy::redundant_static_lifetimes)]` on by default