Show hash on sendrawtransaction#796
Conversation
Codecov Report
@@ Coverage Diff @@
## master #796 +/- ##
==========================================
- Coverage 37.75% 37.59% -0.16%
==========================================
Files 176 176
Lines 12439 12442 +3
==========================================
- Hits 4696 4678 -18
- Misses 7743 7764 +21
Continue to review full report at Codecov.
|
| var ret = new JObject(); | ||
| ret["result"] = true; | ||
| ret["hash"] = hash.ToString(); | ||
| return ret; |
There was a problem hiding this comment.
I can't quickly tell but will this result in
{
"jsonrpc": "2.0",
"id": 1,
"result": true,
"hash": "some tx id hash"
}
or in
{
"jsonrpc": "2.0",
"id": 1,
"result": {
"result": true,
"hash": "some tx id hash"
}
}
?
There was a problem hiding this comment.
The second one, but i will change result for 'relayed'
| { | ||
| var ret = new JObject(); | ||
| ret["relayed"] = true; | ||
| ret["hash"] = hash.ToString(); |
There was a problem hiding this comment.
I think we should call this txid instead of hash to stay consistent. e.g. sendtoaddress and sendfrom also use txid
Otherwise looks good
There was a problem hiding this comment.
It's weird to return two different structures for blocks and transactions.
There was a problem hiding this comment.
Maybe we can leave blocks as before, but looks weird too
There was a problem hiding this comment.
Maybe we should use hash uniformly.
There was a problem hiding this comment.
We can change the neo-plugin to "hash"
|
Test failed. |
* Show hash on sendrawtransaction * Update RpcServer.cs * txid * relayed * Revert to hash * txid -> hash * Update RpcServer.cs * Fix test
Close #795