It looks like this is the problem, in bzrlib/switch.py.
In the function _check_pending_merges:
try:
tree = control.open_workingtree()
except errors.NotBranchError, ex:
# Lightweight checkout and branch is no longer there
if force:
return
else:
raise ex
It always attempts to open the working tree to check for pending merges. If it finds the branch has disappeared and this is a lightweight checkout, it either raises an exception or if --force is used, just ignores it.
The problem is that if the working tree is remote and the server is no longer there/whatever, it fails at the connecting stage. ie with:
"ERROR: Unable to connect to SSH host XXX.XXX.XXX.XXX"
It looks like this is the problem, in bzrlib/switch.py.
In the function _check_ pending_ merges:
try: open_workingtre e() NotBranchError, ex:
tree = control.
except errors.
# Lightweight checkout and branch is no longer there
if force:
return
else:
raise ex
It always attempts to open the working tree to check for pending merges. If it finds the branch has disappeared and this is a lightweight checkout, it either raises an exception or if --force is used, just ignores it.
The problem is that if the working tree is remote and the server is no longer there/whatever, it fails at the connecting stage. ie with:
"ERROR: Unable to connect to SSH host XXX.XXX.XXX.XXX"