Skip to content

Commit

Permalink
chore: polygon mumbai -> amoy
Browse files Browse the repository at this point in the history
  • Loading branch information
Vid201 committed Oct 31, 2024
1 parent 386997a commit c51c7f1
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 12 deletions.
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ Silius was tested on the following networks, and some public endpoints are avail
| Ethereum Sepolia| :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/ethereum-sepolia> |
| Ethereum Holesky| :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/ethereum-holesky> |
| Polygon | :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/polygon-mainnet> |
| Polygon Mumbai| :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/polygon-mumbai> |
| Linea | :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/linea-mainnet> |
| Optimism | :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/optimism-mainnet> |
| Optimism Sepolia | :heavy_check_mark: | <https://rpc.silius.xyz/api/v1/chain/optimism-sepolia> |
Expand Down
14 changes: 8 additions & 6 deletions crates/bundler/src/conditional.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,14 @@ where

let signed_tx = self.0.sign_transaction(bundle).await?;

let prefix: Option<String> =
if self.0.get_chainid().await? == Chain::from_named(NamedChain::Polygon).id().into() {
Some("bor".to_string())
} else {
None
};
let prefix: Option<String> = if self.0.get_chainid().await? ==
Chain::from_named(NamedChain::Polygon).id().into() ||
self.0.get_chainid().await? == Chain::from_named(NamedChain::PolygonAmoy).id().into()
{
Some("bor".to_string())
} else {
None
};

let tx = self
.0
Expand Down
2 changes: 1 addition & 1 deletion crates/p2p/src/service/utils.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ pub mod tests {
}

#[tokio::test]
async fn mempool_config_polygon_mumbai() {
async fn mempool_config_polygon_amoy() {
let cid = "QmQfRyE9iVTBqZ17hPSP4tuMzaez83Y5wD874ymyRtj9VE";
let mempool_config = fetch_mempool_config(cid.to_string()).await.unwrap();
assert_eq!(mempool_config.min_stake, 0.into());
Expand Down
8 changes: 4 additions & 4 deletions crates/primitives/src/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ impl ChainSpec {
1337 => Self::dev(),
11155111 => Self::sepolia(),
137 => Self::polygon(),
80001 => Self::polygon_mumbai(),
80002 => Self::polygon_amoy(),
421614 => Self::arbitrum_sepolia(),
_ => Self::default(chain_id),
}
Expand Down Expand Up @@ -67,10 +67,10 @@ impl ChainSpec {
}
}

/// 'ChainSpec' for polygon mumbai
pub fn polygon_mumbai() -> Self {
/// 'ChainSpec' for polygon amoy
pub fn polygon_amoy() -> Self {
Self {
chain: Chain::from(NamedChain::PolygonMumbai),
chain: Chain::from(NamedChain::PolygonAmoy),
block_time: Duration::from_secs(2),
canonical_mempools: vec!["QmQfRyE9iVTBqZ17hPSP4tuMzaez83Y5wD874ymyRtj9VE".into()],
}
Expand Down

0 comments on commit c51c7f1

Please sign in to comment.