Skip to content

Write WrapCCC tracker to db #1548

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

Merged
merged 5 commits into from
May 22, 2019
Merged

Conversation

HoOngEe
Copy link
Contributor

@HoOngEe HoOngEe commented May 20, 2019

It fixes #1547

@sgkim126
Copy link
Contributor

@HoOngEe Would you check the use case of Transaction::tracker?
Fixing this function might be better, but please make sure where the function is used.

@HoOngEe
Copy link
Contributor Author

HoOngEe commented May 21, 2019

@sgkim126 There are two use cases of Transaction::tracker. One is for pushing invoice information to block(our target usage) and the other is for calculating asset_type in devels.rs.

@HoOngEe
Copy link
Contributor Author

HoOngEe commented May 21, 2019

But in the second case, the asset_type operates only for MintAsset transactions. I think I can safely change the Transaction::tracker.

@HoOngEe HoOngEe force-pushed the fix/wrapccc-tracker branch from 9769065 to f2f6745 Compare May 21, 2019 03:22
@HoOngEe HoOngEe force-pushed the fix/wrapccc-tracker branch from f2f6745 to 76ab889 Compare May 21, 2019 03:27
The added test case succeeds on this branch but fails on current master
branch because current master doesn't store WrapCCC tracker in body_db
and invoice_db.
@HoOngEe HoOngEe force-pushed the fix/wrapccc-tracker branch from d8085d3 to 40f5c44 Compare May 21, 2019 05:51
@HoOngEe HoOngEe changed the title [WIP] Write WrapCCC tracker to db Write WrapCCC tracker to db May 21, 2019
@sgkim126 sgkim126 added the bug Something isn't working label May 22, 2019
@sgkim126 sgkim126 added the do-not-merge Do not merge (for mergify.io) label May 22, 2019
@HoOngEe
Copy link
Contributor Author

HoOngEe commented May 22, 2019

After the patch, I synchronized local node to Corgi network and got the rpc response previously didn't work.

curl http://localhost:8080 -H 'Content-Type: application/json' -d '{"jsonrpc": "2.0", "method": "chain_getTransactionByTracker", "params": ["0x033e49e6e7eeb612694eedfd2b6274c4f0d5b21ce866710c02b4fb8c62f9572b"], "id": null}'
{"jsonrpc":"2.0","result":{"action":{"lockScriptHash":"0x5f5960a7bca6ceeeb0c97bc717562914e7a1de04","parameters":["d5b0e27e1e87d9446b0a45cbe38821ccc1430380"],"payer":"wccqxxz05354l57u877989aus855y0v7wual54n86yf","quantity":"0x3e8","shardId":0,"type":"wrapCCC"},"blockHash":"0x9ae96d65e866ce760617f24a94c2febbc8f8c2c09e9ddb60081a1514f36be1e9","blockNumber":290457,"fee":"0x186a0","hash":"0x71765bbdedf9e22bcb053c41ce5a66852508ca4d0b066d0e943800c7e4719c32","networkId":"wc","result":true,"seq":8,"sig":"0x145e5005e2a4a03ba218a43be01289b8541c81f6eefa781ad024834eebcc3a0719a2a9835e4d94d233dda3e5705e53d74ee7f1518c60019272e37e0162f7a54d01","transactionIndex":1},"id":null}

@HoOngEe HoOngEe removed the do-not-merge Do not merge (for mergify.io) label May 22, 2019
@sgkim126
Copy link
Contributor

@HoOngEe Thank you for checking

@mergify mergify bot merged commit e57b851 into CodeChain-io:master May 22, 2019
@HoOngEe HoOngEe deleted the fix/wrapccc-tracker branch May 22, 2019 07:09
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
None yet
Development

Successfully merging this pull request may close these issues.

getTransactionByTracker RPC doesn't return WrapCCC transactions
2 participants