4441
Technical Support / Re: Exception cancelling market orders
« on: January 07, 2015, 01:08:33 pm »
Let's replay..
1. open a wallet console (v0.4.27.1),
1.1 type a command 'wallet_account_create [sub.account]'
1.2 type command 'register [sub.account] [account]'
1.3 type 'wallet_dump_private_key [sub.account]', will get a private key
2. transfer some BTS and CNY to the new sub-account
3. on another computer, open a wallet console (v0.4.27.2),
3.1 type 'create_wallet [wallet_name]'
3.2 type 'wallet_import_private_key [the_private_key]'
3.3 type 'wallet_market_submit_bid aaa xxx bbb yyy', created a bid order
3.4 type 'wallet_market_order_list xxx yyy', can see the order created, with an order id
3.5 type 'wallet_market_cancel_order [order_id]', Exception raised.
It's interesting that the owner key and active key of that sub-account are different. Perhaps it makes sense?
The result of command 'wallet_dump_private_key [account_name]' is the private key of the active key, but not the owner key.
So I guess active key is needed for submit an order, but owner key is needed for cancelling an order? Will import the other key and make some tests.
UPDATE:
After imported the private key of owner key of the sub-account in the new client, I was able to cancel the market orders successfully.
So here comes a question: is it a new feature or a bug?
1. open a wallet console (v0.4.27.1),
1.1 type a command 'wallet_account_create [sub.account]'
1.2 type command 'register [sub.account] [account]'
1.3 type 'wallet_dump_private_key [sub.account]', will get a private key
2. transfer some BTS and CNY to the new sub-account
3. on another computer, open a wallet console (v0.4.27.2),
3.1 type 'create_wallet [wallet_name]'
3.2 type 'wallet_import_private_key [the_private_key]'
3.3 type 'wallet_market_submit_bid aaa xxx bbb yyy', created a bid order
3.4 type 'wallet_market_order_list xxx yyy', can see the order created, with an order id
3.5 type 'wallet_market_cancel_order [order_id]', Exception raised.
It's interesting that the owner key and active key of that sub-account are different. Perhaps it makes sense?
The result of command 'wallet_dump_private_key [account_name]' is the private key of the active key, but not the owner key.
So I guess active key is needed for submit an order, but owner key is needed for cancelling an order? Will import the other key and make some tests.
UPDATE:
After imported the private key of owner key of the sub-account in the new client, I was able to cancel the market orders successfully.
So here comes a question: is it a new feature or a bug?