mirror of
https://github.com/pezkuwichain/revive-differential-tests.git
synced 2026-04-27 16:07:58 +00:00
Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| f97f44bc25 | |||
| fb1d5469c3 | |||
| fb009f65c1 | |||
| 9a9999fb1f | |||
| ab9164e873 | |||
| 32a433eb0a | |||
| dff4c25e24 | |||
| 94026b61f4 | |||
| e433d93cbf | |||
| 408754e8fb | |||
| 59bfffe5fe | |||
| 380ea693be | |||
| d02152b565 |
@@ -16,6 +16,7 @@ use alloy::{
|
|||||||
primitives::{B256, FixedBytes, U256},
|
primitives::{B256, FixedBytes, U256},
|
||||||
signers::local::PrivateKeySigner,
|
signers::local::PrivateKeySigner,
|
||||||
};
|
};
|
||||||
|
use anyhow::Context as _;
|
||||||
use clap::{Parser, ValueEnum, ValueHint};
|
use clap::{Parser, ValueEnum, ValueHint};
|
||||||
use revive_dt_common::types::{ParsedTestSpecifier, PlatformIdentifier};
|
use revive_dt_common::types::{ParsedTestSpecifier, PlatformIdentifier};
|
||||||
use semver::Version;
|
use semver::Version;
|
||||||
@@ -1079,7 +1080,10 @@ impl FromStr for WorkingDirectoryConfiguration {
|
|||||||
fn from_str(s: &str) -> Result<Self, Self::Err> {
|
fn from_str(s: &str) -> Result<Self, Self::Err> {
|
||||||
match s {
|
match s {
|
||||||
"" => Ok(Default::default()),
|
"" => Ok(Default::default()),
|
||||||
_ => Ok(Self::Path(PathBuf::from(s))),
|
_ => PathBuf::from(s)
|
||||||
|
.canonicalize()
|
||||||
|
.context("Failed to canonicalize the working directory path")
|
||||||
|
.map(Self::Path),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -104,7 +104,7 @@ where
|
|||||||
};
|
};
|
||||||
debug!(%tx_hash, "Submitted Transaction");
|
debug!(%tx_hash, "Submitted Transaction");
|
||||||
|
|
||||||
pending_transaction.set_timeout(Some(Duration::from_secs(240)));
|
pending_transaction.set_timeout(Some(Duration::from_secs(120)));
|
||||||
let tx_hash = pending_transaction.watch().await.context(format!(
|
let tx_hash = pending_transaction.watch().await.context(format!(
|
||||||
"Transaction inclusion watching timeout for {tx_hash}"
|
"Transaction inclusion watching timeout for {tx_hash}"
|
||||||
))?;
|
))?;
|
||||||
|
|||||||
@@ -2,12 +2,13 @@
|
|||||||
|
|
||||||
use std::{
|
use std::{
|
||||||
collections::HashMap,
|
collections::HashMap,
|
||||||
|
str::FromStr,
|
||||||
sync::{LazyLock, Mutex},
|
sync::{LazyLock, Mutex},
|
||||||
};
|
};
|
||||||
|
|
||||||
use revive_dt_common::types::VersionOrRequirement;
|
use revive_dt_common::types::VersionOrRequirement;
|
||||||
|
|
||||||
use semver::Version;
|
use semver::{Version, VersionReq};
|
||||||
use sha2::{Digest, Sha256};
|
use sha2::{Digest, Sha256};
|
||||||
|
|
||||||
use crate::list::List;
|
use crate::list::List;
|
||||||
@@ -65,6 +66,9 @@ impl SolcDownloader {
|
|||||||
target: &'static str,
|
target: &'static str,
|
||||||
list: &'static str,
|
list: &'static str,
|
||||||
) -> anyhow::Result<Self> {
|
) -> anyhow::Result<Self> {
|
||||||
|
static MAXIMUM_COMPILER_VERSION_REQUIREMENT: LazyLock<VersionReq> =
|
||||||
|
LazyLock::new(|| VersionReq::from_str("<=0.8.30").unwrap());
|
||||||
|
|
||||||
let version_or_requirement = version.into();
|
let version_or_requirement = version.into();
|
||||||
match version_or_requirement {
|
match version_or_requirement {
|
||||||
VersionOrRequirement::Version(version) => Ok(Self {
|
VersionOrRequirement::Version(version) => Ok(Self {
|
||||||
@@ -79,7 +83,10 @@ impl SolcDownloader {
|
|||||||
.builds
|
.builds
|
||||||
.into_iter()
|
.into_iter()
|
||||||
.map(|build| build.version)
|
.map(|build| build.version)
|
||||||
.filter(|version| requirement.matches(version))
|
.filter(|version| {
|
||||||
|
MAXIMUM_COMPILER_VERSION_REQUIREMENT.matches(version)
|
||||||
|
&& requirement.matches(version)
|
||||||
|
})
|
||||||
.max()
|
.max()
|
||||||
else {
|
else {
|
||||||
anyhow::bail!("Failed to find a version that satisfies {requirement:?}");
|
anyhow::bail!("Failed to find a version that satisfies {requirement:?}");
|
||||||
|
|||||||
+1
-1
Submodule polkadot-sdk updated: a44be635e6...45a0ea734f
+1
-1
Submodule resolc-compiler-tests updated: a9d1f54b74...40ffa2b839
Reference in New Issue
Block a user