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

eth_call errors out when transaction.to is set to null #2334

Open
quiet-node opened this issue Apr 12, 2024 · 1 comment
Open

eth_call errors out when transaction.to is set to null #2334

quiet-node opened this issue Apr 12, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@quiet-node
Copy link
Collaborator

Description

Currently, eth_call will reject requests that have transaction.to set to null. However, it should accept nullable transaction.to in the cases of contract deployment.

Steps to reproduce

  1. Run below cURL request
curl --location 'https://testnet.hashio.io/api' \
--header 'Content-Type: application/json' \
--data '{
    "id": "test_id",
    "jsonrpc": "2.0",
    "method": "eth_call",
        "params": [{
            "from":"0x05fba803be258049a27b820088bab1cad2058871", 
            "to": null,
            "data":"0x60806040"}, "latest"]
}'
  1. Observe the response to see the error like below
{"error":{"code":-32602,"name":"Invalid parameter","message":"[Request ID: b2a2c4cf-1ce4-4a56-bbc3-c25e51c51c53] Invalid parameter 'to' for TransactionObject: Expected 0x prefixed string representing the address (20 bytes), value: null"},"jsonrpc":"2.0","id":"test_id"}

Additional context

No response

Hedera network

mainnet, testnet, previewnet, other

Version

latest

Operating system

None

@quiet-node quiet-node added the bug Something isn't working label Apr 12, 2024
@quiet-node quiet-node self-assigned this Apr 12, 2024
@quiet-node
Copy link
Collaborator Author

Blocking by hashgraph/hedera-mirror-node#8072

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: Backlog
Development

No branches or pull requests

1 participant