sapling/mercurial
Pierre-Yves David e4e6aeb80c bookmark: informs of failure to upgrade a bookmark
When we explicitly requested to update a bookmark but the bookmark location was
missing locally, we used to silently ignore the case. We now issue a message
about it to point that something wrong is going on.

By chance, we fixed all the cases where is case happened (for explicit pulling
only, issue4700 is still open). But I think it is still valuable to have a
warning in place in case such issue is reintroduced.

This patch have been tested against issue4689 test (but without issue4689 fix).
It give the better but expected failure seen below:

> --- /home/pyd/src/mercurial-dev/tests/test-bookmarks-pushpull.t
> +++ /home/pyd/src/mercurial-dev/tests/test-bookmarks-pushpull.t.err
> @@ -337,12 +337,12 @@
>    adding manifests
>    adding file changes
>    added 1 changesets with 1 changes to 1 files
> -  updating bookmark Y
> +  remote bookmark Y point to locally missing 0d60821d2197
>    (run 'hg update' to get a working copy)
>    $ hg book
>     * @                         1:0d2164f0ce0d
>       X                         1:0d2164f0ce0d
> -     Y                         5:35d1ef0a8d1b
> +     Y                         4:b0a5eff05604
>       Z                         1:0d2164f0ce0d
>
>  Update a bookmark right after the initial lookup -r (issue4700)
> @@ -387,12 +387,11 @@
>    adding manifests
>    adding file changes
>    added 1 changesets with 1 changes to 1 files
> -  updating bookmark Y
>    (run 'hg update' to get a working copy)
>    $ hg book
>     * @                         1:0d2164f0ce0d
>       X                         1:0d2164f0ce0d
> -     Y                         6:0d60821d2197
> +     Y                         4:b0a5eff05604
>       Z                         1:0d2164f0ce0d
>    $ hg -R $TESTTMP/pull-race book
>       @                         1:0d2164f0ce0d
2015-06-11 17:19:48 -07:00
..
default.d mergetools: drop incorrect quoting of diffargs variables 2015-01-28 02:28:38 +01:00
help help: use 'color' as an example (instead of 'progress') 2015-06-11 00:26:06 -07:00
hgweb hgewb: disable progress when serving (issue4582) 2015-06-07 17:14:17 -07:00
httpclient style: kill ersatz if-else ternary operators 2015-03-13 17:00:06 -04:00
pure parsers: remove unused dependency on util 2015-04-06 13:59:36 -07:00
templates hgweb: don't point file links at tip hash where it doesn't make sense 2015-06-12 18:34:10 +08:00
__init__.py
ancestor.py util: drop alias for collections.deque 2015-05-16 11:28:04 -07:00
archival.py archive: look for first visible revision to build repo identity (issue4591) 2015-04-08 23:30:02 +09:00
base85.c base85: cast Py_ssize_t values to int (issue3481) 2012-06-04 16:59:34 +02:00
bdiff.c bdiff: avoid a memory error on malloc failure 2013-10-30 16:03:42 -05:00
bookmarks.py bookmark: informs of failure to upgrade a bookmark 2015-06-11 17:19:48 -07:00
branchmap.py revbranchcache: return uncached branchinfo for nullrev (issue4683) 2015-05-23 11:14:00 +09:00
bundle2.py bundle2: provide number of changesets information to 'addchangegroup' 2015-06-07 15:57:54 -07:00
bundlerepo.py bundlerepo: disable filtering of changelog while constructing revision text 2015-04-29 19:47:37 +09:00
byterange.py style: kill ersatz if-else ternary operators 2015-03-13 17:00:06 -04:00
changegroup.py addchangegroup: accept an expected total number of changesets as argument 2015-06-07 15:57:40 -07:00
changelog.py changelog: fix readpending if no pending data exist (issue4609) 2015-04-20 17:16:22 +02:00
cmdutil.py formatter: move most of template option helper to formatter 2015-06-10 14:29:13 -05:00
commands.py pull: avoid race condition with 'hg pull --rev name --update' (issue4706) 2015-06-03 14:29:11 -07:00
commandserver.py cmdserver: include pid of server handling requests in hello message 2014-10-18 12:24:50 +09:00
config.py config: give it an includepaths option for looking for config files 2015-05-15 09:04:32 -04:00
context.py context: add an optional constructor parameter for a match.bad() override 2015-06-05 19:01:04 -04:00
copies.py mergecopies: avoid slowdown from linkrev adjustment (issue4680) 2015-05-26 06:45:18 -05:00
crecord.py crecord: add mechanism for error reporting 2015-06-05 13:53:49 -07:00
dagparser.py dagparser: use 'next' instead of try/except for default value 2015-05-18 12:22:44 -05:00
dagutil.py style: kill ersatz if-else ternary operators 2015-03-13 17:00:06 -04:00
demandimport.py demandimport: define a deactivated context manager 2015-05-28 16:11:26 -04:00
diffhelpers.c diffhelpers: fix botched return statement from e48d70075d8a 2015-01-28 13:34:20 -05:00
dirs.c dirs._addpath: reinstate use of Py_CLEAR 2015-04-07 20:43:04 -07:00
dirstate.py dirstate: avoid invalidating every entries when list is empty 2015-06-04 22:10:32 -07:00
discovery.py discovery: don't compute allfuturecommon when it won't be used 2015-04-13 09:54:36 -04:00
dispatch.py dispatch: disable demandimport for the --debugger option 2015-05-28 16:42:21 -04:00
dummycert.pem ssl: on OS X, use a dummy cert to trick Python/OpenSSL to use system CA certs 2014-09-26 02:19:48 +02:00
encoding.py util.h: define an enum for normcase specs 2015-04-02 19:17:32 -07:00
error.py bundle2: introduce a PushkeyFail error to abort unbundle on pushkey error 2015-05-27 23:48:54 -07:00
exchange.py push: only say we are trying to push obsmarkers when we actually try 2015-06-11 13:02:21 -07:00
exewrapper.c exewrapper: adapt for legacy HackableMercurial 2012-08-07 11:04:41 +02:00
extensions.py extensions: clear aftercallbacks after execution (issue4646) 2015-05-06 09:52:10 -07:00
fancyopts.py fancyopts: allow all callable as default parameter value 2015-06-11 08:54:24 -04:00
filelog.py filelog: use censored revlog flag bit to quickly check if a node is censored 2015-01-12 15:29:36 -05:00
filemerge.py merge: better debug messages before/after invoking external merge tool 2015-03-19 22:22:50 +01:00
fileset.py fileset: pretty print syntax tree in debug output 2015-04-26 22:26:44 +09:00
formatter.py formatter: add template support 2015-06-10 14:33:38 -05:00
graphmod.py dagwalker: drop a useless intermediate variable 2014-10-08 02:43:51 -07:00
hbisect.py util: drop alias for collections.deque 2015-05-16 11:28:04 -07:00
help.py help: also hide options marked EXPERIMENTAL 2015-04-27 15:12:41 -07:00
hg.py hg: explicitly check that peer lookup object has instance() if call failed 2015-05-30 12:46:30 +09:00
hook.py hooks: replace if-try-finally with a "with" statement 2015-05-28 16:42:04 -04:00
httpconnection.py ssl: rename ssl_wrap_socket() to conform to our naming convention 2015-06-05 21:25:28 +09:00
httppeer.py httppeer: allow extensions to replace urllib2.Request 2015-06-08 16:55:21 -07:00
i18n.py i18n: cache the result of every gettext call 2014-10-17 13:52:10 -04:00
keepalive.py util: move md5 back next to sha1 and allow to call it without an argument 2014-09-24 16:00:47 +09:00
localrepo.py localrepo: pass hook argument txnid to pretxnopen hooks 2015-05-25 01:26:23 +09:00
lock.py lock: while releasing, unlink lockfile even if the release function throws 2014-10-16 19:15:51 -07:00
lsprof.py profiling: replace '+' markup of nested lines with indentation 2013-02-08 22:54:48 +01:00
lsprofcalltree.py
mail.py mail: pass ui to sslutil.wrapsocket() even if verifycert is off (issue4713) 2015-06-07 09:30:15 +09:00
manifest.c lazymanifest: prevent leak when updating an entry more than once 2015-04-11 11:56:21 -04:00
manifest.py manifest: use match.prefix() instead of 'not match.anypats()' 2015-05-19 11:16:20 -07:00
match.py match: add an optional constructor parameter for a bad() override 2015-06-05 18:56:33 -04:00
mdiff.py mdiff: add helper for making deltas which replace the full text of a revision 2015-01-21 16:35:09 -05:00
merge.py merge: run update hook after the last wlock release 2015-04-29 15:52:31 -04:00
minirst.py help: show all nested subsections of a section with hg help foo.section 2014-10-06 07:35:53 -04:00
mpatch.c mpatch: rewrite pointer overflow checks 2013-12-11 18:33:42 -06:00
namespaces.py revset: mask specific names for named() predicate 2015-02-05 14:45:49 +09:00
node.py
obsolete.py phases: add hg help phases hint to failures to edit public commits 2015-06-01 14:16:52 -04:00
osutil.c osutil: mark end of string with null char, not 0 2015-03-25 16:21:58 -07:00
parser.py parser: extract closure of prettyformat() to a top-level function 2015-05-06 10:17:41 +09:00
parsers.c parsers: simplify the code computing the phases 2015-05-27 17:01:43 -07:00
patch.py record: exiting editor with non-zero status should not stop recording session 2015-06-05 13:31:18 -07:00
pathencode.c pathencode: eliminate signed integer warnings 2014-02-19 13:11:24 -08:00
pathutil.py pathutil: demote two local functions to just be forwards 2015-05-26 14:41:00 -04:00
peer.py peer: delete double definition of method peer 2012-07-28 22:36:22 +02:00
phases.py phases: really fix native phase computation 2015-06-10 19:26:16 -07:00
posix.py util: add a simple poll utility 2015-05-20 18:00:05 -05:00
progress.py progress: move most extension code into a 'mercurial.progress' module 2015-06-07 17:19:20 -07:00
pushkey.py obsolete: add exchange option 2014-10-14 13:26:01 -07:00
pvec.py pvec: replace 'ctx._repo' with 'ctx.repo()' 2015-03-12 23:18:20 -04:00
py3kcompat.py py3kcompat: drop unused export 2014-05-13 15:22:36 -05:00
repair.py repair: use _hexlist() to build revset expression from binary nodes 2015-05-24 14:34:12 +09:00
repoview.py repoview: avoid processing the same rev twice in _getstatichidden 2015-04-03 14:41:18 -07:00
revlog.py revlog: move size limit check to addrevision 2015-06-04 14:57:58 -05:00
revset.py revset: mark spots that use 'set' instead of 'smartset' 2015-06-11 15:45:02 -07:00
scmposix.py config: don't read the same config file twice 2014-09-04 21:36:35 +02:00
scmutil.py scmutil: add an optional parameter to matcher factories for a bad() override 2015-06-05 19:24:32 -04:00
scmwindows.py config: don't read the same config file twice 2014-09-04 21:36:35 +02:00
setdiscovery.py cleanup: use __builtins__.all instead of util.all 2015-05-16 14:34:19 -04:00
similar.py cleanup: eradicate long lines 2012-05-12 15:54:54 +02:00
simplemerge.py simplemerge: remove dead code 2014-08-07 12:51:45 -04:00
sshpeer.py sshpeer: allow doublepipe on unbuffered main pipe 2015-06-05 04:54:23 -07:00
sshserver.py changegroup: rename bundle-related functions and classes 2014-09-02 12:11:36 +02:00
sslutil.py ssl: remove CERT_REQUIRED constant that was necessary for compatibility 2015-06-05 21:45:44 +09:00
statichttprepo.py statichttprepo: remove wrong getattr ladder 2015-05-18 22:40:16 -04:00
store.py store: add comment in _hashencode with reason for skipping the first 5 chars 2015-05-13 20:36:56 +02:00
strutil.py
subrepo.py subrepo: introduce the nullsubrepo() method 2015-06-03 13:45:42 -04:00
tagmerge.py filemerge: add internal:tagmerge merge tool 2014-06-26 01:20:25 +02:00
tags.py tags: support setting hgtags fnodes cache entries 2015-05-25 16:48:55 -07:00
templatefilters.py templatefilters: add "upper" and "lower" for case conversion 2015-03-30 23:54:29 +09:00
templatekw.py templatekw: compare target context and its parent exactly (issue4690) 2015-06-02 02:28:33 +09:00
templater.py templater: make pad function evaluate both string and rawstring templates 2015-06-08 18:48:45 +09:00
transaction.py transaction: really fix _addbackupentry key usage (issue4684) 2015-05-26 13:02:28 -07:00
treediscovery.py util: drop alias for collections.deque 2015-05-16 11:28:04 -07:00
ui.py progress: display progress bars by default with core Mercurial 2015-06-07 17:51:27 -07:00
unionrepo.py unionrepo: use pathutil.normasprefix to ensure os.sep at the end of cwd 2015-04-22 23:38:55 +09:00
url.py ssl: rename ssl_wrap_socket() to conform to our naming convention 2015-06-05 21:25:28 +09:00
util.h util: fix the check for non-C99 compilers (issue4605) 2015-04-20 22:21:57 -05:00
util.py util: add a simple poll utility 2015-05-20 18:00:05 -05:00
verify.py verify: add a note about a paleo-bug 2015-03-27 15:13:21 -05:00
win32.py win32: 'raise ctypes.WinError' -> 'raise ctypes.WinError()' 2015-03-22 19:08:13 -04:00
windows.py windows: use os.SEEK_END 2015-06-06 14:03:55 +02:00
wireproto.py bundle2: convey PushkeyFailed error over the wire 2015-06-10 13:10:53 -04:00
worker.py cleanup: avoid _ for local unused tmp variables - that is reserved for i18n 2014-08-15 16:20:47 +02:00