mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-12 21:41:12 +00:00
pre-checking: Reject failed PVFs (#6492)
* pre-checking: Reject failed PVFs * paras: immediately reject any PVF that cannot reach a supermajority * Make the `quorum` reject condition a bit more clear semantically * Add comment * Update implementer's guide * Update a link Not related to the rest of the PR, but I randomly noticed and fixed this. * Update runtime/parachains/src/paras/tests.rs Co-authored-by: s0me0ne-unkn0wn <48632512+s0me0ne-unkn0wn@users.noreply.github.com> * Remove unneeded loop * Log PVF retries using `info!` * Change retry logs to `warn!` and add preparation failure log * Log PVF execution failure * Clarify why we reject failed PVFs * Fix PVF reject runtime benchmarks Co-authored-by: s0me0ne-unkn0wn <48632512+s0me0ne-unkn0wn@users.noreply.github.com>
This commit is contained in:
@@ -525,7 +525,7 @@ async fn handle_execute_pvf(
|
||||
},
|
||||
ArtifactState::FailedToProcess { last_time_failed, num_failures, error } => {
|
||||
if can_retry_prepare_after_failure(*last_time_failed, *num_failures, error) {
|
||||
gum::debug!(
|
||||
gum::warn!(
|
||||
target: LOG_TARGET,
|
||||
?pvf,
|
||||
?artifact_id,
|
||||
@@ -599,7 +599,7 @@ async fn handle_heads_up(
|
||||
},
|
||||
ArtifactState::FailedToProcess { last_time_failed, num_failures, error } => {
|
||||
if can_retry_prepare_after_failure(*last_time_failed, *num_failures, error) {
|
||||
gum::debug!(
|
||||
gum::warn!(
|
||||
target: LOG_TARGET,
|
||||
?active_pvf,
|
||||
?artifact_id,
|
||||
@@ -728,18 +728,18 @@ async fn handle_prepare_done(
|
||||
Ok(cpu_time_elapsed) =>
|
||||
ArtifactState::Prepared { last_time_needed: SystemTime::now(), cpu_time_elapsed },
|
||||
Err(error) => {
|
||||
gum::debug!(
|
||||
let last_time_failed = SystemTime::now();
|
||||
let num_failures = *num_failures + 1;
|
||||
|
||||
gum::warn!(
|
||||
target: LOG_TARGET,
|
||||
artifact_id = ?artifact_id,
|
||||
num_failures = ?num_failures,
|
||||
"Failed to process artifact: {}",
|
||||
?artifact_id,
|
||||
time_failed = ?last_time_failed,
|
||||
%num_failures,
|
||||
"artifact preparation failed: {}",
|
||||
error
|
||||
);
|
||||
ArtifactState::FailedToProcess {
|
||||
last_time_failed: SystemTime::now(),
|
||||
num_failures: *num_failures + 1,
|
||||
error,
|
||||
}
|
||||
ArtifactState::FailedToProcess { last_time_failed, num_failures, error }
|
||||
},
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user