diff --git a/Cargo.lock b/Cargo.lock index 88ca1d6..57e8446 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -6860,7 +6860,7 @@ dependencies = [ [[package]] name = "tuktuk-crank-turner" -version = "0.2.26" +version = "0.2.27" dependencies = [ "anchor-client", "anchor-lang", diff --git a/tuktuk-crank-turner/Cargo.toml b/tuktuk-crank-turner/Cargo.toml index 6b27ea8..151d32e 100644 --- a/tuktuk-crank-turner/Cargo.toml +++ b/tuktuk-crank-turner/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "tuktuk-crank-turner" -version = "0.2.26" +version = "0.2.27" authors.workspace = true edition.workspace = true license.workspace = true diff --git a/tuktuk-crank-turner/src/task_processor.rs b/tuktuk-crank-turner/src/task_processor.rs index ce09e6f..f3b60fe 100644 --- a/tuktuk-crank-turner/src/task_processor.rs +++ b/tuktuk-crank-turner/src/task_processor.rs @@ -289,6 +289,19 @@ impl TimedTask { { info!(?self.task_key, "task was already replaced, skipping"); } + TransactionQueueError::SimulatedTransactionError( + TransactionError::InstructionError(_, InstructionError::Custom(code)), + ) if code == 6005 + && ctx + .rpc_client + .anchor_account::(&self.task_key) + .await + .ok() + .flatten() + .is_some_and(|acc| acc.queued_at != self.task.queued_at) => + { + info!(?self.task_key, "task was already replaced, skipping"); + } TransactionQueueError::RawTransactionError(_) | TransactionQueueError::SimulatedTransactionError(_) | TransactionQueueError::TransactionError(_)