# HG changeset patch # User Matt Mackall # Date 1325286276 21600 # Node ID 742c766c8cea2c1407882e38c1faba9abea641e0 # Parent e251250ac20bdb07e2d95f39e86134b252c4aa92# Parent 03d04296cfab3633eee6663d82baaf541d43d011 merge with stable diff -r e251250ac20b -r 742c766c8cea hgext/convert/subversion.py --- a/hgext/convert/subversion.py Thu Dec 29 14:45:18 2011 -0600 +++ b/hgext/convert/subversion.py Fri Dec 30 17:04:36 2011 -0600 @@ -106,11 +106,11 @@ discover_changed_paths, strict_node_history, receiver) - except SubversionException, (inst, num): - pickle.dump(num, fp, protocol) except IOError: # Caller may interrupt the iteration pickle.dump(None, fp, protocol) + except Exception, inst: + pickle.dump(str(inst), fp, protocol) else: pickle.dump(None, fp, protocol) fp.close() @@ -145,7 +145,7 @@ except: if entry is None: break - raise SubversionException("child raised exception", entry) + raise util.Abort(_("log stream exception '%s'") % entry) yield entry def close(self): diff -r e251250ac20b -r 742c766c8cea hgext/fetch.py --- a/hgext/fetch.py Thu Dec 29 14:45:18 2011 -0600 +++ b/hgext/fetch.py Fri Dec 30 17:04:36 2011 -0600 @@ -83,7 +83,7 @@ # Is this a simple fast-forward along the current branch? newheads = repo.branchheads(branch) newchildren = repo.changelog.nodesbetween([parent], newheads)[2] - if len(newheads) == 1: + if len(newheads) == 1 and len(newchildren): if newchildren[0] != parent: return hg.clean(repo, newchildren[0]) else: @@ -102,6 +102,9 @@ (len(newheads) - 1)) return 1 + if not newheads: + return 0 + # Otherwise, let's merge. err = False if newheads: