# HG changeset patch # User Pierre-Yves David # Date 1488894113 -3600 # Node ID ce3d68029ed7ad3135a45759f47ef97c8dca4a92 # Parent f9d65d24b9f9e328184eedcb5f31b2fc6807d651 compat: drop special code handling change in push/pull op API All version of Mercurial we support have the same API. diff -r f9d65d24b9f9 -r ce3d68029ed7 hgext3rd/evolve/obsexchange.py --- a/hgext3rd/evolve/obsexchange.py Tue Mar 07 14:29:43 2017 +0100 +++ b/hgext3rd/evolve/obsexchange.py Tue Mar 07 14:41:53 2017 +0100 @@ -63,11 +63,9 @@ @eh.wrapfunction(exchange, '_pushobsolete') def _pushobsolete(orig, pushop): """utility function to push obsolete markers to a remote""" - stepsdone = getattr(pushop, 'stepsdone', None) - if stepsdone is not None: - if 'obsmarkers' in stepsdone: - return - stepsdone.add('obsmarkers') + if 'obsmarkers' in pushop.stepsdone: + return + pushop.stepsdone.add('obsmarkers') if pushop.cgresult == 0: return pushop.ui.debug('try to push obsolete markers to remote\n') @@ -173,9 +171,7 @@ def _pullobsolete(orig, pullop): if not obsolete.isenabled(pullop.repo, obsolete.exchangeopt): return None - if 'obsmarkers' not in getattr(pullop, 'todosteps', ['obsmarkers']): - return None - if 'obsmarkers' in getattr(pullop, 'stepsdone', []): + if 'obsmarkers' in pullop.stepsdone: return None wirepull = pullop.remote.capable('_evoext_pullobsmarkers_0') if not wirepull: