if you have enabled delegate production on your wallet you must first disable it before rescaning...
wallet_delegate_set_block production ALL false
wallet_close
wallet_open <your wallet name>
wallet_rescan_blockchain
wallet_close
wallet_open <your wallet name>
wallet_unlock 9999999
wallet_delegate_set_block production ALL true (you can type the command even if the cli is counting blocks and you can't see what you are typing)
get_info
maybe some steps are not necessary but it works for me....