Merge pull request #95 from sephynox/nft-support #264
Annotations
55 warnings
unneeded `return` statement:
src/utils/parse_nftoken_id.rs#L35
warning: unneeded `return` statement
--> src/utils/parse_nftoken_id.rs:35:5
|
35 | return (taxon ^ (384160001 * token_seq + 2459)) % 4294967296;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_return
= note: `#[warn(clippy::needless_return)]` on by default
help: remove `return`
|
35 - return (taxon ^ (384160001 * token_seq + 2459)) % 4294967296;
35 + (taxon ^ (384160001 * token_seq + 2459)) % 4294967296
|
|
struct `FlagCollection` has a public `len` method, but no `is_empty` method:
src/models/flag_collection.rs#L103
warning: struct `FlagCollection` has a public `len` method, but no `is_empty` method
--> src/models/flag_collection.rs:103:5
|
103 | pub fn len(&self) -> usize {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#len_without_is_empty
= note: `#[warn(clippy::len_without_is_empty)]` on by default
|
useless conversion to the same type: `alloc::string::String`:
src/models/transactions/signer_list_set.rs#L136
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
|
useless conversion to the same type: `models::exceptions::XRPLModelException`:
src/models/transactions/nftoken_mint.rs#L155
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 ~ })
|
|
useless conversion to the same type: `models::exceptions::XRPLModelException`:
src/models/transactions/nftoken_mint.rs#L138
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 ~ })
|
|
useless conversion to the same type: `models::exceptions::XRPLModelException`:
src/models/transactions/nftoken_mint.rs#L122
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 ~ })
|
|
useless conversion to the same type: `&[&str]`:
src/models/transactions/amm_deposit.rs#L76
warning: useless conversion to the same type: `&[&str]`
--> src/models/transactions/amm_deposit.rs:76:17
|
76 | ["lp_token_out", "amount"].as_ref().into(),
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `.into()`: `["lp_token_out", "amount"].as_ref()`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
|
question mark operator is useless here:
src/models/requests/ledger_entry.rs#L96
warning: question mark operator is useless here
--> src/models/requests/ledger_entry.rs:96:9
|
96 | 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
|
question mark operator is useless here:
src/core/binarycodec/types/paths.rs#L370
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
|
question mark operator is useless here:
src/core/binarycodec/types/paths.rs#L354
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
|
question mark operator is useless here:
src/core/binarycodec/types/hash.rs#L179
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
|
useless conversion to the same type: `core::exceptions::XRPLCoreException`:
src/core/binarycodec/types/amount.rs#L348
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 ~ }),
|
|
redundant closure:
src/core/addresscodec/mod.rs#L152
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
|
this lifetime isn't used in the function definition:
src/asynch/transaction/mod.rs#L281
warning: this lifetime isn't used in the function definition
--> src/asynch/transaction/mod.rs:281:33
|
281 | 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
|
useless conversion to the same type: `asynch::exceptions::XRPLHelperException`:
src/asynch/transaction/mod.rs#L274
warning: useless conversion to the same type: `asynch::exceptions::XRPLHelperException`
--> src/asynch/transaction/mod.rs:274:27
|
274 | 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
|
useless conversion to the same type: `alloc::string::String`:
src/asynch/transaction/submit_and_wait.rs#L98
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
|
redundant closure:
src/asynch/clients/websocket/websocket_base.rs#L82
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
|
unreachable statement:
src/asynch/mod.rs#L25
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
|
unneeded sub `cfg` when there is only one condition:
src/lib.rs#L56
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
|
unneeded sub `cfg` when there is only one condition:
src/lib.rs#L45
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
|
xrpl-rust
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
|
xrpl-rust
The following actions use a deprecated Node.js version and will be forced to run on node20: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2024-03-07-github-actions-all-actions-will-run-on-node20-instead-of-node16-by-default/
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust:
src/asynch/clients/client.rs#L5
unused import: `alloc::borrow::Cow`
|
xrpl-rust:
src/asynch/mod.rs#L16
unused variable: `seconds`
|
xrpl-rust
`xrpl-rust` (lib) generated 2 warnings (run `cargo fix --lib -p xrpl-rust` to apply 1 suggestion)
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust:
src/asynch/clients/client.rs#L5
unused import: `alloc::borrow::Cow`
|
xrpl-rust:
src/asynch/clients/websocket/mod.rs#L28
unused import: `XRPLClientException`
|
xrpl-rust:
src/asynch/mod.rs#L16
unused variable: `seconds`
|
xrpl-rust
`xrpl-rust` (lib) generated 3 warnings (run `cargo fix --lib -p xrpl-rust` to apply 2 suggestions)
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
xrpl-rust
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
xrpl-rust
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
xrpl-rust
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust:
src/asynch/clients/client.rs#L5
unused import: `alloc::borrow::Cow`
|
xrpl-rust:
src/asynch/clients/websocket/mod.rs#L28
unused import: `XRPLClientException`
|
xrpl-rust:
src/asynch/mod.rs#L16
unused variable: `seconds`
|
xrpl-rust
`xrpl-rust` (lib) generated 3 warnings (run `cargo fix --lib -p xrpl-rust` to apply 2 suggestions)
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust:
src/asynch/clients/client.rs#L5
unused import: `alloc::borrow::Cow`
|
xrpl-rust:
src/asynch/clients/websocket/mod.rs#L28
unused import: `XRPLClientException`
|
xrpl-rust:
src/asynch/mod.rs#L16
unused variable: `seconds`
|
xrpl-rust
`xrpl-rust` (lib) generated 3 warnings (run `cargo fix --lib -p xrpl-rust` to apply 2 suggestions)
|
xrpl-rust
unused manifest key: dev-dependencies.anyhow.no-default-features
|
xrpl-rust:
src/asynch/clients/client.rs#L5
unused import: `alloc::borrow::Cow`
|
xrpl-rust:
src/asynch/clients/websocket/mod.rs#L28
unused import: `XRPLClientException`
|
xrpl-rust
`xrpl-rust` (lib) generated 2 warnings (run `cargo fix --lib -p xrpl-rust` to apply 2 suggestions)
|