Add assertion in bitcoin-wallet