Setup definitions and functions for Interchain Accounts application #719
clippy
18 errors
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 18 |
Warning | 0 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.78.0 (9b00956e5 2024-04-29)
- cargo 1.78.0 (54d8815d0 2024-03-26)
- clippy 0.1.78 (9b00956 2024-04-29)
Annotations
Check failure on line 118 in ibc-apps/ics27-interchain-accounts/src/metadata.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/metadata.rs:118:33
|
118 | let previous_metadata = serde_json::from_str::<Metadata>(previous_version.as_str())
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
Check failure on line 92 in ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs
github-actions / clippy
this function takes 3 arguments but 2 arguments were supplied
error[E0061]: this function takes 3 arguments but 2 arguments were supplied
--> ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs:92:9
|
92 | execute(ctx_b, msg).map_err(InterchainAccountError::source)?;
| ^^^^^^^ --- an argument of type `&mut _` is missing
|
note: function defined here
--> /home/runner/work/ibc-rs/ibc-rs/ibc-core/ics25-handler/src/entrypoint.rs:125:8
|
125 | pub fn execute<Ctx>(
| ^^^^^^^
help: provide the argument
|
92 | execute(ctx_b, /* router */, msg).map_err(InterchainAccountError::source)?;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~
Check failure on line 92 in ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs
github-actions / clippy
the trait bound `ibc_core::client::types::error::ClientError: std::convert::From<<<<Ctx as ibc_core::host::ExecutionContext>::E as ibc_core::client::context::ClientExecutionContext>::ClientStateMut as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not satisfied
error[E0277]: the trait bound `ibc_core::client::types::error::ClientError: std::convert::From<<<<Ctx as ibc_core::host::ExecutionContext>::E as ibc_core::client::context::ClientExecutionContext>::ClientStateMut as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not satisfied
--> ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs:92:17
|
92 | execute(ctx_b, msg).map_err(InterchainAccountError::source)?;
| ------- ^^^^^ the trait `std::convert::From<<<<Ctx as ibc_core::host::ExecutionContext>::E as ibc_core::client::context::ClientExecutionContext>::ClientStateMut as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not implemented for `ibc_core::client::types::error::ClientError`, which is required by `<<<Ctx as ibc_core::host::ExecutionContext>::E as ibc_core::client::context::ClientExecutionContext>::ClientStateMut as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error: std::convert::Into<ibc_core::client::types::error::ClientError>`
| |
| required by a bound introduced by this call
|
= note: the full name for the type has been written to '/home/runner/work/ibc-rs/ibc-rs/target/debug/deps/ibc_app_interchain_accounts-df9a7b190a150b68.long-type-9265073545593745269.txt'
= note: consider using `--verbose` to print the full type name to the console
= note: required for `<<<Ctx as ExecutionContext>::E as ClientExecutionContext>::ClientStateMut as TryFrom<Any>>::Error` to implement `std::convert::Into<ibc_core::client::types::error::ClientError>`
note: required by a bound in `ibc_core::entrypoint::execute`
--> /home/runner/work/ibc-rs/ibc-rs/ibc-core/ics25-handler/src/entrypoint.rs:132:82
|
125 | pub fn execute<Ctx>(
| ------- required by a bound in this function
...
132 | <<Ctx::E as ClientExecutionContext>::ClientStateMut as TryFrom<Any>>::Error: Into<ClientError>,
| ^^^^^^^^^^^^^^^^^ required by this bound in `execute`
= note: the full name for the type has been written to '/home/runner/work/ibc-rs/ibc-rs/target/debug/deps/ibc_app_interchain_accounts-df9a7b190a150b68.long-type-9265073545593745269.txt'
= note: consider using `--verbose` to print the full type name to the console
help: consider extending the `where` clause, but there might be an alternative better way to express this requirement
|
87 | Ctx: InterchainAccountExecutionContext, ibc_core::client::types::error::ClientError: std::convert::From<<<<Ctx as ibc_core::host::ExecutionContext>::E as ibc_core::client::context::ClientExecutionContext>::ClientStateMut as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Check failure on line 91 in ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs
github-actions / clippy
this function takes 3 arguments but 2 arguments were supplied
error[E0061]: this function takes 3 arguments but 2 arguments were supplied
--> ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs:91:9
|
91 | validate(ctx_b, msg.clone()).map_err(InterchainAccountError::source)?;
| ^^^^^^^^ ----------- an argument of type `&_` is missing
|
note: function defined here
--> /home/runner/work/ibc-rs/ibc-rs/ibc-core/ics25-handler/src/entrypoint.rs:51:8
|
51 | pub fn validate<Ctx>(ctx: &Ctx, router: &impl Router, msg: MsgEnvelope) -> Result<(), ContextError>
| ^^^^^^^^
help: provide the argument
|
91 | validate(ctx_b, /* router */, msg.clone()).map_err(InterchainAccountError::source)?;
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Check failure on line 91 in ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs
github-actions / clippy
the trait bound `ibc_core::client::types::error::ClientError: std::convert::From<<<Ctx as ibc_core::host::ValidationContext>::HostClientState as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not satisfied
error[E0277]: the trait bound `ibc_core::client::types::error::ClientError: std::convert::From<<<Ctx as ibc_core::host::ValidationContext>::HostClientState as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not satisfied
--> ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs:91:18
|
91 | validate(ctx_b, msg.clone()).map_err(InterchainAccountError::source)?;
| -------- ^^^^^ the trait `std::convert::From<<<Ctx as ibc_core::host::ValidationContext>::HostClientState as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not implemented for `ibc_core::client::types::error::ClientError`, which is required by `<<Ctx as ibc_core::host::ValidationContext>::HostClientState as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error: std::convert::Into<ibc_core::client::types::error::ClientError>`
| |
| required by a bound introduced by this call
|
= note: required for `<<Ctx as ibc_core::host::ValidationContext>::HostClientState as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error` to implement `std::convert::Into<ibc_core::client::types::error::ClientError>`
note: required by a bound in `ibc_core::entrypoint::validate`
--> /home/runner/work/ibc-rs/ibc-rs/ibc-core/ics25-handler/src/entrypoint.rs:55:52
|
51 | pub fn validate<Ctx>(ctx: &Ctx, router: &impl Router, msg: MsgEnvelope) -> Result<(), ContextError>
| -------- required by a bound in this function
...
55 | <Ctx::HostClientState as TryFrom<Any>>::Error: Into<ClientError>,
| ^^^^^^^^^^^^^^^^^ required by this bound in `validate`
help: consider extending the `where` clause, but there might be an alternative better way to express this requirement
|
87 | Ctx: InterchainAccountExecutionContext, ibc_core::client::types::error::ClientError: std::convert::From<<<Ctx as ibc_core::host::ValidationContext>::HostClientState as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Check failure on line 91 in ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs
github-actions / clippy
the trait bound `ibc_core::client::types::error::ClientError: std::convert::From<<<<Ctx as ibc_core::host::ValidationContext>::V as ibc_core::client::context::ClientValidationContext>::ClientStateRef as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not satisfied
error[E0277]: the trait bound `ibc_core::client::types::error::ClientError: std::convert::From<<<<Ctx as ibc_core::host::ValidationContext>::V as ibc_core::client::context::ClientValidationContext>::ClientStateRef as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not satisfied
--> ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs:91:18
|
91 | validate(ctx_b, msg.clone()).map_err(InterchainAccountError::source)?;
| -------- ^^^^^ the trait `std::convert::From<<<<Ctx as ibc_core::host::ValidationContext>::V as ibc_core::client::context::ClientValidationContext>::ClientStateRef as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>` is not implemented for `ibc_core::client::types::error::ClientError`, which is required by `<<<Ctx as ibc_core::host::ValidationContext>::V as ibc_core::client::context::ClientValidationContext>::ClientStateRef as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error: std::convert::Into<ibc_core::client::types::error::ClientError>`
| |
| required by a bound introduced by this call
|
= note: the full name for the type has been written to '/home/runner/work/ibc-rs/ibc-rs/target/debug/deps/ibc_app_interchain_accounts-df9a7b190a150b68.long-type-10037760129119409342.txt'
= note: consider using `--verbose` to print the full type name to the console
= note: required for `<<<Ctx as ValidationContext>::V as ClientValidationContext>::ClientStateRef as TryFrom<Any>>::Error` to implement `std::convert::Into<ibc_core::client::types::error::ClientError>`
note: required by a bound in `ibc_core::entrypoint::validate`
--> /home/runner/work/ibc-rs/ibc-rs/ibc-core/ics25-handler/src/entrypoint.rs:54:83
|
51 | pub fn validate<Ctx>(ctx: &Ctx, router: &impl Router, msg: MsgEnvelope) -> Result<(), ContextError>
| -------- required by a bound in this function
...
54 | <<Ctx::V as ClientValidationContext>::ClientStateRef as TryFrom<Any>>::Error: Into<ClientError>,
| ^^^^^^^^^^^^^^^^^ required by this bound in `validate`
= note: the full name for the type has been written to '/home/runner/work/ibc-rs/ibc-rs/target/debug/deps/ibc_app_interchain_accounts-df9a7b190a150b68.long-type-10037760129119409342.txt'
= note: consider using `--verbose` to print the full type name to the console
help: consider extending the `where` clause, but there might be an alternative better way to express this requirement
|
87 | Ctx: InterchainAccountExecutionContext, ibc_core::client::types::error::ClientError: std::convert::From<<<<Ctx as ibc_core::host::ValidationContext>::V as ibc_core::client::context::ClientValidationContext>::ClientStateRef as std::convert::TryFrom<ibc_core::primitives::proto::Any>>::Error>
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Check failure on line 155 in ibc-apps/ics27-interchain-accounts/src/host/callback.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/host/callback.rs:155:24
|
155 | let metadata_str = serde_json::to_string(&metadata).map_err(InterchainAccountError::source)?;
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
Check failure on line 150 in ibc-apps/ics27-interchain-accounts/src/host/callback.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/host/callback.rs:150:24
|
150 | let mut metadata = serde_json::from_str::<Metadata>(version_on_a.as_str())
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
Check failure on line 94 in ibc-apps/ics27-interchain-accounts/src/host/callback.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/host/callback.rs:94:20
|
94 | let metadata = serde_json::from_str::<Metadata>(version_on_a.as_str())
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
github-actions / clippy
unreachable expression
error: unreachable expression
--> ibc-apps/ics27-interchain-accounts/src/controller/msgs/register_interchain_account.rs:66:9
|
66 | / RawMsgRegisterInterchainAccount {
67 | | owner: domain.owner.to_string(),
68 | | connection_id: domain.conn_id_on_a.to_string(),
69 | | version: domain.version.to_string(),
70 | | ordering: todo!(),
| | ------- any code following this expression is unreachable
71 | | }
| |_________^ unreachable expression
|
= note: `-D unreachable-code` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(unreachable_code)]`
github-actions / clippy
no method named `lookup_module_by_port` found for mutable reference `&mut ExecCtx` in the current scope
error[E0599]: no method named `lookup_module_by_port` found for mutable reference `&mut ExecCtx` in the current scope
--> ibc-apps/ics27-interchain-accounts/src/controller/handler/register_interchain_account.rs:94:10
|
93 | let module_id = ctx_a
| _____________________-
94 | | .lookup_module_by_port(&port_id_on_a)
| | -^^^^^^^^^^^^^^^^^^^^^ method not found in `&mut ExecCtx`
| |_________|
|
github-actions / clippy
no method named `lookup_module_by_port` found for reference `&ValCtx` in the current scope
error[E0599]: no method named `lookup_module_by_port` found for reference `&ValCtx` in the current scope
--> ibc-apps/ics27-interchain-accounts/src/controller/handler/register_interchain_account.rs:57:10
|
56 | let module_id = ctx_a
| _____________________-
57 | | .lookup_module_by_port(&port_id_on_a)
| | -^^^^^^^^^^^^^^^^^^^^^ method not found in `&ValCtx`
| |_________|
|
Check failure on line 189 in ibc-apps/ics27-interchain-accounts/src/controller/callback.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/controller/callback.rs:189:20
|
189 | let metadata = serde_json::from_str::<Metadata>(version_on_b.as_str())
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
Check failure on line 159 in ibc-apps/ics27-interchain-accounts/src/controller/callback.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/controller/callback.rs:159:20
|
159 | let metadata = serde_json::from_str::<Metadata>(version_on_b.as_str())
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
Check failure on line 65 in ibc-apps/ics27-interchain-accounts/src/controller/callback.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `serde_json`
error[E0433]: failed to resolve: use of undeclared crate or module `serde_json`
--> ibc-apps/ics27-interchain-accounts/src/controller/callback.rs:65:9
|
65 | serde_json::from_str::<Metadata>(version_on_a.as_str())
| ^^^^^^^^^^ use of undeclared crate or module `serde_json`
Check failure on line 9 in ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs
github-actions / clippy
unused import: `ibc_core::router::router::Router`
error: unused import: `ibc_core::router::router::Router`
--> ibc-apps/ics27-interchain-accounts/src/host/handler/on_recv_packet.rs:9:5
|
9 | use ibc_core::router::router::Router;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Check failure on line 1 in ibc-apps/ics27-interchain-accounts/src/controller/msgs/send_tx.rs
github-actions / clippy
unused import: `String`
error: unused import: `String`
--> ibc-apps/ics27-interchain-accounts/src/controller/msgs/send_tx.rs:1:21
|
1 | use alloc::string::{String, ToString};
| ^^^^^^
github-actions / clippy
unused import: `String`
error: unused import: `String`
--> ibc-apps/ics27-interchain-accounts/src/controller/msgs/register_interchain_account.rs:1:21
|
1 | use alloc::string::{String, ToString};
| ^^^^^^
|
= note: `-D unused-imports` implied by `-D warnings`
= help: to override `-D warnings` add `#[allow(unused_imports)]`