In getblocksysfee, fee returns full decimals. However, in getrawtransaction, fee has decimal point. I think it's necessary to make fee format be unified in RPC, otherwise, it'll make a lot of users be comfused.


Can you find all APIs that return inconsistent formats?
And which one do you prefer to return? Long or decimal?
I prefer as decimal
Can you find all APIs that return inconsistent formats?
Sure.
@erikzhang
getnep5balances--->amount(full decimals)
getnep5transfers--->amount(full decimals)
getunclaimedgas--->result(full decimals)
getapplicationlog--->value(full decimals)
getbalance--->balance(full decimals)
getblock--->net_fee,sys_fee(decimal point)
getrawtransaction--->net_fee,sys_fee(decimal point)
invokefunction, invokescript--->gas_consumed, value(full decimals)
sendfrom, sendtoaddress, sendmany--->net_fee,sys_fee(decimal point)
getblocksysfee --->result(full decimals)
cli command line: decimal point
If we choose full decimals, I think we鈥榙 better add subscript to help read value.
I prefer to return long in RPC, and return decimal in command line.
Because in RPC, the results are for programs, and long is easy for programs to process. In command line, the results are for human reading.
What do you think?
Because in RPC, the results are for programs, and long is easy for programs to process. In command line, the results are for human reading.
Couldn't agree more Erik. long is good for me too on RPC.
have sense, is good for me
getapplicationlog--->value(full decimals)
invokefunction, invokescript--->gas_consumed, value(full decimals)
What value? I didn't see it.
@superboyiii Please check the fixes.
@erikzhang OK
getapplicationlog--->value(full decimals)
invokefunction, invokescript--->gas_consumed, value(full decimals)
What
value? I didn't see it.
I mean the invocation return value. Such like this:

These are StackItems and I don't think they have any problems.
Most helpful comment
I prefer to return
longin RPC, and returndecimalin command line.Because in RPC, the results are for programs, and
longis easy for programs to process. In command line, the results are for human reading.What do you think?