Patchwork [2,of,4] devel: officially deprecate update without destination

login
register
mail settings
Submitter Pierre-Yves David
Date May 8, 2016, 9:35 p.m.
Message ID <cbb9caf8a54e5e6a6e9f.1462743325@nodosa.octopoid.net>
Download mbox | patch
Permalink /patch/14972/
State Superseded
Commit 899879becd655139a06b67849064edd5d8680f38
Headers show

Comments

Pierre-Yves David - May 8, 2016, 9:35 p.m.
# HG changeset patch
# User Pierre-Yves David <pierre-yves.david@ens-lyon.org>
# Date 1462469029 -7200
#      Thu May 05 19:23:49 2016 +0200
# Node ID cbb9caf8a54e5e6a6e9fe4b0e5f8f852d349d740
# Parent  70e701b45e36638fceffbb68d334b4f2478ecb76
# EXP-Topic deprecate
devel: officially deprecate update without destination

When we introduce the develwarning, we did not had an official deprecation API
and infrastructure. We can now officially deprecate the old way with a version
deadline.

Patch

diff -r 70e701b45e36 -r cbb9caf8a54e mercurial/merge.py
--- a/mercurial/merge.py	Thu May 05 19:23:30 2016 +0200
+++ b/mercurial/merge.py	Thu May 05 19:23:49 2016 +0200
@@ -1442,7 +1442,7 @@  def update(repo, node, branchmerge, forc
             pas = [repo[ancestor]]
 
         if node is None:
-            repo.ui.develwarn('update with no target', 'oldapi')
+            repo.ui.deprecwarn('update with no target', '3.9')
             rev, _mark, _act = destutil.destupdate(repo)
             node = repo[rev].node()