From ebb414615868afa05b847c9d59dec2ef5a51f322 Mon Sep 17 00:00:00 2001 From: Shashank Date: Thu, 18 Jun 2026 20:47:51 +0530 Subject: [PATCH 1/4] fix StateGetNetworkParams rpc --- docs/openrpc-specs/v0.json | 7 ++++++- docs/openrpc-specs/v1.json | 7 ++++++- scripts/devnet/.env | 2 +- scripts/tests/api_compare/.env | 2 +- scripts/tests/api_compare/filter-list | 4 ++++ scripts/tests/api_compare/filter-list-gateway | 6 ++++++ scripts/tests/api_compare/filter-list-offline | 2 ++ scripts/tests/bootstrapper/.env | 2 +- scripts/tests/snapshot_parity/.env | 2 +- src/rpc/methods/state.rs | 9 +++++++-- src/rpc/snapshots/forest__rpc__tests__rpc__v0.snap | 4 ++++ src/rpc/snapshots/forest__rpc__tests__rpc__v1.snap | 4 ++++ 12 files changed, 43 insertions(+), 8 deletions(-) diff --git a/docs/openrpc-specs/v0.json b/docs/openrpc-specs/v0.json index 0314c63f3d9e..b8f6aacef6d4 100644 --- a/docs/openrpc-specs/v0.json +++ b/docs/openrpc-specs/v0.json @@ -10257,6 +10257,10 @@ "UpgradeWatermelonHeight": { "type": "integer", "format": "int64" + }, + "UpgradeXxHeight": { + "type": "integer", + "format": "int64" } }, "required": [ @@ -10292,7 +10296,8 @@ "UpgradeTeepHeight", "UpgradeTockHeight", "UpgradeGoldenWeekHeight", - "UpgradeFireHorseHeight" + "UpgradeFireHorseHeight", + "UpgradeXxHeight" ] }, "GasTrace": { diff --git a/docs/openrpc-specs/v1.json b/docs/openrpc-specs/v1.json index 1697bf027c1b..07c986e29846 100644 --- a/docs/openrpc-specs/v1.json +++ b/docs/openrpc-specs/v1.json @@ -10471,6 +10471,10 @@ "UpgradeWatermelonHeight": { "type": "integer", "format": "int64" + }, + "UpgradeXxHeight": { + "type": "integer", + "format": "int64" } }, "required": [ @@ -10506,7 +10510,8 @@ "UpgradeTeepHeight", "UpgradeTockHeight", "UpgradeGoldenWeekHeight", - "UpgradeFireHorseHeight" + "UpgradeFireHorseHeight", + "UpgradeXxHeight" ] }, "GasTrace": { diff --git a/scripts/devnet/.env b/scripts/devnet/.env index 4a02982f5b14..51d1e210e6aa 100644 --- a/scripts/devnet/.env +++ b/scripts/devnet/.env @@ -1,4 +1,4 @@ -LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.0-rc1-2k +LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.1-rc1-2k FOREST_DATA_DIR=/forest_data LOTUS_DATA_DIR=/lotus_data FIL_PROOFS_PARAMETER_CACHE=/var/tmp/filecoin-proof-parameters diff --git a/scripts/tests/api_compare/.env b/scripts/tests/api_compare/.env index a393f0fc0bb0..c98db88f7db5 100644 --- a/scripts/tests/api_compare/.env +++ b/scripts/tests/api_compare/.env @@ -1,6 +1,6 @@ # Note: this should be a `fat` image so that it contains the pre-downloaded filecoin proof parameters FOREST_IMAGE=ghcr.io/chainsafe/forest:edge-fat -LOTUS_IMAGE=filecoin/lotus-all-in-one:72ac4c059-calibnet +LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.1-rc1-calibnet FIL_PROOFS_PARAMETER_CACHE=/var/tmp/filecoin-proof-parameters LOTUS_RPC_PORT=1234 LOTUS_VIA_GATEWAY_RPC_PORT=4568 diff --git a/scripts/tests/api_compare/filter-list b/scripts/tests/api_compare/filter-list index 0656b736d920..f749dc6fadbc 100644 --- a/scripts/tests/api_compare/filter-list +++ b/scripts/tests/api_compare/filter-list @@ -1,2 +1,6 @@ # This list contains potentially broken methods (or tests) that are ignored. # They should be considered bugged, and not used until the root cause is resolved. + +!Filecoin.EthEstimateGas +!Filecoin.EthGetBlockByHash +!Filecoin.EthGetBlockByNumber diff --git a/scripts/tests/api_compare/filter-list-gateway b/scripts/tests/api_compare/filter-list-gateway index df7c3724e05d..870225d6f8c0 100644 --- a/scripts/tests/api_compare/filter-list-gateway +++ b/scripts/tests/api_compare/filter-list-gateway @@ -9,6 +9,7 @@ !Filecoin.ChainStatObj !Filecoin.ChainTipSetWeight !Filecoin.EthGetBlockReceiptsLimited +!Filecoin.EthGetTransactionByHashLimited !Filecoin.F3 !Filecoin.GasEstimateGasLimit !Filecoin.MinerCreateBlock @@ -64,3 +65,8 @@ !Filecoin.StateSearchMsg # https://github.com/filecoin-project/lotus/pull/13562 !Filecoin.EthGetTransactionReceiptLimited +# https://github.com/filecoin-project/lotus/pull/13644 +!Filecoin.EthEstimateGas +# https://github.com/filecoin-project/lotus/pull/13618 +!Filecoin.EthGetBlockByHash +!Filecoin.EthGetBlockByNumber diff --git a/scripts/tests/api_compare/filter-list-offline b/scripts/tests/api_compare/filter-list-offline index 7aa00e70a803..782ee74579fe 100644 --- a/scripts/tests/api_compare/filter-list-offline +++ b/scripts/tests/api_compare/filter-list-offline @@ -33,3 +33,5 @@ !Filecoin.ChainSetHead !Filecoin.EthTraceFilter !Filecoin.EthTraceReplayBlockTransactions +!Filecoin.EthEstimateGas +!Filecoin.EthGetBlockByHash diff --git a/scripts/tests/bootstrapper/.env b/scripts/tests/bootstrapper/.env index 311fe7e5c641..668da3ea672a 100644 --- a/scripts/tests/bootstrapper/.env +++ b/scripts/tests/bootstrapper/.env @@ -1,5 +1,5 @@ # Note: this should be a `fat` image so that it contains the pre-downloaded filecoin proof parameters -LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.0-rc1-calibnet +LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.1-rc1-calibnet FIL_PROOFS_PARAMETER_CACHE=/var/tmp/filecoin-proof-parameters LOTUS_RPC_PORT=1234 FOREST_RPC_PORT=2345 diff --git a/scripts/tests/snapshot_parity/.env b/scripts/tests/snapshot_parity/.env index d7e81e8d2a99..dcb88d1dbea6 100644 --- a/scripts/tests/snapshot_parity/.env +++ b/scripts/tests/snapshot_parity/.env @@ -1,4 +1,4 @@ -LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.0-rc1-calibnet +LOTUS_IMAGE=filecoin/lotus-all-in-one:v1.36.1-rc1-calibnet FIL_PROOFS_PARAMETER_CACHE=/var/tmp/filecoin-proof-parameters LOTUS_RPC_PORT=1234 FOREST_RPC_PORT=2345 diff --git a/src/rpc/methods/state.rs b/src/rpc/methods/state.rs index 236119e6ff62..340edf1a565f 100644 --- a/src/rpc/methods/state.rs +++ b/src/rpc/methods/state.rs @@ -14,7 +14,7 @@ use crate::eth::EthChainId; use crate::interpreter::{MessageCallbackCtx, VMTrace}; use crate::libp2p::NetworkMessage; use crate::lotus_json::{LotusJson, lotus_json_with_self}; -use crate::networks::ChainConfig; +use crate::networks::{ChainConfig, NetworkChain}; use crate::prelude::*; use crate::rpc::registry::actors_reg::load_and_serialize_actor_state; use crate::shim::actors::market::DealState; @@ -3251,7 +3251,8 @@ pub struct ForkUpgradeParams { upgrade_tock_height: ChainEpoch, upgrade_golden_week_height: ChainEpoch, upgrade_fire_horse_height: ChainEpoch, - //upgrade_xxx_height: ChainEpoch, + // placeholder for the next network upgrade + upgrade_xx_height: ChainEpoch, } impl TryFrom<&ChainConfig> for ForkUpgradeParams { @@ -3301,6 +3302,10 @@ impl TryFrom<&ChainConfig> for ForkUpgradeParams { upgrade_tock_height: get_height(Tock)?, upgrade_golden_week_height: get_height(GoldenWeek)?, upgrade_fire_horse_height: get_height(FireHorse)?, + upgrade_xx_height: match config.network { + NetworkChain::Mainnet => 9_999_999_999, + _ => 999_999_999_999_999, + }, }) } } diff --git a/src/rpc/snapshots/forest__rpc__tests__rpc__v0.snap b/src/rpc/snapshots/forest__rpc__tests__rpc__v0.snap index bc160d5af550..00a290c57bff 100644 --- a/src/rpc/snapshots/forest__rpc__tests__rpc__v0.snap +++ b/src/rpc/snapshots/forest__rpc__tests__rpc__v0.snap @@ -6491,6 +6491,9 @@ components: UpgradeWatermelonHeight: type: integer format: int64 + UpgradeXxHeight: + type: integer + format: int64 required: - UpgradeSmokeHeight - UpgradeBreezeHeight @@ -6525,6 +6528,7 @@ components: - UpgradeTockHeight - UpgradeGoldenWeekHeight - UpgradeFireHorseHeight + - UpgradeXxHeight GasTrace: type: object properties: diff --git a/src/rpc/snapshots/forest__rpc__tests__rpc__v1.snap b/src/rpc/snapshots/forest__rpc__tests__rpc__v1.snap index f597aa227c69..416a71b8ff33 100644 --- a/src/rpc/snapshots/forest__rpc__tests__rpc__v1.snap +++ b/src/rpc/snapshots/forest__rpc__tests__rpc__v1.snap @@ -6610,6 +6610,9 @@ components: UpgradeWatermelonHeight: type: integer format: int64 + UpgradeXxHeight: + type: integer + format: int64 required: - UpgradeSmokeHeight - UpgradeBreezeHeight @@ -6644,6 +6647,7 @@ components: - UpgradeTockHeight - UpgradeGoldenWeekHeight - UpgradeFireHorseHeight + - UpgradeXxHeight GasTrace: type: object properties: From 58868d3e3b132d751baf5eb08fb49c0025b065c2 Mon Sep 17 00:00:00 2001 From: Shashank Date: Thu, 18 Jun 2026 20:56:28 +0530 Subject: [PATCH 2/4] docs: add CHANGELOG entry for StateGetNetworkParams fix --- CHANGELOG.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 55370e364cb5..11e404d8e748 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,6 +39,8 @@ ### Fixed +- [#7194](https://github.com/ChainSafe/forest/pull/7194): Added missing `UpgradeXxHeight` fork-upgrade parameter to `Filecoin.StateGetNetworkParams` for Lotus v1.36.1 parity. + - [#7129](https://github.com/ChainSafe/forest/pull/7129): Fixed a few inaccurate cache size metrics. - [#6974](https://github.com/ChainSafe/forest/issues/6974): Fixed the message pool reporting a still-pending nonce as the next nonce after an applied message was removed. From ee96e0daff8d626455f59ed153f8fa601533b275 Mon Sep 17 00:00:00 2001 From: Shashank Date: Thu, 18 Jun 2026 20:58:50 +0530 Subject: [PATCH 3/4] update changelog --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 11e404d8e748..2751fa3137b2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -39,7 +39,7 @@ ### Fixed -- [#7194](https://github.com/ChainSafe/forest/pull/7194): Added missing `UpgradeXxHeight` fork-upgrade parameter to `Filecoin.StateGetNetworkParams` for Lotus v1.36.1 parity. +- [#7194](https://github.com/ChainSafe/forest/pull/7194): Added `UpgradeXxHeight` placeholder for the NV29 network upgrade. - [#7129](https://github.com/ChainSafe/forest/pull/7129): Fixed a few inaccurate cache size metrics. From d5d056c5c5fc6ac8414819f4dba4268712c07cb4 Mon Sep 17 00:00:00 2001 From: Shashank Date: Fri, 19 Jun 2026 23:08:31 +0530 Subject: [PATCH 4/4] update testsnapshot --- src/tool/subcommands/api_cmd/test_snapshots.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tool/subcommands/api_cmd/test_snapshots.txt b/src/tool/subcommands/api_cmd/test_snapshots.txt index c7e08f24d967..310ed20b0bc7 100644 --- a/src/tool/subcommands/api_cmd/test_snapshots.txt +++ b/src/tool/subcommands/api_cmd/test_snapshots.txt @@ -278,7 +278,7 @@ filecoin_stategetbeaconentry_1737546933208724.rpcsnap.json.zst filecoin_stategetclaim_1737546933208940.rpcsnap.json.zst filecoin_stategetclaims_1737546933208977.rpcsnap.json.zst filecoin_stategetid_1764943126105310.rpcsnap.json.zst -filecoin_stategetnetworkparams_1777517671344321.rpcsnap.json.zst +filecoin_stategetnetworkparams_1781890385127277.rpcsnap.json.zst filecoin_stategetrandomnessdigestfrombeacon_1737546933236534.rpcsnap.json.zst filecoin_stategetrandomnessdigestfromtickets_1737546933236558.rpcsnap.json.zst filecoin_stategetrandomnessfrombeacon_1737546933236581.rpcsnap.json.zst