Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
hg-windows-ci
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mercurial
hg-windows-ci
Commits
75f6491b
Commit
75f6491b
authored
4 years ago
by
Manuel Jacob
Browse files
Options
Downloads
Patches
Plain Diff
discovery: weaken claim about returned common heads if ancestorsof are given
As the test case shows, the claim is not true in general.
parent
9719e118
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
mercurial/discovery.py
+2
-2
2 additions, 2 deletions
mercurial/discovery.py
tests/test-setdiscovery.t
+37
-0
37 additions, 0 deletions
tests/test-setdiscovery.t
with
39 additions
and
2 deletions
mercurial/discovery.py
+
2
−
2
View file @
75f6491b
...
...
@@ -41,8 +41,8 @@
any longer.
"
heads
"
is either the supplied heads, or else the remote
'
s heads.
"
ancestorsof
"
if not None, restrict the discovery to a subset defined by
these nodes. Changeset outside of this set won
'
t be considered (
and
won
'
t
appear
s
in
"
common
"
)
these nodes. Changeset outside of this set won
'
t be considered (
but may
still
appear in
"
common
"
)
.
If you pass heads and they are all known locally, the response lists just
these heads in
"
common
"
and in
"
heads
"
.
...
...
This diff is collapsed.
Click to expand it.
tests/test-setdiscovery.t
+
37
−
0
View file @
75f6491b
...
...
@@ -1112,3 +1112,40 @@
*
@
5
d0b986a083e0d91f116de4691e2aaa54d5bbec0
(
*
)
>
found
101
common
and
1
unknown
server
heads
,
1
roundtrips
in
*.
????
s (glob)
* @5d0b986a083e0d91f116de4691e2aaa54d5bbec0 (*)> -R r1 outgoing r2 *-T{rev} * --config *extensions.blackbox=* exited 0 after *.?? seconds (glo
b
)
$
cd
..
Even
if
the
set
of
revs
to
discover
is
restricted
,
unrelated
revs
may
be
returned
as
common
heads
.
$
mkdir
ancestorsof
$
cd
ancestorsof
$
hg
init
a
$
hg
clone
a
b
-
q
$ cd b
$
hg
debugbuilddag
'
.:root *root *root
'
$
hg
log
-
G
-
T
'
{node|short}
'
o
fa942426a6fd
|
|
o
66
f7d451a68b
|/
o
1
ea73414a91b
$
hg
push
-
r
66
f7d451a68b
-
q
$ hg debugdiscovery --verbose --rev fa942426a6fd
comparing
with
$TESTTMP
/ancestorsof/a
searching
for
changes
elapsed
time
:
*
seconds
(
glob
)
heads
summary:
total
common
heads:
1
also
local
heads:
1
also
remote
heads:
1
both:
1
local
heads:
2
common:
1
missing:
1
remote
heads:
1
common:
1
unknown:
0
local
changesets:
3
common:
2
missing:
1
common
heads:
66
f7d451a68b
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment