Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Add from and to to eth_getTransactionReceipt #6948

Closed
mmitech opened this issue Oct 31, 2017 · 15 comments
Closed

Add from and to to eth_getTransactionReceipt #6948

mmitech opened this issue Oct 31, 2017 · 15 comments
Labels
F3-annoyance 💩 The client behaves within expectations, however this “expected behaviour” itself is at issue. M6-rpcapi 📣 RPC API. P5-sometimesoon 🌲 Issue is worth doing soon. Q2-easy 💃 Can be fixed by copy and pasting from StackOverflow. Q3-medium A fair chunk of work, not necessarily very hard but not trivial either
Milestone

Comments

@mmitech
Copy link

mmitech commented Oct 31, 2017

I'm running:

  • Parity version: 1.8.2
  • Operating system: Linux: Ubuntu 16.04
  • And installed: via binaries

I am switching from geth to parity, I wrote my APP following the docs, but for some reason getTransactionreceipt seems to be missing some fields, specifically from and to which is needed in my APP.

@5chdn 5chdn added F3-annoyance 💩 The client behaves within expectations, however this “expected behaviour” itself is at issue. M6-rpcapi 📣 RPC API. P5-sometimesoon 🌲 Issue is worth doing soon. labels Nov 1, 2017
@5chdn 5chdn added this to the 1.9 milestone Nov 1, 2017
@5chdn
Copy link
Contributor

5chdn commented Nov 1, 2017

The example on that page does not contain from and to, was this added recently?

@tomusdrw
Copy link
Collaborator

tomusdrw commented Nov 1, 2017

from and to (and all other fields) can be retrieved from the transaction itself (by hash) adding only those two fields to receipt seems a bit weird.

@5chdn 5chdn modified the milestones: 1.9, 1.10 Jan 5, 2018
@5chdn 5chdn modified the milestones: 1.10, 1.11 Jan 23, 2018
@5chdn 5chdn modified the milestones: 1.11, 1.12 Mar 1, 2018
@simon-temple
Copy link

simon-temple commented Apr 18, 2018

There is a difference between the documented response to getTransactionReceipt and the actual response:

 --> POST http://localhost:8545/ http/1.1
Content-Type: application/json; charset=utf-8
Content-Length: 141 
{
    "jsonrpc": "2.0",
    "method": "eth_getTransactionReceipt",
    "params": ["0x60a37c38327d3f3b2cace6ad89546895bf49c1fb6c70a4b23c9027967232ecb8"],
    "id": 9
}
 --> END POST (141-byte body)

<-- 200 OK http://localhost:8545/ (3ms)
Content-Type: application/json
Transfer-Encoding: chunked
Date: Wed, 11 Apr 2018 08:28:11 GMT
{
    "jsonrpc": "2.0",
    "result": {
        "blockHash": "0xcf5f0a2a90bf99aaa29516ed2a35eae2c8f72fefb997402158a566c7d5a39f4f",
        "blockNumber": "0x9d05",
        "contractAddress": null,
        "cumulativeGasUsed": "0x90a9",
        "gasUsed": "0x90a9",
        "logs": [{
            "address": "0x0a35db94da8e787b1c10bc5d9a7761d151bedeaf",
            "blockHash": "0xcf5f0a2a90bf99aaa29516ed2a35eae2c8f72fefb997402158a566c7d5a39f4f",
            "blockNumber": "0x9d05",
            "data": "0x0000000000000000000000000000000000000000000000000000000000000001",
            "logIndex": "0x0",
            "topics": ["0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef", "0x000000000000000000000000e26b50ae30945efac2b1dd8897a29c3efc1d9780", "0x0000000000000000000000006b0c56d1ad5144b4d37fa6e27dc9afd5c2435c3b"],
            "transactionHash": "0x60a37c38327d3f3b2cace6ad89546895bf49c1fb6c70a4b23c9027967232ecb8",
            "transactionIndex": "0x0",
            "transactionLogIndex": "0x0",
            "type": "mined"
        }],
        "logsBloom": "0x00000000000000000000020000000000000000000000000000100000000000000000000000000000000008000000000000000000000000000000000008000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000080000000000000000008100000000000000000000000000000000000100000000000000000000000000000",
        "root": null,
        "status": null,
        "transactionHash": "0x60a37c38327d3f3b2cace6ad89546895bf49c1fb6c70a4b23c9027967232ecb8",
        "transactionIndex": "0x0"
    },
    "id": 9
}

The documentation: https://wiki.parity.io/JSONRPC-eth-module#eth_gettransactionreceipt

I'm using Parity//v1.9.5-stable-ff821da-20180321/x86_64-linux-gnu/rustc1.24.1
and https://github.com/web3j/web3j version 3.3.0

My problem is with the lack 'status' value. The expected value would be: "either 0x1 (success) or 0x0 (failure)"

@Tbaut
Copy link
Contributor

Tbaut commented Apr 18, 2018

@simon-temple thanks for the heads up, we will update the wiki shortly (https://github.com/paritytech/wiki/pull/75). Regarding "status": null. This field is only used if Byzantium EIP658 has been enabled.
Can you add "eip658Transition": "0x0" to the params of your chain spec like here

@Tbaut
Copy link
Contributor

Tbaut commented Apr 18, 2018

Note that you should set up a hard fork in your chain and set the eip658Transition to a block number in the future. Starting from this block, you will be able to have a non-null status field, not before.

@5chdn 5chdn modified the milestones: 1.12, 1.13 Apr 24, 2018
@folsen
Copy link
Contributor

folsen commented May 19, 2018

The spec here

https://github.com/ethereum/wiki/wiki/JavaScript-API#web3ethgettransactionreceipt

Does not match what is here

https://wiki.parity.io/JSONRPC-eth-module.html#eth_gettransactionreceipt

Specifically from and to are missing. They should be added to match the spec.

@folsen folsen changed the title getTransactionreceipt doesn't return the expected values Add from and to to eth_getTransactionReceipt May 19, 2018
@folsen folsen added Q2-easy 💃 Can be fixed by copy and pasting from StackOverflow. Q3-medium A fair chunk of work, not necessarily very hard but not trivial either labels May 19, 2018
@gitcoinbot
Copy link

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


This issue now has a funding of 0.12 ETH (69.09 USD @ $575.79/ETH) attached to it.

@openethereum openethereum deleted a comment May 29, 2018
@vaibhavchellani
Copy link

is some one working on this ?

@folsen
Copy link
Contributor

folsen commented May 29, 2018

@vaibhavchellani nope, feel free to pick it

@gitcoinbot
Copy link

gitcoinbot commented May 31, 2018

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


Work has been started.

These users each claimed they can complete the work by 8 months, 2 weeks ago.
Please review their action plans below:

1) ab320012 has started work.

1.add to and from to receipt
2. assign to and from to receipt in the following map:
typehttps://github.com/paritytech/parity/blob/master/rpc/src/v1/impls/light/eth.rs#L461

Learn more on the Gitcoin Issue Details page.

@gitcoinbot
Copy link

@ab320012 Hello from Gitcoin Core - are you still working on this issue? Please submit a WIP PR or comment back within the next 3 days or you will be removed from this ticket and it will be returned to an ‘Open’ status. Please let us know if you have questions!

  • warning (3 days)
  • escalation to mods (6 days)

Funders only: Snooze warnings for 1 day | 3 days | 5 days | 10 days | 100 days

@gitcoinbot
Copy link

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


Work for 0.12 ETH (72.93 USD @ $607.75/ETH) has been submitted by:

  1. @ab320012

@vs77bb please take a look at the submitted work:


@ab320012
Copy link
Contributor

@vs77bb this is resolved

@gitcoinbot
Copy link

Issue Status: 1. Open 2. Started 3. Submitted 4. Done


The funding of 0.12 ETH (64.13 USD @ $534.44/ETH) attached to this issue has been approved & issued to @ab320012.

@andresilva
Copy link
Contributor

andresilva commented Jun 19, 2018

Fixed in #8756.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
F3-annoyance 💩 The client behaves within expectations, however this “expected behaviour” itself is at issue. M6-rpcapi 📣 RPC API. P5-sometimesoon 🌲 Issue is worth doing soon. Q2-easy 💃 Can be fixed by copy and pasting from StackOverflow. Q3-medium A fair chunk of work, not necessarily very hard but not trivial either
Projects
None yet
Development

No branches or pull requests

10 participants