mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 21:31:04 +00:00
[ci] Update ci image with rust 1.77 and 2024-04-10 (#4077)
cc https://github.com/paritytech/ci_cd/issues/974 --------- Co-authored-by: command-bot <> Co-authored-by: Bastian Köcher <info@kchr.de>
This commit is contained in:
committed by
GitHub
parent
b6fab8046e
commit
76719da221
@@ -24,8 +24,8 @@ use polkadot_primitives::{
|
||||
CandidateCommitments, CandidateEvent, CandidateHash, CommittedCandidateReceipt, CoreIndex,
|
||||
CoreState, DisputeState, ExecutorParams, GroupRotationInfo, Hash, Id as ParaId,
|
||||
InboundDownwardMessage, InboundHrmpMessage, NodeFeatures, OccupiedCoreAssumption,
|
||||
PersistedValidationData, PvfCheckStatement, ScrapedOnChainVotes, SessionIndex, SessionInfo,
|
||||
ValidationCode, ValidationCodeHash, ValidatorId, ValidatorIndex, ValidatorSignature,
|
||||
PersistedValidationData, ScrapedOnChainVotes, SessionIndex, SessionInfo, ValidationCode,
|
||||
ValidationCodeHash, ValidatorId, ValidatorIndex,
|
||||
};
|
||||
|
||||
/// For consistency we have the same capacity for all caches. We use 128 as we'll only need that
|
||||
@@ -561,7 +561,7 @@ pub(crate) enum RequestResult {
|
||||
// The structure of each variant is (relay_parent, [params,]*, result)
|
||||
Authorities(Hash, Vec<AuthorityDiscoveryId>),
|
||||
Validators(Hash, Vec<ValidatorId>),
|
||||
MinimumBackingVotes(Hash, SessionIndex, u32),
|
||||
MinimumBackingVotes(SessionIndex, u32),
|
||||
ValidatorGroups(Hash, (Vec<Vec<ValidatorIndex>>, GroupRotationInfo)),
|
||||
AvailabilityCores(Hash, Vec<CoreState>),
|
||||
PersistedValidationData(Hash, ParaId, OccupiedCoreAssumption, Option<PersistedValidationData>),
|
||||
@@ -589,19 +589,16 @@ pub(crate) enum RequestResult {
|
||||
FetchOnChainVotes(Hash, Option<ScrapedOnChainVotes>),
|
||||
PvfsRequirePrecheck(Hash, Vec<ValidationCodeHash>),
|
||||
// This is a request with side-effects and no result, hence ().
|
||||
SubmitPvfCheckStatement(Hash, PvfCheckStatement, ValidatorSignature, ()),
|
||||
#[allow(dead_code)]
|
||||
SubmitPvfCheckStatement(()),
|
||||
ValidationCodeHash(Hash, ParaId, OccupiedCoreAssumption, Option<ValidationCodeHash>),
|
||||
Version(Hash, u32),
|
||||
Disputes(Hash, Vec<(SessionIndex, CandidateHash, DisputeState<BlockNumber>)>),
|
||||
UnappliedSlashes(Hash, Vec<(SessionIndex, CandidateHash, slashing::PendingSlashes)>),
|
||||
KeyOwnershipProof(Hash, ValidatorId, Option<slashing::OpaqueKeyOwnershipProof>),
|
||||
// This is a request with side-effects.
|
||||
SubmitReportDisputeLost(
|
||||
Hash,
|
||||
slashing::DisputeProof,
|
||||
slashing::OpaqueKeyOwnershipProof,
|
||||
Option<()>,
|
||||
),
|
||||
#[allow(dead_code)]
|
||||
SubmitReportDisputeLost(Option<()>),
|
||||
ApprovalVotingParams(Hash, SessionIndex, ApprovalVotingParams),
|
||||
DisabledValidators(Hash, Vec<ValidatorIndex>),
|
||||
ParaBackingState(Hash, ParaId, Option<async_backing::BackingState>),
|
||||
|
||||
@@ -101,7 +101,7 @@ where
|
||||
self.requests_cache.cache_authorities(relay_parent, authorities),
|
||||
Validators(relay_parent, validators) =>
|
||||
self.requests_cache.cache_validators(relay_parent, validators),
|
||||
MinimumBackingVotes(_, session_index, minimum_backing_votes) => self
|
||||
MinimumBackingVotes(session_index, minimum_backing_votes) => self
|
||||
.requests_cache
|
||||
.cache_minimum_backing_votes(session_index, minimum_backing_votes),
|
||||
ValidatorGroups(relay_parent, groups) =>
|
||||
@@ -155,7 +155,7 @@ where
|
||||
self.requests_cache.cache_on_chain_votes(relay_parent, scraped),
|
||||
PvfsRequirePrecheck(relay_parent, pvfs) =>
|
||||
self.requests_cache.cache_pvfs_require_precheck(relay_parent, pvfs),
|
||||
SubmitPvfCheckStatement(_, _, _, ()) => {},
|
||||
SubmitPvfCheckStatement(()) => {},
|
||||
ValidationCodeHash(relay_parent, para_id, assumption, hash) => self
|
||||
.requests_cache
|
||||
.cache_validation_code_hash((relay_parent, para_id, assumption), hash),
|
||||
@@ -170,7 +170,7 @@ where
|
||||
.cache_key_ownership_proof((relay_parent, validator_id), key_ownership_proof),
|
||||
RequestResult::ApprovalVotingParams(_relay_parent, session_index, params) =>
|
||||
self.requests_cache.cache_approval_voting_params(session_index, params),
|
||||
SubmitReportDisputeLost(_, _, _, _) => {},
|
||||
SubmitReportDisputeLost(_) => {},
|
||||
DisabledValidators(relay_parent, disabled_validators) =>
|
||||
self.requests_cache.cache_disabled_validators(relay_parent, disabled_validators),
|
||||
ParaBackingState(relay_parent, para_id, constraints) => self
|
||||
@@ -370,7 +370,7 @@ where
|
||||
async fn poll_requests(&mut self) {
|
||||
// If there are no active requests, this future should be pending forever.
|
||||
if self.active_requests.len() == 0 {
|
||||
return futures::pending!()
|
||||
return futures::pending!();
|
||||
}
|
||||
|
||||
// If there are active requests, this will always resolve to `Some(_)` when a request is
|
||||
@@ -439,7 +439,7 @@ where
|
||||
}};
|
||||
($req_variant:ident, $api_name:ident ($($param:expr),*), ver = $version:expr, $sender:expr, result = ( $($results:expr),* ) ) => {{
|
||||
let sender = $sender;
|
||||
let version: u32 = $version; // enforce type for the version expression
|
||||
let version: u32 = $version; // enforce type for the version expression
|
||||
let runtime_version = client.api_version_parachain_host(relay_parent).await
|
||||
.unwrap_or_else(|e| {
|
||||
gum::warn!(
|
||||
@@ -570,7 +570,8 @@ where
|
||||
SubmitPvfCheckStatement,
|
||||
submit_pvf_check_statement(stmt, signature),
|
||||
ver = 2,
|
||||
sender
|
||||
sender,
|
||||
result = ()
|
||||
)
|
||||
},
|
||||
Request::PvfsRequirePrecheck(sender) => {
|
||||
@@ -606,13 +607,15 @@ where
|
||||
SubmitReportDisputeLost,
|
||||
submit_report_dispute_lost(dispute_proof, key_ownership_proof),
|
||||
ver = Request::SUBMIT_REPORT_DISPUTE_LOST_RUNTIME_REQUIREMENT,
|
||||
sender
|
||||
sender,
|
||||
result = ()
|
||||
),
|
||||
Request::MinimumBackingVotes(index, sender) => query!(
|
||||
MinimumBackingVotes,
|
||||
minimum_backing_votes(index),
|
||||
ver = Request::MINIMUM_BACKING_VOTES_RUNTIME_REQUIREMENT,
|
||||
sender
|
||||
sender,
|
||||
result = (index)
|
||||
),
|
||||
Request::DisabledValidators(sender) => query!(
|
||||
DisabledValidators,
|
||||
|
||||
@@ -148,6 +148,7 @@ enum ApprovalEntryError {
|
||||
InvalidCandidateIndex,
|
||||
DuplicateApproval,
|
||||
UnknownAssignment,
|
||||
#[allow(dead_code)]
|
||||
AssignmentsFollowedDifferentPaths(RequiredRouting, RequiredRouting),
|
||||
}
|
||||
|
||||
|
||||
@@ -953,6 +953,7 @@ enum AdvertisementError {
|
||||
/// parent.
|
||||
ProtocolMisuse,
|
||||
/// Advertisement is invalid.
|
||||
#[allow(dead_code)]
|
||||
Invalid(InsertAdvertisementError),
|
||||
}
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
|
||||
use std::collections::{HashMap, HashSet};
|
||||
|
||||
use futures::{future::RemoteHandle, Future, FutureExt};
|
||||
use futures::{Future, FutureExt};
|
||||
|
||||
use polkadot_node_network_protocol::{
|
||||
request_response::{
|
||||
@@ -64,7 +64,7 @@ pub struct SendTask<M> {
|
||||
/// Status of a particular vote/statement delivery to a particular validator.
|
||||
enum DeliveryStatus {
|
||||
/// Request is still in flight.
|
||||
Pending(RemoteHandle<()>),
|
||||
Pending,
|
||||
/// Succeeded - no need to send request to this peer anymore.
|
||||
Succeeded,
|
||||
}
|
||||
@@ -297,9 +297,8 @@ async fn send_requests<Context, M: 'static + Send + Sync>(
|
||||
metrics.time_dispute_request(),
|
||||
);
|
||||
|
||||
let (remote, remote_handle) = fut.remote_handle();
|
||||
ctx.spawn("dispute-sender", remote.boxed()).map_err(FatalError::SpawnTask)?;
|
||||
statuses.insert(receiver, DeliveryStatus::Pending(remote_handle));
|
||||
ctx.spawn("dispute-sender", fut.boxed()).map_err(FatalError::SpawnTask)?;
|
||||
statuses.insert(receiver, DeliveryStatus::Pending);
|
||||
}
|
||||
|
||||
let msg = NetworkBridgeTxMessage::SendRequests(reqs, IfDisconnected::ImmediateError);
|
||||
|
||||
Reference in New Issue
Block a user