Three days after I undelegatebw, why can't tokens be redeemed automatically? I also need to make a manual refund action
after the 3 days of undelegatebw,I needn't explicitly push refund action,Token is automatically sent to my account.How do I want this scenario to be implemented
you can send an deferred_transaction in you contract.
eosio::transaction out;
out.actions.emplace_back( permission_level{ account, N(active) }, _self, N(action_name)
, std::make_tuple(arg1,arg2) );
out.delay_sec = delay_sec;
out.send(sender_id, _self, false);
you can send an deferred_transaction in you contract.
eosio::transaction out; out.actions.emplace_back( permission_level{ account, N(active) }, _self, N(action_name) , std::make_tuple(arg1,arg2) ); out.delay_sec = delay_sec; out.send(sender_id, _self, false);
I tried it and it still doesn't work.why?
Can you post your code?
Can you post your code?
I use the latest eos code,You can have a look
Maybe lack of resources,so that refund action exec failed. deferred_transaction(refund exec after three days ) consume cpu and net when it was exec, so you should ensure adequate resources.
I can make sure that I have enough resources, and I can do the manual refund action
Is it all the hand-operated refund action?
Did you do another undelegatebw in the middle?
The automatically generated deferred transaction generated by an undelegatebw instruction frequently fails on mainnet. It could be that it would be more reliable with a longer expiration time, but this would require all mainnet producers to vote in a new system contract. Unless and until that happens, use the manual refund workaround.