Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skaled ignore params field for eth_blockNumber method #1198

Closed
gannakulikova opened this issue Oct 31, 2022 · 4 comments · Fixed by #1677
Closed

Skaled ignore params field for eth_blockNumber method #1198

gannakulikova opened this issue Oct 31, 2022 · 4 comments · Fixed by #1677
Assignees
Labels
bug Something isn't working epic:eth-compatibility
Milestone

Comments

@gannakulikova
Copy link
Contributor

Versions
Skaled: schain:3.14.15-stable.2

Environment
20 active nodes on the network
2 schains up and running

Steps to Reproduce/Description

  1. send eth_blockNumber request with params to skaled
  2. check response

Expected behavior
skaled should return an error
""error":{"code":-32602,"message":"too many arguments, want at most 0"}"

Actual result
skaled return the latest block number without any errors
{"id":1,"jsonrpc":"2.0","result":"0xcbce7"}

example request

curl http://sample-endpoint-name.network.quiknode.pro/token-goes-here/ \
  -X POST \
  -H "Content-Type: application/json" \
  --data '{"method":"eth_blockNumber","params":["0x40ee315dbee7c25d0ca4265d75b545cc87529edc5590bc2324eef0a706ab9c14"],"id":1,"jsonrpc":"2.0"}'
@DmytroNazarenko DmytroNazarenko added enhancement New feature or request bug Something isn't working and removed enhancement New feature or request labels Apr 3, 2023
@DmytroNazarenko DmytroNazarenko added this to the SKALE 2.3 milestone Aug 9, 2023
@PolinaKiporenko PolinaKiporenko moved this from To Do to Ready For Pickup in SKALE Engineering 🚀 Sep 8, 2023
@olehnikolaiev olehnikolaiev moved this from Ready For Pickup to In Progress in SKALE Engineering 🚀 Sep 26, 2023
@olehnikolaiev
Copy link
Contributor

fixed

oleh@oleh-ThinkPad-E15:~$ curl -X POST --data '{"method":"eth_blockNumber","params":["stringValueInsteadOfBlockNuber"],"id":1,"jsonrpc":"2.0"}' http://localhost:1234
{"error":{"code":-32602,"data":null,"message":"INVALID_PARAMS: Invalid method parameters (invalid name and/or type) recognised"},"id":1,"jsonrpc":"2.0"}oleh@oleh-ThinkPad-E15:~$ 
oleh@oleh-ThinkPad-E15:~$ 
oleh@oleh-ThinkPad-E15:~$ 
oleh@oleh-ThinkPad-E15:~$ curl -X POST --data '{"method":"eth_blockNumber","params":[],"id":1,"jsonrpc":"2.0"}' http://localhost:1234
{"id":1,"jsonrpc":"2.0","result":"0x3f"}

@olehnikolaiev olehnikolaiev moved this from In Progress to Code Review in SKALE Engineering 🚀 Sep 28, 2023
@olehnikolaiev olehnikolaiev moved this from Code Review to Ready For Release Candidate in SKALE Engineering 🚀 Sep 29, 2023
@DmytroNazarenko
Copy link
Collaborator

Verified on devnet: 3.18.0-develop.9

Response:

{"error":{"code":-32602,"data":null,"message":"INVALID_PARAMS: Invalid method parameters (invalid name and/or type) recognised"},"id":1,"jsonrpc":"2.0"}

@DmytroNazarenko
Copy link
Collaborator

skaled: 3.18.0-beta.0

@DmytroNazarenko DmytroNazarenko moved this from Ready For Release Candidate to Merged To Release Candidate in SKALE Engineering 🚀 Jan 23, 2024
@EvgeniyZZ EvgeniyZZ moved this from Merged To Release Candidate to QA in SKALE Engineering 🚀 Jan 23, 2024
@oleksandrSydorenkoJ
Copy link

Verified on Regresson network
Skale chain: aged-wry-finished-skale
Version: skaled: 3.18.0-beta.0

            "jsonrpc": "2.0",
            "method": "eth_blockNumber",
            "params": [
                "0x40ee315dbee7c25d0ca4265d75b545cc87529edc5590bc2324eef0a706ab9c14"
            ],
{"error":{"code":-32602,"data":null,"message":"INVALID_PARAMS: Invalid method parameters (invalid name and/or type) recognised"},"id":1,"jsonrpc":"2.0"}

@EvgeniyZZ EvgeniyZZ moved this from QA to Done in SKALE Engineering 🚀 Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working epic:eth-compatibility
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

6 participants