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

Remove required logIndex and transactionIndex for light client support #1270

Merged
merged 2 commits into from
May 28, 2019

Conversation

jleeh
Copy link
Contributor

@jleeh jleeh commented May 28, 2019

Example transaction receipt from light clients for a fulfillment tx:

{
    "jsonrpc": "2.0",
    "result": {
        "blockHash": "0x6c0deace15b5fed0fc3c66d2e1089bbe523960a01a258c5c97bb31c0baad15e7",
        "blockNumber": "0x56c820",
        "contractAddress": null,
        "cumulativeGasUsed": "0x10a30",
        "from": null,
        "gasUsed": null,
        "logs": [
            {
                "address": "0xec8ea88b10717ad268e30bbbf3f3659c44d49256",
                "blockHash": null,
                "blockNumber": null,
                "data": "0x",
                "logIndex": null,
                "removed": false,
                "topics": [
                    "0x7cc135e0cebb02c3480ae5d74d377283180a2601f8f644edf7987b009316c63a",
                    "0x177deec7b77150208732595dafba8fb087c07f87bf2ee095a8566cdf87831afe"
                ],
                "transactionHash": null,
                "transactionIndex": null,
                "transactionLogIndex": null,
                "type": "pending"
            },
            {
                "address": "0xec8ea88b10717ad268e30bbbf3f3659c44d49256",
                "blockHash": null,
                "blockNumber": null,
                "data": "0x",
                "logIndex": null,
                "removed": false,
                "topics": [
                    "0x794eb9e29f6750ede99e05248d997a9ab9fa23c4a7eaff8afa729080eb7c6428",
                    "0x177deec7b77150208732595dafba8fb087c07f87bf2ee095a8566cdf87831afe",
                    "0x0000000000000000000000000000000000000000000000000000000000006941"
                ],
                "transactionHash": null,
                "transactionIndex": null,
                "transactionLogIndex": null,
                "type": "pending"
            }
        ],
        "logsBloom": "0x00000000000000000000020000000000000000000000000000000000000000000000100000000000000000000000000000800000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000000000000000000000000100000000000000000000000800000000000000000000100000000000000040000000000000000000000000000000000000000000000000000004000000000000000000102008000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000000",
        "root": null,
        "status": "0x1",
        "to": null,
        "transactionHash": "0x2f6dafc0e47bfbf98a9d402e901e7b1d13ba04abe0411a5073b6f7aef379873d",
        "transactionIndex": "0x1"
    },
    "id": 1
}

On finding usages for transactionIndex and logIndex in models.Eth, the only use was it being printed in the logger in debug mode:
https://github.com/smartcontractkit/chainlink/blob/master/core/services/subscription.go#L109

@jleeh jleeh requested review from j16r and dimroc May 28, 2019 13:27
thodges-gh
thodges-gh previously approved these changes May 28, 2019
@jleeh
Copy link
Contributor Author

jleeh commented May 28, 2019

Closing this as it's a Parity bug rather than a deviation in response from light clients:
openethereum/parity-ethereum#10697

@jleeh jleeh closed this May 28, 2019
@jleeh
Copy link
Contributor Author

jleeh commented May 28, 2019

Re-opened this to workaround the issue before the parity bug is fixed.

@jleeh jleeh reopened this May 28, 2019
@jleeh jleeh merged commit e850866 into master May 28, 2019
@se3000 se3000 deleted the bug/light-clients branch September 11, 2019 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants