Make output of gettxout RPC more consistent #2149

Merged
merged 1 commit into from Jan 18, 2013

Conversation

Projects
None yet
5 participants
Owner

sipa commented Jan 4, 2013

  • Report "value" in BTC, rather than "amount" in satoshis
  • Use ScriptPubKeyToJSON to report script data
@sipa sipa Make output of gettxout RPC more consistent
* Report "value" in BTC, rather than "amount" in satoshis
* Use ScriptPubKeyToJSON to report script data
4e68391

Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/4e68391a7f3b3361584af032bf671bd9dc0677fe for binaries and test log.

Member

luke-jr commented Jan 4, 2013

This is changing things in the wrong direction. BTC values should be changed to amounts.

Member

gmaxwell commented Jan 4, 2013

The non-integers in the API needing special json handling does stink— wittness my complaints about the python module's inconsistent use of decimal... but that no reason to make the API inconsistent.

Owner

sipa commented Jan 4, 2013

I am all for using satoshis expressed as an integer, or amounts encoded as strings in the RPC interface. But consistency is more important.

I hope we can one day do a nice "RPC v2" with consistent names, nicely separated calls for net/wallet/blockchain, with support for multiwallet and authentication, and amounts that don't rely on floats, though.

Contributor

gavinandresen commented Jan 14, 2013

ACK

gavinandresen merged commit 2c78473 into bitcoin:master Jan 18, 2013

sipa deleted the sipa:fixtxoutrpc branch May 3, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment