-
Notifications
You must be signed in to change notification settings - Fork 431
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bump Substrate and subxt
dependencies
#1549
Changes from 9 commits
f35f0d2
b0e0501
5f6b07e
b787e14
3e90251
b7799f5
e01295c
376401c
48d7fed
9e44a14
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -18,9 +18,7 @@ use super::{ | |
sr25519, | ||
ContractExecResult, | ||
ContractInstantiateResult, | ||
IdentifyAccount, | ||
Signer, | ||
Verify, | ||
}; | ||
use ink_env::Environment; | ||
|
||
|
@@ -41,7 +39,7 @@ use sp_core::{ | |
use sp_weights::Weight; | ||
use subxt::{ | ||
blocks::ExtrinsicEvents, | ||
tx::ExtrinsicParams, | ||
config::ExtrinsicParams, | ||
OnlineClient, | ||
}; | ||
|
||
|
@@ -118,7 +116,10 @@ pub struct UploadCode<B> { | |
/// A struct that encodes RPC parameters required to instantiate a new smart contract. | ||
#[derive(serde::Serialize, scale::Encode)] | ||
#[serde(rename_all = "camelCase")] | ||
struct RpcInstantiateRequest<C: subxt::Config, E: Environment> { | ||
struct RpcInstantiateRequest<C: subxt::Config, E: Environment> | ||
where | ||
C::AccountId: scale::Codec, | ||
{ | ||
origin: C::AccountId, | ||
value: E::Balance, | ||
gas_limit: Option<Weight>, | ||
|
@@ -176,14 +177,10 @@ pub struct ContractsApi<C: subxt::Config, E: Environment> { | |
impl<C, E> ContractsApi<C, E> | ||
where | ||
C: subxt::Config, | ||
C::AccountId: Into<C::Address> + serde::de::DeserializeOwned, | ||
<C::ExtrinsicParams as ExtrinsicParams<C::Index, C::Hash>>::OtherParams: Default, | ||
|
||
C::AccountId: serde::de::DeserializeOwned, | ||
C::AccountId: scale::Codec, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm not sure why they removed the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @jsdw I meant to ping you about this last week, but yeah this shouldn't have been removed imo. If it was it should've also been mentioned in the release notes - I only saw it while looking through the PR diff There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I spoke with @jsdw about this and the outcome was that all bounds which are not required within |
||
C::Signature: From<sr25519::Signature>, | ||
<C::Signature as Verify>::Signer: From<sr25519::Public>, | ||
<C::Signature as Verify>::Signer: | ||
From<sr25519::Public> + IdentifyAccount<AccountId = C::AccountId>, | ||
sr25519::Signature: Into<C::Signature>, | ||
<C::ExtrinsicParams as ExtrinsicParams<C::Index, C::Hash>>::OtherParams: Default, | ||
|
||
E: Environment, | ||
E::Balance: scale::HasCompact + serde::Serialize, | ||
|
@@ -251,7 +248,7 @@ where | |
) -> ContractInstantiateResult<C::AccountId, E::Balance> { | ||
let code = Code::Upload(code); | ||
let call_request = RpcInstantiateRequest::<C, E> { | ||
origin: signer.account_id().clone(), | ||
origin: subxt::tx::Signer::account_id(signer).clone(), | ||
value, | ||
gas_limit: None, | ||
storage_deposit_limit, | ||
|
@@ -337,7 +334,7 @@ where | |
storage_deposit_limit: Option<E::Balance>, | ||
) -> CodeUploadResult<E::Hash, E::Balance> { | ||
let call_request = RpcCodeUploadRequest::<C, E> { | ||
origin: signer.account_id().clone(), | ||
origin: subxt::tx::Signer::account_id(signer).clone(), | ||
code, | ||
storage_deposit_limit, | ||
determinism: Determinism::Deterministic, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I reckon this bound on the struct is not necessary