Better error reporting for datastore_delete, fix tests