diff --git a/CHANGELOG.md b/CHANGELOG.md index fbb11ae71819..6fe51908a8e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -29,6 +29,8 @@ ### Added +- [#6513](https://github.com/ChainSafe/forest/pull/6513): Enabled `Filecoin.EthNewFilter` for API v2. + ### Changed ### Removed diff --git a/src/rpc/methods/eth.rs b/src/rpc/methods/eth.rs index 46e9a588afc3..81cf86595bba 100644 --- a/src/rpc/methods/eth.rs +++ b/src/rpc/methods/eth.rs @@ -3132,7 +3132,7 @@ impl RpcMethod<1> for EthNewFilter { const NAME: &'static str = "Filecoin.EthNewFilter"; const NAME_ALIAS: Option<&'static str> = Some("eth_newFilter"); const PARAM_NAMES: [&'static str; 1] = ["filterSpec"]; - const API_PATHS: BitFlags = ApiPaths::all(); + const API_PATHS: BitFlags = ApiPaths::all_with_v2(); const PERMISSION: Permission = Permission::Read; type Params = (EthFilterSpec,); diff --git a/src/rpc/snapshots/forest__rpc__tests__rpc__v2.snap b/src/rpc/snapshots/forest__rpc__tests__rpc__v2.snap index a8e6c4af8726..38a798b8d842 100644 --- a/src/rpc/snapshots/forest__rpc__tests__rpc__v2.snap +++ b/src/rpc/snapshots/forest__rpc__tests__rpc__v2.snap @@ -950,6 +950,30 @@ methods: - $ref: "#/components/schemas/EthTxReceipt" - type: "null" paramStructure: by-position + - name: Filecoin.EthNewFilter + params: + - name: filterSpec + required: true + schema: + $ref: "#/components/schemas/EthFilterSpec" + result: + name: Filecoin.EthNewFilter.Result + required: true + schema: + $ref: "#/components/schemas/FilterID" + paramStructure: by-position + - name: eth_newFilter + params: + - name: filterSpec + required: true + schema: + $ref: "#/components/schemas/EthFilterSpec" + result: + name: eth_newFilter.Result + required: true + schema: + $ref: "#/components/schemas/FilterID" + paramStructure: by-position - name: Filecoin.EthNewPendingTransactionFilter params: [] result: