diff --git a/hgext3rd/pushrebase.py b/hgext3rd/pushrebase.py --- a/hgext3rd/pushrebase.py +++ b/hgext3rd/pushrebase.py @@ -109,6 +109,11 @@ partorder.insert(0, partorder.pop(partorder.index(commonheadsparttype))) + if 'check-bookmarks' in partorder: + # check-bookmarks is intended for non-pushrebase scenarios when + # we can't push to a bookmark if it's changed in the meantime + partorder.pop(partorder.index('check-bookmarks')) + wrapfunction(discovery, 'checkheads', _checkheads) # we want to disable the heads check because in pushrebase repos, we # expect the heads to change during the push and we should not abort. @@ -137,6 +142,10 @@ wrapfunction(hg, '_peerorrepo', _peerorrepo) + def noop(*args, **kwargs): + pass + wrapfunction(exchange, '_pushb2checkbookmarks', noop) + def reposetup(ui, repo): if repo.ui.configbool('pushrebase', 'blocknonpushrebase'): repo.ui.setconfig('hooks', 'prechangegroup.blocknonpushrebase',