clippy
17 warnings
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 0 |
Warning | 17 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.81.0 (eeb90cda1 2024-09-04)
- cargo 1.81.0 (2dbb1af80 2024-08-20)
- clippy 0.1.81 (eeb90cd 2024-09-04)
Annotations
Check warning on line 136 in src/models/transactions/signer_list_set.rs
github-actions / clippy
useless conversion to the same type: `alloc::string::String`
warning: useless conversion to the same type: `alloc::string::String`
--> src/models/transactions/signer_list_set.rs:136:28
|
136 | found: account.into(),
| ^^^^^^^^^^^^^^ help: consider removing `.into()`: `account`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
Check warning on line 160 in src/models/transactions/nftoken_mint.rs
github-actions / clippy
useless conversion to the same type: `models::exceptions::XRPLModelException`
warning: useless conversion to the same type: `models::exceptions::XRPLModelException`
--> src/models/transactions/nftoken_mint.rs:155:21
|
155 | Err(XRPLModelException::ValueTooLong {
| _____________________^
156 | | field: "uri".into(),
157 | | max: MAX_URI_LENGTH,
158 | | found: uri.len(),
159 | | }
160 | | .into())
| |_______________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
help: consider removing `.into()`
|
155 ~ Err(XRPLModelException::ValueTooLong {
156 + field: "uri".into(),
157 + max: MAX_URI_LENGTH,
158 + found: uri.len(),
159 ~ })
|
Check warning on line 143 in src/models/transactions/nftoken_mint.rs
github-actions / clippy
useless conversion to the same type: `models::exceptions::XRPLModelException`
warning: useless conversion to the same type: `models::exceptions::XRPLModelException`
--> src/models/transactions/nftoken_mint.rs:138:21
|
138 | Err(XRPLModelException::ValueTooHigh {
| _____________________^
139 | | field: "transfer_fee".into(),
140 | | max: MAX_TRANSFER_FEE,
141 | | found: transfer_fee,
142 | | }
143 | | .into())
| |_______________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
help: consider removing `.into()`
|
138 ~ Err(XRPLModelException::ValueTooHigh {
139 + field: "transfer_fee".into(),
140 + max: MAX_TRANSFER_FEE,
141 + found: transfer_fee,
142 ~ })
|
Check warning on line 126 in src/models/transactions/nftoken_mint.rs
github-actions / clippy
useless conversion to the same type: `models::exceptions::XRPLModelException`
warning: useless conversion to the same type: `models::exceptions::XRPLModelException`
--> src/models/transactions/nftoken_mint.rs:122:21
|
122 | Err(XRPLModelException::ValueEqualsValue {
| _____________________^
123 | | field1: "issuer".into(),
124 | | field2: "account".into(),
125 | | }
126 | | .into())
| |_______________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
help: consider removing `.into()`
|
122 ~ Err(XRPLModelException::ValueEqualsValue {
123 + field1: "issuer".into(),
124 + field2: "account".into(),
125 ~ })
|
Check warning on line 99 in src/models/requests/ledger_entry.rs
github-actions / clippy
question mark operator is useless here
warning: question mark operator is useless here
--> src/models/requests/ledger_entry.rs:99:9
|
99 | Ok(self._get_field_error()?)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try removing question mark and `Ok()`: `self._get_field_error()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark
Check warning on line 370 in src/core/binarycodec/types/paths.rs
github-actions / clippy
question mark operator is useless here
warning: question mark operator is useless here
--> src/core/binarycodec/types/paths.rs:370:9
|
370 | Ok(Path::new(Some(&buffer))?)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try removing question mark and `Ok()`: `Path::new(Some(&buffer))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark
Check warning on line 354 in src/core/binarycodec/types/paths.rs
github-actions / clippy
question mark operator is useless here
warning: question mark operator is useless here
--> src/core/binarycodec/types/paths.rs:354:9
|
354 | Ok(Self::new(Some(&buffer))?)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try removing question mark and `Ok()`: `Self::new(Some(&buffer))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark
Check warning on line 179 in src/core/binarycodec/types/hash.rs
github-actions / clippy
question mark operator is useless here
warning: question mark operator is useless here
--> src/core/binarycodec/types/hash.rs:179:9
|
179 | Ok(parser.read(read_length)?)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try removing question mark and `Ok()`: `parser.read(read_length)`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_question_mark
= note: `#[warn(clippy::needless_question_mark)]` on by default
Check warning on line 352 in src/core/binarycodec/types/amount.rs
github-actions / clippy
useless conversion to the same type: `core::exceptions::XRPLCoreException`
warning: useless conversion to the same type: `core::exceptions::XRPLCoreException`
--> src/core/binarycodec/types/amount.rs:348:17
|
348 | / XRPLCoreException::SerdeJsonError(XRPLSerdeJsonError::UnexpectedValueType {
349 | | expected: "String/Object".into(),
350 | | found: value,
351 | | })
352 | | .into(),
| |_______________________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
help: consider removing `.into()`
|
348 ~ XRPLCoreException::SerdeJsonError(XRPLSerdeJsonError::UnexpectedValueType {
349 + expected: "String/Object".into(),
350 + found: value,
351 ~ }),
|
Check warning on line 152 in src/core/addresscodec/mod.rs
github-actions / clippy
redundant closure
warning: redundant closure
--> src/core/addresscodec/mod.rs:152:26
|
152 | .map_err(|err| XRPLAddressCodecException::VecResizeError(err))?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `XRPLAddressCodecException::VecResizeError`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure
Check warning on line 279 in src/asynch/transaction/mod.rs
github-actions / clippy
this lifetime isn't used in the function definition
warning: this lifetime isn't used in the function definition
--> src/asynch/transaction/mod.rs:279:33
|
279 | fn is_not_later_rippled_version<'a>(source: String, target: String) -> XRPLHelperResult<bool> {
| ^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#extra_unused_lifetimes
= note: `#[warn(clippy::extra_unused_lifetimes)]` on by default
Check warning on line 272 in src/asynch/transaction/mod.rs
github-actions / clippy
useless conversion to the same type: `asynch::exceptions::XRPLHelperException`
warning: useless conversion to the same type: `asynch::exceptions::XRPLHelperException`
--> src/asynch/transaction/mod.rs:272:27
|
272 | Err(e) => Err(e.into()),
| ^^^^^^^^ help: consider removing `.into()`: `e`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
Check warning on line 99 in src/asynch/transaction/submit_and_wait.rs
github-actions / clippy
useless conversion to the same type: `alloc::string::String`
warning: useless conversion to the same type: `alloc::string::String`
--> src/asynch/transaction/submit_and_wait.rs:98:25
|
98 | / format!("{}: {}", error, response.error_message.unwrap_or("".into()))
99 | | .into(),
| |___________________________________^ help: consider removing `.into()`: `format!("{}: {}", error, response.error_message.unwrap_or("".into()))`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
= note: `#[warn(clippy::useless_conversion)]` on by default
Check warning on line 82 in src/asynch/clients/websocket/websocket_base.rs
github-actions / clippy
redundant closure
warning: redundant closure
--> src/asynch/clients/websocket/websocket_base.rs:82:26
|
82 | .map_err(|e| XRPLWebSocketException::MessageChannelError(e))?;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: replace the closure with the function itself: `XRPLWebSocketException::MessageChannelError`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure
= note: `#[warn(clippy::redundant_closure)]` on by default
Check warning on line 28 in src/asynch/mod.rs
github-actions / clippy
unreachable statement
warning: unreachable statement
--> src/asynch/mod.rs:25:5
|
22 | return;
| ------ any code following this expression is unreachable
...
25 | / {
26 | | embassy_time::Timer::after_secs(1).await;
27 | | return;
28 | | }
| |_____^ unreachable statement
|
= note: `#[warn(unreachable_code)]` on by default
Check warning on line 56 in src/lib.rs
github-actions / clippy
unneeded sub `cfg` when there is only one condition
warning: unneeded sub `cfg` when there is only one condition
--> src/lib.rs:56:7
|
56 | #[cfg(any(feature = "models"))]
| ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `feature = "models"`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#non_minimal_cfg
Check warning on line 45 in src/lib.rs
github-actions / clippy
unneeded sub `cfg` when there is only one condition
warning: unneeded sub `cfg` when there is only one condition
--> src/lib.rs:45:7
|
45 | #[cfg(any(feature = "models"))]
| ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `feature = "models"`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#non_minimal_cfg
= note: `#[warn(clippy::non_minimal_cfg)]` on by default