check_self_contained has an optional argument head which is not used in the cli: for tezos this is a problem because they are not using the branch store, so we need to look for the current head in the store and pass it on the check_self_contained function.