tests/test-obsolete-distributed.t
author Valentin Gatien-Baron <valentin.gatienbaron@gmail.com>
Tue, 02 Jul 2019 12:59:58 -0400
changeset 42621 99ebde4fec99
parent 42130 a362b0b95e42
child 42893 34a46d48d24e
permissions -rw-r--r--
commit: improve the files field of changelog for merges Currently, the files list of merge commits repeats all the deletions (either actual deletions, or files that got renamed) that happened between base and p2 of the merge. If p2 is the main branch, the list can easily be much bigger than the change being merged. This results in various problems worth improving: - changelog is bigger than necessary - `hg log directory` lists many unrelated merge commits, and `hg log -v -r commit` frequently fills multiple screens worth of files - it possibly slows down adjustlinkrev, by forcing it to read more manifests, and that function can certainly be a bottleneck - the server side of pulls can waste a lot of time simply opening the filelogs for pointless files (the constant factors for opening even a tiny filelog is apparently pretty bad) So stop listing such files as described in the code. Impacted merge commits and their descendants get a different hash than they would have without this. This doesn't seem problematic, except for convert. The previous commit helped with that in the hg->hg case (but if you do svn->hg twice from scratch, hashes can still change). The rest of the description is numbers. I don't have much to report, because recreating the files list of existing repositories is not easy: - debugupgradeformat and bundle/unbundle don't recreate the list - export/import tends to choke quickly applying patches or on description that contain diffs, - merge commits from the convert extension don't have the right files list for reasons orthogonal to the current commit - replaying the merge with hg update/hg merge/hg revert --all/hg commit can end up failing in hg revert - I wasn't sure that using debugsetparents + debugrebuilddirstate would really build the right thing I measured commit time before and after this change, in a case with no files filtered out, several files filtered out (no difference) and 5k files filtered out (+1% time). Recreating the 100 more recent merges in a private repo, the concatenated uncompressed files lists goes from 1.12MB to 0.52MB. Excluding 3 merges that are not representative, then the size goes from 570k to 15k. I converted part of mozilla-central, and observed file list shrinking quite a bit too, starting at the very first merge, 733641d9feaf, going from 550 files to 10 files (although they have relatively few merges, so they probably wouldn't care). Differential Revision: https://phab.mercurial-scm.org/D6613
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     1
=============================
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     2
Test distributed obsolescence
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     3
=============================
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     4
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     5
This file test various cases where data (changeset, phase, obsmarkers) is
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     6
added to the repository in a specific order. Usually, this order is unlikely
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     7
to happen in the local case but can easily happen in the distributed case.
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     8
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
     9
  $ unset HGUSER
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    10
  $ unset EMAIL
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    11
  $ . $TESTDIR/testlib/obsmarker-common.sh
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    12
  $ cat >> $HGRCPATH << EOF
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
    13
  > [extensions]
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
    14
  > rebase =
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    15
  > [experimental]
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    16
  > evolution = all
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    17
  > [phases]
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    18
  > publish = False
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    19
  > [ui]
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
    20
  > logtemplate= {rev}:{node|short} {desc}{if(obsfate, " [{join(obsfate, "; ")}]")}\n
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    21
  > EOF
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    22
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    23
Check distributed chain building
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    24
================================
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    25
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    26
Test case where a changeset is marked as a successor of another local
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    27
changeset while the successor has already been obsoleted remotely.
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    28
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    29
The chain of evolution should seamlessly connect and all but the new version
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    30
(created remotely) should be seen as obsolete.
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    31
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    32
Initial setup
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    33
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    34
  $ mkdir distributed-chain-building
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    35
  $ cd distributed-chain-building
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    36
  $ hg init server
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    37
  $ cd server
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    38
  $ cat << EOF >> .hg/hgrc
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    39
  > [ui]
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    40
  > username = server
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    41
  > EOF
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    42
  $ mkcommit ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    43
  $ mkcommit c_A0
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    44
  $ hg up 'desc("ROOT")'
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    45
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    46
  $ mkcommit c_A1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    47
  created new head
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    48
  $ hg up 'desc("ROOT")'
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    49
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    50
  $ mkcommit c_B0
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    51
  created new head
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    52
  $ hg debugobsolete `getid 'desc("c_A0")'` `getid 'desc("c_A1")'`
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    53
  obsoleted 1 changesets
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
    54
  $ hg log -G --hidden -v
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    55
  @  3:e5d7dda7cd28 c_B0
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    56
  |
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    57
  | o  2:7f6b0a6f5c25 c_A1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    58
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
    59
  | x  1:e1b46f0f979f c_A0 [rewritten as 2:7f6b0a6f5c25 by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    60
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    61
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    62
  
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    63
  $ hg debugobsolete
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    64
  e1b46f0f979f52748347ff8729c59f2ef56e6fe2 7f6b0a6f5c25345a83870963efd827c1798a5959 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    65
  $ cd ..
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    66
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    67
duplicate the repo for the client:
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    68
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    69
  $ cp -R server client
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    70
  $ cat << EOF >> client/.hg/hgrc
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    71
  > [paths]
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    72
  > default = ../server/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    73
  > [ui]
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    74
  > username = client
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    75
  > EOF
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    76
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    77
server side: create new revision on the server (obsoleting another one)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    78
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    79
  $ cd server
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    80
  $ hg up 'desc("ROOT")'
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    81
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    82
  $ mkcommit c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    83
  created new head
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    84
  $ hg debugobsolete `getid 'desc("c_B0")'` `getid 'desc("c_B1")'`
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    85
  obsoleted 1 changesets
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    86
  $ hg log -G
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    87
  @  4:391a2bf12b1b c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    88
  |
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    89
  | o  2:7f6b0a6f5c25 c_A1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    90
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    91
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    92
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
    93
  $ hg log -G --hidden -v
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    94
  @  4:391a2bf12b1b c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    95
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
    96
  | x  3:e5d7dda7cd28 c_B0 [rewritten as 4:391a2bf12b1b by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    97
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    98
  | o  2:7f6b0a6f5c25 c_A1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
    99
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   100
  | x  1:e1b46f0f979f c_A0 [rewritten as 2:7f6b0a6f5c25 by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   101
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   102
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   103
  
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   104
  $ hg debugobsolete
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   105
  e1b46f0f979f52748347ff8729c59f2ef56e6fe2 7f6b0a6f5c25345a83870963efd827c1798a5959 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   106
  e5d7dda7cd28e6b3f79437e5b8122a38ece0255c 391a2bf12b1b8b05a72400ae36b26d50a091dc22 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   107
  $ cd ..
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   108
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   109
client side: create a marker between two common changesets
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   110
(client is not aware of the server activity yet)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   111
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   112
  $ cd client
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   113
  $ hg debugobsolete `getid 'desc("c_A1")'` `getid 'desc("c_B0")'`
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   114
  obsoleted 1 changesets
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   115
  $ hg log -G
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   116
  @  3:e5d7dda7cd28 c_B0
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   117
  |
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   118
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   119
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
   120
  $ hg log -G --hidden -v
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   121
  @  3:e5d7dda7cd28 c_B0
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   122
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   123
  | x  2:7f6b0a6f5c25 c_A1 [rewritten as 3:e5d7dda7cd28 by client (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   124
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   125
  | x  1:e1b46f0f979f c_A0 [rewritten as 2:7f6b0a6f5c25 by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   126
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   127
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   128
  
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   129
  $ hg debugobsolete
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   130
  e1b46f0f979f52748347ff8729c59f2ef56e6fe2 7f6b0a6f5c25345a83870963efd827c1798a5959 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   131
  7f6b0a6f5c25345a83870963efd827c1798a5959 e5d7dda7cd28e6b3f79437e5b8122a38ece0255c 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'client'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   132
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   133
client side: pull from the server
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   134
(the new successors should take over)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   135
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   136
  $ hg up 'desc("ROOT")'
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   137
  0 files updated, 0 files merged, 1 files removed, 0 files unresolved
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   138
  $ hg pull
35393
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34961
diff changeset
   139
  pulling from $TESTTMP/distributed-chain-building/server
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   140
  searching for changes
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   141
  adding changesets
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   142
  adding manifests
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   143
  adding file changes
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   144
  added 1 changesets with 1 changes to 1 files (+1 heads)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   145
  1 new obsolescence markers
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   146
  obsoleted 1 changesets
39480
89630d0b3e23 phase: report number of non-public changeset alongside the new range
Boris Feld <boris.feld@octobus.net>
parents: 35709
diff changeset
   147
  new changesets 391a2bf12b1b (1 drafts)
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   148
  (run 'hg heads' to see heads)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   149
  $ hg log -G
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   150
  o  4:391a2bf12b1b c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   151
  |
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   152
  @  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   153
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
   154
  $ hg log -G --hidden -v
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   155
  o  4:391a2bf12b1b c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   156
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   157
  | x  3:e5d7dda7cd28 c_B0 [rewritten as 4:391a2bf12b1b by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   158
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   159
  | x  2:7f6b0a6f5c25 c_A1 [rewritten as 3:e5d7dda7cd28 by client (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   160
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   161
  | x  1:e1b46f0f979f c_A0 [rewritten as 2:7f6b0a6f5c25 by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   162
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   163
  @  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   164
  
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   165
  $ hg debugobsolete
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   166
  e1b46f0f979f52748347ff8729c59f2ef56e6fe2 7f6b0a6f5c25345a83870963efd827c1798a5959 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   167
  7f6b0a6f5c25345a83870963efd827c1798a5959 e5d7dda7cd28e6b3f79437e5b8122a38ece0255c 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'client'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   168
  e5d7dda7cd28e6b3f79437e5b8122a38ece0255c 391a2bf12b1b8b05a72400ae36b26d50a091dc22 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   169
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   170
server side: receive client push
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   171
(the other way around, pushing to the server, the obsolete changesets stay
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   172
obsolete on the server side but the marker is sent out.)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   173
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   174
  $ hg rollback
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   175
  repository tip rolled back to revision 3 (undo pull)
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   176
  $ hg push -f
35393
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34961
diff changeset
   177
  pushing to $TESTTMP/distributed-chain-building/server
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   178
  searching for changes
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   179
  adding changesets
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   180
  adding manifests
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   181
  adding file changes
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   182
  added 0 changesets with 0 changes to 1 files
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   183
  1 new obsolescence markers
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   184
  obsoleted 1 changesets
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   185
  $ hg -R ../server/ log -G
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   186
  @  4:391a2bf12b1b c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   187
  |
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   188
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   189
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
   190
  $ hg -R ../server/ log -G --hidden -v
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   191
  @  4:391a2bf12b1b c_B1
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   192
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   193
  | x  3:e5d7dda7cd28 c_B0 [rewritten as 4:391a2bf12b1b by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   194
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   195
  | x  2:7f6b0a6f5c25 c_A1 [rewritten as 3:e5d7dda7cd28 by client (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   196
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   197
  | x  1:e1b46f0f979f c_A0 [rewritten as 2:7f6b0a6f5c25 by server (at 1970-01-01 00:00 +0000)]
34650
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   198
  |/
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   199
  o  0:e82fb8d02bbf ROOT
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   200
  
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   201
  $ hg debugobsolete
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   202
  e1b46f0f979f52748347ff8729c59f2ef56e6fe2 7f6b0a6f5c25345a83870963efd827c1798a5959 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'server'}
6c85f4e3d914 test: add a test file dedicated to an important distributed case
Boris Feld <boris.feld@octobus.net>
parents:
diff changeset
   203
  7f6b0a6f5c25345a83870963efd827c1798a5959 e5d7dda7cd28e6b3f79437e5b8122a38ece0255c 0 (Thu Jan 01 00:00:00 1970 +0000) {'user': 'client'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   204
  $ cd ..
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   205
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   206
Check getting changesets after getting the markers
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   207
=================================================
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   208
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   209
This test case covers the scenario where commits are received -after- we
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   210
received some obsolescence markers turning them obsolete.
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   211
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   212
For example, we pull some successors from a repository (with associated
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   213
predecessors marker chain) and then later we pull some intermediate
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   214
precedessors changeset from another repository. Obsolescence markers must
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   215
apply to the intermediate changeset. They have to be obsolete (and hidden).
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   216
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   217
Avoiding pulling the changeset in the first place is a tricky decision because
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   218
there could be non-obsolete ancestors that need to be pulled, but the
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   219
discovery cannot currently find these (this is not the case in this tests). In
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   220
addition, we could also have to pull the changeset because they have children.
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   221
In this case, they would not be hidden (yet) because of the orphan descendant,
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   222
but they would still have to be obsolete. (This is not tested in this case
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   223
either).
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   224
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   225
  $ mkdir distributed-chain-building
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   226
  $ cd distributed-chain-building
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   227
  $ hg init server
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   228
  $ cd server
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   229
  $ cat << EOF >> .hg/hgrc
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   230
  > [ui]
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   231
  > username = server
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   232
  > EOF
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   233
  $ mkcommit ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   234
  $ cd ..
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   235
  $ hg clone server repo-Alice
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   236
  updating to branch default
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   237
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   238
  $ cat << EOF >> repo-Alice/.hg/hgrc
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   239
  > [ui]
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   240
  > username = alice
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   241
  > EOF
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   242
  $ hg clone server repo-Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   243
  updating to branch default
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   244
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   245
  $ cat << EOF >> repo-Bob/.hg/hgrc
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   246
  > [ui]
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   247
  > username = bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   248
  > EOF
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   249
  $ hg clone server repo-Celeste
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   250
  updating to branch default
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   251
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   252
  $ cat << EOF >> repo-Celeste/.hg/hgrc
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   253
  > [ui]
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   254
  > username = celeste
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   255
  > EOF
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   256
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   257
Create some changesets locally
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   258
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   259
  $ cd repo-Alice
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   260
  $ mkcommit c_A0
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   261
  $ mkcommit c_B0
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   262
  $ cd ..
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   263
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   264
Bob pulls from Alice and rewrites them
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   265
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   266
  $ cd repo-Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   267
  $ hg pull ../repo-Alice
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   268
  pulling from ../repo-Alice
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   269
  searching for changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   270
  adding changesets
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   271
  adding manifests
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   272
  adding file changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   273
  added 2 changesets with 2 changes to 2 files
39480
89630d0b3e23 phase: report number of non-public changeset alongside the new range
Boris Feld <boris.feld@octobus.net>
parents: 35709
diff changeset
   274
  new changesets d33b0a3a6464:ef908e42ce65 (2 drafts)
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   275
  (run 'hg update' to get a working copy)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   276
  $ hg up 'desc("c_A")'
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   277
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   278
  $ hg commit --amend -m 'c_A1'
35709
1a09dad8b85a evolution: report new unstable changesets
Martin von Zweigbergk <martinvonz@google.com>
parents: 35393
diff changeset
   279
  1 new orphan changesets
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   280
  $ hg rebase -r 'desc("c_B0")' -d . # no easy way to rewrite the message with the rebase
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   281
  rebasing 2:ef908e42ce65 "c_B0"
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   282
  $ hg up
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   283
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   284
  $ hg commit --amend -m 'c_B1'
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   285
  $ hg log -G
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   286
  @  5:956063ac4557 c_B1
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   287
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   288
  o  3:5b5708a437f2 c_A1
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   289
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   290
  o  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   291
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
   292
  $ hg log -G --hidden -v
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   293
  @  5:956063ac4557 c_B1
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   294
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   295
  | x  4:5ffb9e311b35 c_B0 [rewritten using amend as 5:956063ac4557 by bob (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   296
  |/
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   297
  o  3:5b5708a437f2 c_A1
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   298
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   299
  | x  2:ef908e42ce65 c_B0 [rewritten using rebase as 4:5ffb9e311b35 by bob (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   300
  | |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   301
  | x  1:d33b0a3a6464 c_A0 [rewritten using amend as 3:5b5708a437f2 by bob (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   302
  |/
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   303
  o  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   304
  
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   305
  $ hg debugobsolete
34961
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   306
  d33b0a3a64647d79583526be8107802b1f9fedfa 5b5708a437f27665db42c5a261a539a1bcb2a8c2 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   307
  ef908e42ce65ef57f970d799acaddde26f58a4cc 5ffb9e311b35f6ab6f76f667ca5d6e595645481b 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   308
  5ffb9e311b35f6ab6f76f667ca5d6e595645481b 956063ac4557828781733b2d5677a351ce856f59 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   309
  $ cd ..
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   310
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   311
Celeste pulls from Bob and rewrites them again
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   312
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   313
  $ cd repo-Celeste
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   314
  $ hg pull ../repo-Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   315
  pulling from ../repo-Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   316
  searching for changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   317
  adding changesets
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   318
  adding manifests
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   319
  adding file changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   320
  added 2 changesets with 2 changes to 2 files
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   321
  3 new obsolescence markers
39480
89630d0b3e23 phase: report number of non-public changeset alongside the new range
Boris Feld <boris.feld@octobus.net>
parents: 35709
diff changeset
   322
  new changesets 5b5708a437f2:956063ac4557 (2 drafts)
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   323
  (run 'hg update' to get a working copy)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   324
  $ hg up 'desc("c_A")'
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   325
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   326
  $ hg commit --amend -m 'c_A2'
35709
1a09dad8b85a evolution: report new unstable changesets
Martin von Zweigbergk <martinvonz@google.com>
parents: 35393
diff changeset
   327
  1 new orphan changesets
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   328
  $ hg rebase -r 'desc("c_B1")' -d . # no easy way to rewrite the message with the rebase
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   329
  rebasing 2:956063ac4557 "c_B1"
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   330
  $ hg up
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   331
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   332
  $ hg commit --amend -m 'c_B2'
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   333
  $ hg log -G
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   334
  @  5:77ae25d99ff0 c_B2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   335
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   336
  o  3:9866d64649a5 c_A2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   337
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   338
  o  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   339
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
   340
  $ hg log -G --hidden -v
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   341
  @  5:77ae25d99ff0 c_B2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   342
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   343
  | x  4:3cf8de21cc22 c_B1 [rewritten using amend as 5:77ae25d99ff0 by celeste (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   344
  |/
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   345
  o  3:9866d64649a5 c_A2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   346
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   347
  | x  2:956063ac4557 c_B1 [rewritten using rebase as 4:3cf8de21cc22 by celeste (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   348
  | |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   349
  | x  1:5b5708a437f2 c_A1 [rewritten using amend as 3:9866d64649a5 by celeste (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   350
  |/
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   351
  o  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   352
  
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   353
  $ hg debugobsolete
34961
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   354
  5ffb9e311b35f6ab6f76f667ca5d6e595645481b 956063ac4557828781733b2d5677a351ce856f59 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   355
  d33b0a3a64647d79583526be8107802b1f9fedfa 5b5708a437f27665db42c5a261a539a1bcb2a8c2 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   356
  ef908e42ce65ef57f970d799acaddde26f58a4cc 5ffb9e311b35f6ab6f76f667ca5d6e595645481b 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   357
  5b5708a437f27665db42c5a261a539a1bcb2a8c2 9866d64649a5d9c5991fe119c7b2c33898114e10 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   358
  956063ac4557828781733b2d5677a351ce856f59 3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   359
  3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 77ae25d99ff07889e181126b1171b94bec8e5227 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   360
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   361
Celeste now pushes to the server
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   362
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   363
(note: it would be enough to just have direct Celeste -> Alice exchange here.
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   364
However using a central server seems more common)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   365
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   366
  $ hg push
35393
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34961
diff changeset
   367
  pushing to $TESTTMP/distributed-chain-building/distributed-chain-building/server
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   368
  searching for changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   369
  adding changesets
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   370
  adding manifests
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   371
  adding file changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   372
  added 2 changesets with 2 changes to 2 files
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   373
  6 new obsolescence markers
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   374
  $ cd ..
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   375
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   376
Now Alice pulls from the server, then from Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   377
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   378
Alice first retrieves the new evolution of its changesets and associated markers
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   379
from the server (note: could be from Celeste directly)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   380
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   381
  $ cd repo-Alice
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   382
  $ hg up 'desc(ROOT)'
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   383
  0 files updated, 0 files merged, 2 files removed, 0 files unresolved
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   384
  $ hg pull
35393
4441705b7111 tests: remove (glob) annotations that were only for '\' matches
Matt Harbison <matt_harbison@yahoo.com>
parents: 34961
diff changeset
   385
  pulling from $TESTTMP/distributed-chain-building/distributed-chain-building/server
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   386
  searching for changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   387
  adding changesets
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   388
  adding manifests
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   389
  adding file changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   390
  added 2 changesets with 0 changes to 2 files (+1 heads)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   391
  6 new obsolescence markers
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   392
  obsoleted 2 changesets
39480
89630d0b3e23 phase: report number of non-public changeset alongside the new range
Boris Feld <boris.feld@octobus.net>
parents: 35709
diff changeset
   393
  new changesets 9866d64649a5:77ae25d99ff0 (2 drafts)
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   394
  (run 'hg heads' to see heads)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   395
  $ hg debugobsolete
34961
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   396
  3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 77ae25d99ff07889e181126b1171b94bec8e5227 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   397
  5b5708a437f27665db42c5a261a539a1bcb2a8c2 9866d64649a5d9c5991fe119c7b2c33898114e10 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   398
  5ffb9e311b35f6ab6f76f667ca5d6e595645481b 956063ac4557828781733b2d5677a351ce856f59 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   399
  956063ac4557828781733b2d5677a351ce856f59 3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   400
  d33b0a3a64647d79583526be8107802b1f9fedfa 5b5708a437f27665db42c5a261a539a1bcb2a8c2 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   401
  ef908e42ce65ef57f970d799acaddde26f58a4cc 5ffb9e311b35f6ab6f76f667ca5d6e595645481b 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'bob'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   402
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   403
Then, she pulls from Bob, pulling predecessors of the changeset she has
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   404
already pulled. The changesets are not obsoleted in the Bob repo yet. Their
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   405
successors do not exist in Bob repository yet.
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   406
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   407
  $ hg pull ../repo-Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   408
  pulling from ../repo-Bob
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   409
  searching for changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   410
  adding changesets
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   411
  adding manifests
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   412
  adding file changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   413
  added 2 changesets with 0 changes to 2 files (+1 heads)
39899
f9232b0310ef pullreport: issue a message about "extinct" pulled changesets
Boris Feld <boris.feld@octobus.net>
parents: 39897
diff changeset
   414
  (2 other changesets obsolete on arrival)
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   415
  (run 'hg heads' to see heads)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   416
  $ hg log -G
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   417
  o  4:77ae25d99ff0 c_B2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   418
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   419
  o  3:9866d64649a5 c_A2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   420
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   421
  @  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   422
  
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   423
  $ hg debugobsolete
34961
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   424
  3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 77ae25d99ff07889e181126b1171b94bec8e5227 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   425
  5b5708a437f27665db42c5a261a539a1bcb2a8c2 9866d64649a5d9c5991fe119c7b2c33898114e10 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   426
  5ffb9e311b35f6ab6f76f667ca5d6e595645481b 956063ac4557828781733b2d5677a351ce856f59 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   427
  956063ac4557828781733b2d5677a351ce856f59 3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   428
  d33b0a3a64647d79583526be8107802b1f9fedfa 5b5708a437f27665db42c5a261a539a1bcb2a8c2 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   429
  ef908e42ce65ef57f970d799acaddde26f58a4cc 5ffb9e311b35f6ab6f76f667ca5d6e595645481b 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'bob'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   430
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   431
Same tests, but change coming from a bundle
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   432
(testing with a bundle is interesting because absolutely no discovery or
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   433
decision is made in that case, so receiving the changesets are not an option).
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   434
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   435
  $ hg rollback
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   436
  repository tip rolled back to revision 4 (undo pull)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   437
  $ hg log -G
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   438
  o  4:77ae25d99ff0 c_B2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   439
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   440
  o  3:9866d64649a5 c_A2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   441
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   442
  @  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   443
  
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   444
  $ hg debugobsolete
34961
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   445
  3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 77ae25d99ff07889e181126b1171b94bec8e5227 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   446
  5b5708a437f27665db42c5a261a539a1bcb2a8c2 9866d64649a5d9c5991fe119c7b2c33898114e10 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   447
  5ffb9e311b35f6ab6f76f667ca5d6e595645481b 956063ac4557828781733b2d5677a351ce856f59 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   448
  956063ac4557828781733b2d5677a351ce856f59 3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   449
  d33b0a3a64647d79583526be8107802b1f9fedfa 5b5708a437f27665db42c5a261a539a1bcb2a8c2 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   450
  ef908e42ce65ef57f970d799acaddde26f58a4cc 5ffb9e311b35f6ab6f76f667ca5d6e595645481b 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'bob'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   451
  $ hg -R ../repo-Bob bundle ../step-1.hg
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   452
  searching for changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   453
  2 changesets found
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   454
  $ hg unbundle ../step-1.hg
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   455
  adding changesets
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   456
  adding manifests
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   457
  adding file changes
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   458
  added 2 changesets with 0 changes to 2 files (+1 heads)
39899
f9232b0310ef pullreport: issue a message about "extinct" pulled changesets
Boris Feld <boris.feld@octobus.net>
parents: 39897
diff changeset
   459
  (2 other changesets obsolete on arrival)
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   460
  (run 'hg heads' to see heads)
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   461
  $ hg log -G
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   462
  o  4:77ae25d99ff0 c_B2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   463
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   464
  o  3:9866d64649a5 c_A2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   465
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   466
  @  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   467
  
34850
62a4ccf9784a obsfate: filter out current user if not in verbose
Boris Feld <boris.feld@octobus.net>
parents: 34847
diff changeset
   468
  $ hg log -G --hidden -v
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   469
  x  6:956063ac4557 c_B1 [rewritten using amend, rebase as 4:77ae25d99ff0 by celeste (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   470
  |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   471
  x  5:5b5708a437f2 c_A1 [rewritten using amend as 3:9866d64649a5 by celeste (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   472
  |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   473
  | o  4:77ae25d99ff0 c_B2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   474
  | |
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   475
  | o  3:9866d64649a5 c_A2
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   476
  |/
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   477
  | x  2:ef908e42ce65 c_B0 [rewritten using amend, rebase as 6:956063ac4557 by bob (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   478
  | |
34847
e27f1f04c2cf templatekw: introduce obsfate keyword
Boris Feld <boris.feld@octobus.net>
parents: 34661
diff changeset
   479
  | x  1:d33b0a3a6464 c_A0 [rewritten using amend as 5:5b5708a437f2 by bob (at 1970-01-01 00:00 +0000)]
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   480
  |/
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   481
  @  0:e82fb8d02bbf ROOT
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   482
  
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   483
  $ hg debugobsolete
34961
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   484
  3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 77ae25d99ff07889e181126b1171b94bec8e5227 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   485
  5b5708a437f27665db42c5a261a539a1bcb2a8c2 9866d64649a5d9c5991fe119c7b2c33898114e10 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   486
  5ffb9e311b35f6ab6f76f667ca5d6e595645481b 956063ac4557828781733b2d5677a351ce856f59 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   487
  956063ac4557828781733b2d5677a351ce856f59 3cf8de21cc2282186857d2266eb6b1f9cb85ecf3 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'celeste'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   488
  d33b0a3a64647d79583526be8107802b1f9fedfa 5b5708a437f27665db42c5a261a539a1bcb2a8c2 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '1', 'operation': 'amend', 'user': 'bob'}
a7e49a5b3e6f obsolete: activate effect-flag by default
Boris Feld <boris.feld@octobus.net>
parents: 34850
diff changeset
   489
  ef908e42ce65ef57f970d799acaddde26f58a4cc 5ffb9e311b35f6ab6f76f667ca5d6e595645481b 0 (Thu Jan 01 00:00:00 1970 +0000) {'ef1': '4', 'operation': 'rebase', 'user': 'bob'}
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   490
42129
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   491
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   492
Same tests, but with --rev, this prevent regressing case where `hg pull --rev
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   493
X` has to process a X that is filtered locally.
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   494
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   495
  $ hg rollback
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   496
  repository tip rolled back to revision 4 (undo unbundle)
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   497
  $ hg pull ../repo-Bob --rev 956063ac4557
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   498
  pulling from ../repo-Bob
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   499
  searching for changes
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   500
  adding changesets
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   501
  adding manifests
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   502
  adding file changes
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   503
  added 2 changesets with 0 changes to 2 files (+1 heads)
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   504
  (2 other changesets obsolete on arrival)
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   505
  (run 'hg heads' to see heads)
232a33a11ce0 pull: deal with locally filtered changeset passed into --rev
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 39899
diff changeset
   506
42130
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   507
With --update
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   508
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   509
  $ hg rollback
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   510
  repository tip rolled back to revision 4 (undo pull)
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   511
  $ hg pull ../repo-Bob --rev 956063ac4557 --update
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   512
  pulling from ../repo-Bob
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   513
  searching for changes
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   514
  adding changesets
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   515
  adding manifests
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   516
  adding file changes
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   517
  added 2 changesets with 0 changes to 2 files (+1 heads)
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   518
  (2 other changesets obsolete on arrival)
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   519
  abort: cannot update to target: filtered revision '6'!
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   520
  [255]
a362b0b95e42 pull: improved message issued in case of failed update
Pierre-Yves David <pierre-yves.david@octobus.net>
parents: 42129
diff changeset
   521
34651
e88dbbcf2a56 test: add an extra case for obsolescence distributed case
Boris Feld <boris.feld@octobus.net>
parents: 34650
diff changeset
   522
  $ cd ..
39896
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   523
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   524
Test pull report consistency
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   525
============================
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   526
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   527
obsolete but visible should be reported
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   528
---------------------------------------
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   529
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   530
Setup
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   531
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   532
  $ hg init repo-a
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   533
  $ cat << EOF >> repo-a/.hg/hgrc
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   534
  > [ui]
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   535
  > username=test
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   536
  > EOF
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   537
  $ cd repo-a
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   538
  $ hg debugbuilddag ..
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   539
  $ hg debugobsolete `getid tip`
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   540
  obsoleted 1 changesets
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   541
  $ cd ../
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   542
  $ hg clone --pull repo-a repo-b
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   543
  requesting all changes
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   544
  adding changesets
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   545
  adding manifests
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   546
  adding file changes
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   547
  added 1 changesets with 0 changes to 0 files
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   548
  new changesets 1ea73414a91b (1 drafts)
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   549
  updating to branch default
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   550
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   551
  $ hg -R repo-a up tip --hidden
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   552
  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   553
  updated to hidden changeset 66f7d451a68b
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   554
  (hidden revision '66f7d451a68b' is pruned)
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   555
  $ hg -R repo-a branch foo
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   556
  marked working directory as branch foo
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   557
  (branches are permanent and global, did you want a bookmark?)
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   558
  $ hg -R repo-a commit -m foo
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   559
  1 new orphan changesets
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   560
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   561
Actual test
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   562
(BROKEN)
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   563
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   564
  $ hg -R repo-b pull
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   565
  pulling from $TESTTMP/distributed-chain-building/distributed-chain-building/repo-a
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   566
  searching for changes
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   567
  adding changesets
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   568
  adding manifests
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   569
  adding file changes
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   570
  added 2 changesets with 0 changes to 0 files
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   571
  1 new obsolescence markers
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   572
  1 new orphan changesets
39897
a477679f6323 pullreport: skip filtered revs instead of obsolete ones
Boris Feld <boris.feld@octobus.net>
parents: 39896
diff changeset
   573
  new changesets 66f7d451a68b:95d586532b49 (2 drafts)
39896
642cbc228bad pullreport: add a test to show misreporting of visible changeset
Boris Feld <boris.feld@octobus.net>
parents: 39480
diff changeset
   574
  (run 'hg update' to get a working copy)