BitShares Forum

Main => Technical Support => Topic started by: monsterer on October 24, 2015, 12:19:34 pm

Title: [cli_wallet] reserve_asset throws unexpected exception
Post by: monsterer on October 24, 2015, 12:19:34 pm
Code: [Select]
reserve_asset monsterer 0.1 METAFEES true
throw exception:

Code: [Select]
0 exception: unspecified
10 assert_exception: Assert Exception
fc::to_uint64( s.substr( 0, first_dot ) ) == SpaceID && fc::to_uint64( s.substr( first_dot+1, second_dot-first_dot-1 ) ) == TypeID: Space.Type.0 (1.3.0) doesn't match expected value 0.1
Title: Re: [cli_wallet] reserve_asset throws unexpected exception
Post by: roadscape on October 24, 2015, 05:03:15 pm
It appears either the API or documentation have it mixed up..

Flip the asset and amount, and it works:
reserve_asset monsterer METAFEES 0.1 true

@xeroc any insight into this?
http://docs.bitshares.eu/namespaces/wallet.html
reserve_asset(string from, string amount, string symbol, bool broadcast)
Title: Re: [cli_wallet] reserve_asset throws unexpected exception
Post by: monsterer on October 24, 2015, 05:14:36 pm
It appears either the API or documentation have it mixed up..

Flip the asset and amount, and it works:
reserve_asset monsterer METAFEES 0.1 true

@xeroc any insight into this?
http://docs.bitshares.eu/namespaces/wallet.html
reserve_asset(string from, string amount, string symbol, bool broadcast)

Hmmm, strange!

Calling this doesn't actually reduce monsterer's balance of METAFEES, it just results in the following:

Quote
Funded asset fee pool with 0.01 METAFEES

edit: indeed - the units parameter appears to out by a factor of 10, and all this does is fund the fee pool without reducing the balance... That seems like a bug?

especially as the fee_pool is now bigger than the current_supply:

Code: [Select]
get_object 2.3.472
[{
    "id": "2.3.472",
    "current_supply": 100000,
    "confidential_supply": 0,
    "accumulated_fees": 0,
    "fee_pool": 120000
  }
]