D1223: merge: disable path conflict checking by default (issue5716)

2017-10-23 Thread sid0 (Siddharth Agarwal)
sid0 updated this revision to Diff 3076.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D1223?vs=3075=3076

REVISION DETAIL
  https://phab.mercurial-scm.org/D1223

AFFECTED FILES
  mercurial/configitems.py
  tests/test-audit-path.t
  tests/test-commandserver.t
  tests/test-merge1.t
  tests/test-pathconflicts-basic.t
  tests/test-pathconflicts-merge.t
  tests/test-pathconflicts-update.t
  tests/test-update-names.t

CHANGE DETAILS

diff --git a/tests/test-update-names.t b/tests/test-update-names.t
--- a/tests/test-update-names.t
+++ b/tests/test-update-names.t
@@ -50,9 +50,7 @@
   $ hg st
   ? name/file
   $ hg up 1
-  name: untracked directory conflicts with file
-  abort: untracked files in working directory differ from files in requested 
revision
-  [255]
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ cd ..
 
 #if symlink
diff --git a/tests/test-pathconflicts-update.t 
b/tests/test-pathconflicts-update.t
--- a/tests/test-pathconflicts-update.t
+++ b/tests/test-pathconflicts-update.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
@@ -150,4 +158,3 @@
   $ hg up file2 --clean
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   (activating bookmark file2)
-
diff --git a/tests/test-pathconflicts-merge.t b/tests/test-pathconflicts-merge.t
--- a/tests/test-pathconflicts-merge.t
+++ b/tests/test-pathconflicts-merge.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
diff --git a/tests/test-pathconflicts-basic.t b/tests/test-pathconflicts-basic.t
--- a/tests/test-pathconflicts-basic.t
+++ b/tests/test-pathconflicts-basic.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
@@ -96,4 +104,3 @@
   commit: (clean)
   update: 1 new changesets, 2 branch heads (merge)
   phases: 4 draft
-
diff --git a/tests/test-merge1.t b/tests/test-merge1.t
--- a/tests/test-merge1.t
+++ b/tests/test-merge1.t
@@ -30,22 +30,23 @@
 
   $ mkdir b && touch b/nonempty
   $ hg up
-  b: untracked directory conflicts with file
-  abort: untracked files in working directory differ from files in requested 
revision
-  [255]
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg ci
   nothing changed
   [1]
   $ hg sum
-  parent: 0:538afb845929 
-   commit #0
+  parent: 1:b8bb4a988f25 tip
+   commit #1
   branch: default
-  commit: 1 unknown (clean)
-  update: 1 new changesets (update)
+  commit: (clean)
+  update: (current)
   phases: 2 draft
-  $ rm b/nonempty
+
+The following line is commented out because the file doesn't exist at the 
moment, and some OSes error out even with `rm -f`.
+$ rm b/nonempty
+
   $ hg up
-  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg sum
   parent: 1:b8bb4a988f25 tip
commit #1
diff --git a/tests/test-commandserver.t b/tests/test-commandserver.t
--- a/tests/test-commandserver.t
+++ b/tests/test-commandserver.t
@@ -975,12 +975,8 @@
   *** runcommand up -qC 2
   *** runcommand up -qC 1
   *** runcommand merge 2
-  a: path conflict - a file or link has the same name as a directory
-  the local file has been renamed to a~aa04623eb0c3
-  resolve manually then use 'hg resolve --mark a'
-  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to 
abandon
-   [1]
+  abort: path 'a/poisoned' traverses symbolic link 'a'
+   [255]
   $ ls ../merge-symlink-out
 
 cache of repo.auditor should be discarded, so matcher would never traverse
diff --git a/tests/test-audit-path.t b/tests/test-audit-path.t
--- a/tests/test-audit-path.t
+++ b/tests/test-audit-path.t
@@ -104,8 +104,7 @@
   back/test
 #if symlink
   $ hg update -Cr2
-  back: is both a file and a directory
-  abort: destination manifest contains path conflicts
+  abort: path 'back/test' traverses symbolic link 'back'
   [255]
 #else
 ('back' will be a file and cause some other system specific error)
@@ -167,24 +166,17 @@
 
   $ hg up -qC 1
   $ hg merge 2
-  a: path conflict - a file or link has the same name as a directory
-  the local file has been renamed to a~aa04623eb0c3
-  resolve manually then use 'hg resolve --mark a'
-  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-  use 'hg resolve' to retry 

Re: [PATCH 2 of 2 STABLE] setup: filter out devel-warn messages from system hg

2017-10-23 Thread Augie Fackler
queued these

> On Oct 23, 2017, at 23:19, Kevin Bullock  
> wrote:
> 
> # HG changeset patch
> # User Kevin Bullock 
> # Date 1508814839 18000
> #  Mon Oct 23 22:13:59 2017 -0500
> # Branch stable
> # Node ID adc50614340e952d8e98f5948d35b7bf632c2232
> # Parent  f13a8d056d6ebf490e65096391fdcd5916197f48
> setup: filter out devel-warn messages from system hg
> 
> If we're going to use the user's installed and configured hg command
> (which we do since 8b20338b989e), we should prevent devel-warn messages
> from interfering with locating it.
> 
> diff --git a/setup.py b/setup.py
> --- a/setup.py
> +++ b/setup.py
> @@ -218,7 +218,8 @@ def filterhgerr(err):
> err = [e for e in err.splitlines()
>if (not e.startswith(b'not trusting file')
>and not e.startswith(b'warning: Not importing')
> -   and not e.startswith(b'obsolete feature not enabled'))]
> +   and not e.startswith(b'obsolete feature not enabled')
> +   and not e.startswith(b'devel-warn:'))]
> return b'\n'.join(b'  ' + e for e in err)
> 
> def findhg():
> ___
> Mercurial-devel mailing list
> Mercurial-devel@mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel

___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


Re: [PATCH] commands: be more uniform in an "hg update" error message

2017-10-23 Thread Kevin Bullock
> On Oct 23, 2017, at 16:07, muxator via Mercurial-devel 
>  wrote:
> 
> # HG changeset patch
> # User muxator 
> # Date 1508791524 -7200
> #  Mon Oct 23 22:45:24 2017 +0200
> # Branch stable
> # Node ID a0d216dad0347ceb0d29a3506b4c63a0a37df8b9
> # Parent  83a8eaeba37151821781becdf285501ebf065695
> commands: be more uniform in an "hg update" error message

Queued, thanks.

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock

___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


Re: [PATCH] update: in the description update() in merge.py, mention the long options explicitly

2017-10-23 Thread Kevin Bullock
> On Oct 23, 2017, at 22:26, Kevin Bullock  
> wrote:
> 
>> On Oct 23, 2017, at 17:03, muxator  wrote:
>> 
>>> On 10/23/2017 11:56 PM, Kevin Bullock wrote:
 On Oct 23, 2017, at 16:07, muxator via Mercurial-devel 
  wrote:
 
 # HG changeset patch
 # User muxator 
 # Date 1507152154 -7200
 #  Wed Oct 04 23:22:34 2017 +0200
 # Branch stable
 # Node ID 83a8eaeba37151821781becdf285501ebf065695
 # Parent  780d13a58b332b3d18595af698eed1190fbe971e
 update: in the description update() in merge.py, mention the long options 
 explicitly
 
 The short options "-c" and "-C" may be confusing for a novice reading the
 documentation. Let's try to be more explicit, also mentioning the 
 equivalent
 long options ("--check" and "--clean") in the comments.
>>> This looks good, but our usual style in help is to say:
>>> 
>>>-c/--check and -C/--clean
>>> 
>>> instead of having the long options in parentheses. Okay if I update that 
>>> in-flight?
>> 
>> no problem at all!
> 
> Fixed in flight, re-wrapped, and queued, thanks.

I also reworded the summary line to be shorter -- check-commit says hi. For 
future patches please consider running at least test-check-*.t before sending.

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock

___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


Re: [PATCH] update: in the description update() in merge.py, mention the long options explicitly

2017-10-23 Thread Kevin Bullock
> On Oct 23, 2017, at 17:03, muxator  wrote:
> 
>> On 10/23/2017 11:56 PM, Kevin Bullock wrote:
>>> On Oct 23, 2017, at 16:07, muxator via Mercurial-devel 
>>>  wrote:
>>> 
>>> # HG changeset patch
>>> # User muxator 
>>> # Date 1507152154 -7200
>>> #  Wed Oct 04 23:22:34 2017 +0200
>>> # Branch stable
>>> # Node ID 83a8eaeba37151821781becdf285501ebf065695
>>> # Parent  780d13a58b332b3d18595af698eed1190fbe971e
>>> update: in the description update() in merge.py, mention the long options 
>>> explicitly
>>> 
>>> The short options "-c" and "-C" may be confusing for a novice reading the
>>> documentation. Let's try to be more explicit, also mentioning the equivalent
>>> long options ("--check" and "--clean") in the comments.
>> This looks good, but our usual style in help is to say:
>> 
>> -c/--check and -C/--clean
>> 
>> instead of having the long options in parentheses. Okay if I update that 
>> in-flight?
> 
> no problem at all!

Fixed in flight, re-wrapped, and queued, thanks.

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock

___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


[PATCH STABLE] packaging: update book URL in Mac and Windows READMEs

2017-10-23 Thread Kevin Bullock
# HG changeset patch
# User Kevin Bullock 
# Date 1508525691 18000
#  Fri Oct 20 13:54:51 2017 -0500
# Branch stable
# Node ID a1573e7daf038763fcd96669b797be72ad4447b0
# Parent  27481162780894fb82e4b2f679f967a3a86cbc3b
packaging: update book URL in Mac and Windows READMEs

diff --git a/contrib/macosx/Readme.html b/contrib/macosx/Readme.html
--- a/contrib/macosx/Readme.html
+++ b/contrib/macosx/Readme.html
@@ -27,7 +27,7 @@
 
 Visit the https://mercurial-scm.org/;>Mercurial web 
site and wiki
 
-There's also a free book, http://hgbook.red-bean.com/;>Distributed revision control with 
Mercurial
+There's also a free book, https://book.mercurial-scm.org/;>Distributed revision control with 
Mercurial
 
 Reporting problems
 
diff --git a/contrib/win32/ReadMe.html b/contrib/win32/ReadMe.html
--- a/contrib/win32/ReadMe.html
+++ b/contrib/win32/ReadMe.html
@@ -51,7 +51,7 @@
   For documentation, please visit the https://mercurial-scm.org/;>Mercurial web site.
   You can also download a free book, http://hgbook.red-bean.com/;>Mercurial: The Definitive
+  href="https://book.mercurial-scm.org/;>Mercurial: The Definitive
   Guide.
 
 
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


[PATCH 2 of 2 STABLE] setup: filter out devel-warn messages from system hg

2017-10-23 Thread Kevin Bullock
# HG changeset patch
# User Kevin Bullock 
# Date 1508814839 18000
#  Mon Oct 23 22:13:59 2017 -0500
# Branch stable
# Node ID adc50614340e952d8e98f5948d35b7bf632c2232
# Parent  f13a8d056d6ebf490e65096391fdcd5916197f48
setup: filter out devel-warn messages from system hg

If we're going to use the user's installed and configured hg command
(which we do since 8b20338b989e), we should prevent devel-warn messages
from interfering with locating it.

diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -218,7 +218,8 @@ def filterhgerr(err):
 err = [e for e in err.splitlines()
if (not e.startswith(b'not trusting file')
and not e.startswith(b'warning: Not importing')
-   and not e.startswith(b'obsolete feature not enabled'))]
+   and not e.startswith(b'obsolete feature not enabled')
+   and not e.startswith(b'devel-warn:'))]
 return b'\n'.join(b'  ' + e for e in err)
 
 def findhg():
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


[PATCH 1 of 2 STABLE] setup: remove duplicate assignment of HGRCPATH

2017-10-23 Thread Kevin Bullock
# HG changeset patch
# User Kevin Bullock 
# Date 1508812259 18000
#  Mon Oct 23 21:30:59 2017 -0500
# Branch stable
# Node ID f13a8d056d6ebf490e65096391fdcd5916197f48
# Parent  27481162780894fb82e4b2f679f967a3a86cbc3b
setup: remove duplicate assignment of HGRCPATH

HGRCPATH is already set in localhgenv().

diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -249,8 +249,6 @@ def findhg():
 
 # Fall back to trying the local hg installation.
 hgenv = localhgenv()
-# Don't source any system hgrc files when using the local hg.
-hgenv['HGRCPATH'] = ''
 hgcmd = [sys.executable, 'hg']
 try:
 retcode, out, err = runcmd(hgcmd + check_cmd, hgenv)
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


D1223: merge: disable path conflict checking by default (issue5716)

2017-10-23 Thread sid0 (Siddharth Agarwal)
sid0 updated this revision to Diff 3075.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D1223?vs=3074=3075

REVISION DETAIL
  https://phab.mercurial-scm.org/D1223

AFFECTED FILES
  mercurial/configitems.py
  tests/test-audit-path.t
  tests/test-commandserver.t
  tests/test-merge1.t
  tests/test-pathconflicts-basic.t
  tests/test-pathconflicts-merge.t
  tests/test-pathconflicts-update.t
  tests/test-update-names.t

CHANGE DETAILS

diff --git a/tests/test-update-names.t b/tests/test-update-names.t
--- a/tests/test-update-names.t
+++ b/tests/test-update-names.t
@@ -50,9 +50,7 @@
   $ hg st
   ? name/file
   $ hg up 1
-  name: untracked directory conflicts with file
-  abort: untracked files in working directory differ from files in requested 
revision
-  [255]
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ cd ..
 
 #if symlink
diff --git a/tests/test-pathconflicts-update.t 
b/tests/test-pathconflicts-update.t
--- a/tests/test-pathconflicts-update.t
+++ b/tests/test-pathconflicts-update.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
@@ -150,4 +158,3 @@
   $ hg up file2 --clean
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   (activating bookmark file2)
-
diff --git a/tests/test-pathconflicts-merge.t b/tests/test-pathconflicts-merge.t
--- a/tests/test-pathconflicts-merge.t
+++ b/tests/test-pathconflicts-merge.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
diff --git a/tests/test-pathconflicts-basic.t b/tests/test-pathconflicts-basic.t
--- a/tests/test-pathconflicts-basic.t
+++ b/tests/test-pathconflicts-basic.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
@@ -96,4 +104,3 @@
   commit: (clean)
   update: 1 new changesets, 2 branch heads (merge)
   phases: 4 draft
-
diff --git a/tests/test-merge1.t b/tests/test-merge1.t
--- a/tests/test-merge1.t
+++ b/tests/test-merge1.t
@@ -30,22 +30,20 @@
 
   $ mkdir b && touch b/nonempty
   $ hg up
-  b: untracked directory conflicts with file
-  abort: untracked files in working directory differ from files in requested 
revision
-  [255]
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg ci
   nothing changed
   [1]
   $ hg sum
-  parent: 0:538afb845929 
-   commit #0
+  parent: 1:b8bb4a988f25 tip
+   commit #1
   branch: default
-  commit: 1 unknown (clean)
-  update: 1 new changesets (update)
+  commit: (clean)
+  update: (current)
   phases: 2 draft
-  $ rm b/nonempty
+  $ rm -f b/nonempty
   $ hg up
-  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg sum
   parent: 1:b8bb4a988f25 tip
commit #1
diff --git a/tests/test-commandserver.t b/tests/test-commandserver.t
--- a/tests/test-commandserver.t
+++ b/tests/test-commandserver.t
@@ -975,12 +975,8 @@
   *** runcommand up -qC 2
   *** runcommand up -qC 1
   *** runcommand merge 2
-  a: path conflict - a file or link has the same name as a directory
-  the local file has been renamed to a~aa04623eb0c3
-  resolve manually then use 'hg resolve --mark a'
-  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to 
abandon
-   [1]
+  abort: path 'a/poisoned' traverses symbolic link 'a'
+   [255]
   $ ls ../merge-symlink-out
 
 cache of repo.auditor should be discarded, so matcher would never traverse
diff --git a/tests/test-audit-path.t b/tests/test-audit-path.t
--- a/tests/test-audit-path.t
+++ b/tests/test-audit-path.t
@@ -104,8 +104,7 @@
   back/test
 #if symlink
   $ hg update -Cr2
-  back: is both a file and a directory
-  abort: destination manifest contains path conflicts
+  abort: path 'back/test' traverses symbolic link 'back'
   [255]
 #else
 ('back' will be a file and cause some other system specific error)
@@ -167,24 +166,17 @@
 
   $ hg up -qC 1
   $ hg merge 2
-  a: path conflict - a file or link has the same name as a directory
-  the local file has been renamed to a~aa04623eb0c3
-  resolve manually then use 'hg resolve --mark a'
-  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to 
abandon
-  [1]
+  abort: path 'a/poisoned' traverses symbolic link 'a'
+  [255]
 

[Bug 5718] New: Filemerge crashes with an external Windows tool

2017-10-23 Thread mercurial-bugs
https://bz.mercurial-scm.org/show_bug.cgi?id=5718

Bug ID: 5718
   Summary: Filemerge crashes with an external Windows tool
   Product: Mercurial
   Version: 4.4-rc
  Hardware: PC
OS: Windows
Status: UNCONFIRMED
  Severity: bug
  Priority: urgent
 Component: Mercurial
  Assignee: bugzi...@mercurial-scm.org
  Reporter: matt_harbi...@yahoo.com
CC: lothiral...@gmail.com,
mercurial-devel@mercurial-scm.org

It looks like an issue with the default config registration.  I initially
caught this with TortoiseHg doing a visual diff, but it can be triggered with
core hg by doing a merge where the file changed on both sides.  I used the
evolve repo for convenience:

$ ../hg log -R ../../hg-evolve -r .
changeset:   3181:1893bde71ebc
branch:  stable
user:Pulkit Goyal <7895pul...@gmail.com>
date:Sat Oct 14 18:55:43 2017 +0200
summary: changelog: add about pager support

$ ../hg merge -R ../../hg-evolve -r 9a223c3adb9d
** Unknown exception encountered with possibly-broken third-party extension
evolve
** which supports versions 4.3 of Mercurial.
** Please disable evolve and try your action again.
** If that fixes the bug please report it to https://bz.mercurial-scm.org/
** Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:53:40) [MSC v.1500 64
bit (AMD64)]
** Mercurial Distributed SCM (version 4.4-rc+7-6a312fb102d4)
** Extensions loaded: eol, rebase, convert, graphlog, patchbomb, extdiff,
strip, mq, evolve
Traceback (most recent call last):
  File "../hg", line 41, in 
dispatch.run()
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 85, in run
status = (dispatch(req) or 0) & 255
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 173, in dispatch
ret = _runcatch(req)
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 313, in
_runcatch
return _callcatch(ui, _runcatchfunc)
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 321, in
_callcatch
return scmutil.callcatch(ui, func)
  File "c:\Users\Matt\projects\hg\mercurial\scmutil.py", line 154, in callcatch
return func()
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 303, in
_runcatchfunc
return _dispatch(req)
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 940, in
_dispatch
cmdpats, cmdoptions)
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 701, in
runcommand
ret = _runcommand(ui, options, cmd, d)
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 948, in
_runcommand
return cmdfunc()
  File "c:\Users\Matt\projects\hg\mercurial\dispatch.py", line 937, in 
d = lambda: util.checksignature(func)(ui, *args, **strcmdopt)
  File "c:\Users\Matt\projects\hg\mercurial\util.py", line 1183, in check
return func(*args, **kwargs)
  File "c:\Users\Matt\projects\hg\mercurial\util.py", line 1183, in check
return func(*args, **kwargs)
  File "c:\Users\Matt\projects\hg\hgext\mq.py", line 3583, in mqcommand
return orig(ui, repo, *args, **kwargs)
  File "c:\Users\Matt\projects\hg\mercurial\util.py", line 1183, in check
return func(*args, **kwargs)
  File "c:\Users\Matt\projects\hg\mercurial\commands.py", line 3585, in merge
labels=labels)
  File "c:\Users\Matt\projects\hg\mercurial\hg.py", line 848, in merge
labels=labels)
  File "c:\Users\Matt\projects\hg\mercurial\merge.py", line 1979, in update
stats = applyupdates(repo, actions, wc, p2, overwrite, labels=labels)
  File "c:\Users\Matt\projects\hg\mercurial\merge.py", line 1557, in
applyupdates
complete, r = ms.preresolve(f, wctx)
  File "c:\Users\Matt\projects\hg\mercurial\merge.py", line 581, in preresolve
return self._resolve(True, dfile, wctx)
  File "c:\Users\Matt\projects\hg\mercurial\merge.py", line 534, in _resolve
labels=self._labels)
  File "c:\Users\Matt\projects\hg\mercurial\filemerge.py", line 797, in
premerge
labels=labels)
  File "c:\Users\Matt\projects\hg\mercurial\filemerge.py", line 672, in
_filemerge
tool, toolpath = _picktool(repo, ui, fd, binary, symlink, changedelete)
  File "c:\Users\Matt\projects\hg\mercurial\filemerge.py", line 202, in
_picktool
if check(t, None, symlink, binary, changedelete):
  File "c:\Users\Matt\projects\hg\mercurial\filemerge.py", line 133, in check
if not _findtool(ui, tool):
  File "c:\Users\Matt\projects\hg\mercurial\filemerge.py", line 110, in
_findtool
return findexternaltool(ui, tool)
  File "c:\Users\Matt\projects\hg\mercurial\filemerge.py", line 119, in
findexternaltool
p = util.findexe(p + _toolstr(ui, tool, "regappend"))
TypeError: cannot concatenate 'str' and 'NoneType' objects

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org

[Bug 5717] New: static-http test fails on Windows with dirstatemap

2017-10-23 Thread mercurial-bugs
https://bz.mercurial-scm.org/show_bug.cgi?id=5717

Bug ID: 5717
   Summary: static-http test fails on Windows with dirstatemap
   Product: Mercurial
   Version: 4.4-rc
  Hardware: PC
OS: Windows
Status: UNCONFIRMED
  Severity: bug
  Priority: urgent
 Component: Mercurial
  Assignee: bugzi...@mercurial-scm.org
  Reporter: matt_harbi...@yahoo.com
CC: dur...@fb.com, mercurial-devel@mercurial-scm.org

The start of the change is this:

@@ -29,180 +29,8 @@
   $ cd ..
   $ hg clone static-http://localhost:$HGPORT/remote local
   requesting all changes
-  adding changesets
-  adding manifests
-  adding file changes
-  added 1 changesets with 2 changes to 2 files
-  updating to branch default
-  2 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  abort: The filename, directory name, or volume label syntax is incorrect:
'http://localhost:$HGPORT/remote/.hg\dirstate'

https://buildbot.mercurial-scm.org/builders/Win7%20x86_64%20hg%20tests%20%28stable%29/builds/47/steps/run-tests.py%20%28python%202.7.13%29/logs/stdio


Bisected to here:

changeset:   38401:c36c3fa7d35b
user:Durham Goode 
date:Tue Sep 26 03:56:20 2017 -0700
summary: dirstate: move opendirstatefile to dirstatemap

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


D1222: merge: add a config option to disable path conflict checking

2017-10-23 Thread sid0 (Siddharth Agarwal)
sid0 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  We've found a severe perf regression in `hg update` caused by the path 
conflict
  checking code. The next patch will disable this by default.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D1222

AFFECTED FILES
  mercurial/configitems.py
  mercurial/merge.py

CHANGE DETAILS

diff --git a/mercurial/merge.py b/mercurial/merge.py
--- a/mercurial/merge.py
+++ b/mercurial/merge.py
@@ -693,6 +693,7 @@
 abortconflicts = set()
 unknownconfig = _getcheckunknownconfig(repo, 'merge', 'checkunknown')
 ignoredconfig = _getcheckunknownconfig(repo, 'merge', 'checkignored')
+pathconfig = repo.ui.configbool('debug', 'merge.checkpathconflicts')
 if not force:
 def collectconflicts(conflicts, config):
 if config == 'abort':
@@ -704,7 +705,7 @@
 if m in ('c', 'dc'):
 if _checkunknownfile(repo, wctx, mctx, f):
 fileconflicts.add(f)
-elif f not in wctx:
+elif pathconfig and f not in wctx:
 path = _checkunknowndirs(repo, f)
 if path is not None:
 pathconflicts.add(path)
@@ -1139,8 +1140,9 @@
 actions[f] = ('dc', (None, f, f, False, pa.node()),
   "prompt deleted/changed")
 
-# If we are merging, look for path conflicts.
-checkpathconflicts(repo, wctx, p2, actions)
+if repo.ui.configbool('debug', 'merge.checkpathconflicts'):
+# If we are merging, look for path conflicts.
+checkpathconflicts(repo, wctx, p2, actions)
 
 return actions, diverge, renamedelete
 
diff --git a/mercurial/configitems.py b/mercurial/configitems.py
--- a/mercurial/configitems.py
+++ b/mercurial/configitems.py
@@ -575,6 +575,9 @@
 coreconfigitem('merge', 'checkignored',
 default='abort',
 )
+coreconfigitem('debug', 'merge.checkpathconflicts',
+default=True,
+)
 coreconfigitem('merge', 'followcopies',
 default=True,
 )



To: sid0, #hg-reviewers
Cc: mercurial-devel
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


D1223: merge: disable path conflict checking by default (issue5716)

2017-10-23 Thread sid0 (Siddharth Agarwal)
sid0 created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.

REVISION SUMMARY
  We shouldn't ship a severe perf regression in hg update for 4.4.

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D1223

AFFECTED FILES
  mercurial/configitems.py
  tests/test-audit-path.t
  tests/test-commandserver.t
  tests/test-merge1.t
  tests/test-pathconflicts-basic.t
  tests/test-pathconflicts-merge.t
  tests/test-pathconflicts-update.t
  tests/test-update-names.t

CHANGE DETAILS

diff --git a/tests/test-update-names.t b/tests/test-update-names.t
--- a/tests/test-update-names.t
+++ b/tests/test-update-names.t
@@ -50,9 +50,7 @@
   $ hg st
   ? name/file
   $ hg up 1
-  name: untracked directory conflicts with file
-  abort: untracked files in working directory differ from files in requested 
revision
-  [255]
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ cd ..
 
 #if symlink
diff --git a/tests/test-pathconflicts-update.t 
b/tests/test-pathconflicts-update.t
--- a/tests/test-pathconflicts-update.t
+++ b/tests/test-pathconflicts-update.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
@@ -150,4 +158,3 @@
   $ hg up file2 --clean
   1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   (activating bookmark file2)
-
diff --git a/tests/test-pathconflicts-merge.t b/tests/test-pathconflicts-merge.t
--- a/tests/test-pathconflicts-merge.t
+++ b/tests/test-pathconflicts-merge.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
diff --git a/tests/test-pathconflicts-basic.t b/tests/test-pathconflicts-basic.t
--- a/tests/test-pathconflicts-basic.t
+++ b/tests/test-pathconflicts-basic.t
@@ -1,3 +1,11 @@
+Path conflict checking is currently disabled by default because of issue5716.
+Turn it on for this test.
+
+  $ cat >> $HGRCPATH << EOF
+  > [debug]
+  > merge.checkpathconflicts=True
+  > EOF
+
   $ hg init repo
   $ cd repo
   $ echo base > base
@@ -96,4 +104,3 @@
   commit: (clean)
   update: 1 new changesets, 2 branch heads (merge)
   phases: 4 draft
-
diff --git a/tests/test-merge1.t b/tests/test-merge1.t
--- a/tests/test-merge1.t
+++ b/tests/test-merge1.t
@@ -30,22 +30,22 @@
 
   $ mkdir b && touch b/nonempty
   $ hg up
-  b: untracked directory conflicts with file
-  abort: untracked files in working directory differ from files in requested 
revision
-  [255]
+  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg ci
   nothing changed
   [1]
   $ hg sum
-  parent: 0:538afb845929 
-   commit #0
+  parent: 1:b8bb4a988f25 tip
+   commit #1
   branch: default
-  commit: 1 unknown (clean)
-  update: 1 new changesets (update)
+  commit: (clean)
+  update: (current)
   phases: 2 draft
   $ rm b/nonempty
+  rm: cannot remove 'b/nonempty': Not a directory
+  [1]
   $ hg up
-  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
+  0 files updated, 0 files merged, 0 files removed, 0 files unresolved
   $ hg sum
   parent: 1:b8bb4a988f25 tip
commit #1
diff --git a/tests/test-commandserver.t b/tests/test-commandserver.t
--- a/tests/test-commandserver.t
+++ b/tests/test-commandserver.t
@@ -975,12 +975,8 @@
   *** runcommand up -qC 2
   *** runcommand up -qC 1
   *** runcommand merge 2
-  a: path conflict - a file or link has the same name as a directory
-  the local file has been renamed to a~aa04623eb0c3
-  resolve manually then use 'hg resolve --mark a'
-  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-  use 'hg resolve' to retry unresolved file merges or 'hg update -C .' to 
abandon
-   [1]
+  abort: path 'a/poisoned' traverses symbolic link 'a'
+   [255]
   $ ls ../merge-symlink-out
 
 cache of repo.auditor should be discarded, so matcher would never traverse
diff --git a/tests/test-audit-path.t b/tests/test-audit-path.t
--- a/tests/test-audit-path.t
+++ b/tests/test-audit-path.t
@@ -104,8 +104,7 @@
   back/test
 #if symlink
   $ hg update -Cr2
-  back: is both a file and a directory
-  abort: destination manifest contains path conflicts
+  abort: path 'back/test' traverses symbolic link 'back'
   [255]
 #else
 ('back' will be a file and cause some other system specific error)
@@ -167,24 +166,17 @@
 
   $ hg up -qC 1
   $ hg merge 2
-  a: path conflict - a file or link has the same name as a directory
-  the local file has been renamed to a~aa04623eb0c3
-  resolve manually then use 'hg resolve --mark a'
-  1 files updated, 0 files merged, 0 files removed, 1 files unresolved
-  use 'hg resolve' to retry unresolved file 

[Bug 5716] New: severe perf regression in hg update because of path conflict checking code

2017-10-23 Thread mercurial-bugs
https://bz.mercurial-scm.org/show_bug.cgi?id=5716

Bug ID: 5716
   Summary: severe perf regression in hg update because of path
conflict checking code
   Product: Mercurial
   Version: 4.4-rc
  Hardware: All
OS: All
Status: UNCONFIRMED
  Severity: bug
  Priority: urgent
 Component: Mercurial
  Assignee: bugzi...@mercurial-scm.org
  Reporter: sid+h...@less-broken.com
CC: mercurial-devel@mercurial-scm.org

We're tracking a severe performance regression in hg update in 4.4rc that
appears to be because of path conflict checking code.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


Re: [PATCH] update: in the description update() in merge.py, mention the long options explicitly

2017-10-23 Thread muxator via Mercurial-devel

no problem at all!


On 10/23/2017 11:56 PM, Kevin Bullock wrote:

On Oct 23, 2017, at 16:07, muxator via Mercurial-devel 
 wrote:

# HG changeset patch
# User muxator 
# Date 1507152154 -7200
#  Wed Oct 04 23:22:34 2017 +0200
# Branch stable
# Node ID 83a8eaeba37151821781becdf285501ebf065695
# Parent  780d13a58b332b3d18595af698eed1190fbe971e
update: in the description update() in merge.py, mention the long options 
explicitly

The short options "-c" and "-C" may be confusing for a novice reading the
documentation. Let's try to be more explicit, also mentioning the equivalent
long options ("--check" and "--clean") in the comments.

This looks good, but our usual style in help is to say:

 -c/--check and -C/--clean

instead of having the long options in parentheses. Okay if I update that 
in-flight?

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock




___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


Re: [PATCH] update: in the description update() in merge.py, mention the long options explicitly

2017-10-23 Thread Kevin Bullock
> On Oct 23, 2017, at 16:07, muxator via Mercurial-devel 
>  wrote:
> 
> # HG changeset patch
> # User muxator 
> # Date 1507152154 -7200
> #  Wed Oct 04 23:22:34 2017 +0200
> # Branch stable
> # Node ID 83a8eaeba37151821781becdf285501ebf065695
> # Parent  780d13a58b332b3d18595af698eed1190fbe971e
> update: in the description update() in merge.py, mention the long options 
> explicitly
> 
> The short options "-c" and "-C" may be confusing for a novice reading the
> documentation. Let's try to be more explicit, also mentioning the equivalent
> long options ("--check" and "--clean") in the comments.

This looks good, but our usual style in help is to say:

-c/--check and -C/--clean

instead of having the long options in parentheses. Okay if I update that 
in-flight?

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock

___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


[PATCH] update: in the description update() in merge.py, mention the long options explicitly

2017-10-23 Thread muxator via Mercurial-devel
# HG changeset patch
# User muxator 
# Date 1507152154 -7200
#  Wed Oct 04 23:22:34 2017 +0200
# Branch stable
# Node ID 83a8eaeba37151821781becdf285501ebf065695
# Parent  780d13a58b332b3d18595af698eed1190fbe971e
update: in the description update() in merge.py, mention the long options 
explicitly

The short options "-c" and "-C" may be confusing for a novice reading the
documentation. Let's try to be more explicit, also mentioning the equivalent
long options ("--check" and "--clean") in the comments.

diff --git a/mercurial/merge.py b/mercurial/merge.py
--- a/mercurial/merge.py
+++ b/mercurial/merge.py
@@ -1728,11 +1728,11 @@
   this is True, then 'force' should be True as well.
 
 The table below shows all the behaviors of the update command
-given the -c and -C or no options, whether the working directory
-is dirty, whether a revision is specified, and the relationship of
-the parent rev to the target rev (linear or not). Match from top first. The
--n option doesn't exist on the command line, but represents the
-experimental.updatecheck=noconflict option.
+given the -c (--check) and -C (--clean) or no options, whether the
+working directory is dirty, whether a revision is specified, and the
+relationship of the parent rev to the target rev (linear or not).
+Match from top first. The -n option doesn't exist on the command
+line, but represents the experimental.updatecheck=noconflict option.
 
 This logic is tested by test-update-branches.t.
 
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


[PATCH] commands: be more uniform in an "hg update" error message

2017-10-23 Thread muxator via Mercurial-devel
# HG changeset patch
# User muxator 
# Date 1508791524 -7200
#  Mon Oct 23 22:45:24 2017 +0200
# Branch stable
# Node ID a0d216dad0347ceb0d29a3506b4c63a0a37df8b9
# Parent  83a8eaeba37151821781becdf285501ebf065695
commands: be more uniform in an "hg update" error message

"can only specify one of -C/--clean, -c/--check, or -m/merge"
becomes
"can only specify one of -C/--clean, -c/--check, or -m/--merge"

diff --git a/i18n/ja.po b/i18n/ja.po
--- a/i18n/ja.po
+++ b/i18n/ja.po
@@ -16535,8 +16535,8 @@
 msgid "for example: hg update \".::\""
 msgstr "指定例: hg update \".::\""
 
-msgid "can only specify one of -C/--clean, -c/--check, or -m/merge"
-msgstr "-C/--clean, -c/--check および -m/merge は複数指定できません"
+msgid "can only specify one of -C/--clean, -c/--check, or -m/--merge"
+msgstr "-C/--clean, -c/--check および -m/--merge は複数指定できません"
 
 msgid "verify the integrity of the repository"
 msgstr "リポジトリの整合性検証"
diff --git a/i18n/pt_BR.po b/i18n/pt_BR.po
--- a/i18n/pt_BR.po
+++ b/i18n/pt_BR.po
@@ -18293,9 +18293,9 @@
 msgid "for example: hg update \".::\""
 msgstr "por exemplo: hg update \".::\""
 
-msgid "can only specify one of -C/--clean, -c/--check, or -m/merge"
-msgstr ""
-"só se pode especificar uma opção dentre -C/--clean, -c/--check ou -m/merge"
+msgid "can only specify one of -C/--clean, -c/--check, or -m/--merge"
+msgstr ""
+"só se pode especificar uma opção dentre -C/--clean, -c/--check ou -m/--merge"
 
 msgid "verify the integrity of the repository"
 msgstr "verifica a integridade do repositório"
diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -5489,7 +5489,7 @@
 
 if len([x for x in (clean, check, merge) if x]) > 1:
 raise error.Abort(_("can only specify one of -C/--clean, -c/--check, "
-"or -m/merge"))
+"or -m/--merge"))
 
 updatecheck = None
 if check:
diff --git a/tests/test-update-branches.t b/tests/test-update-branches.t
--- a/tests/test-update-branches.t
+++ b/tests/test-update-branches.t
@@ -184,17 +184,17 @@
   parent=2
 
   $ revtest '-cC dirty linear'  dirty 1 2 -cC
-  abort: can only specify one of -C/--clean, -c/--check, or -m/merge
+  abort: can only specify one of -C/--clean, -c/--check, or -m/--merge
   parent=1
   M foo
 
   $ revtest '-mc dirty linear'  dirty 1 2 -mc
-  abort: can only specify one of -C/--clean, -c/--check, or -m/merge
+  abort: can only specify one of -C/--clean, -c/--check, or -m/--merge
   parent=1
   M foo
 
   $ revtest '-mC dirty linear'  dirty 1 2 -mC
-  abort: can only specify one of -C/--clean, -c/--check, or -m/merge
+  abort: can only specify one of -C/--clean, -c/--check, or -m/--merge
   parent=1
   M foo
 
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


D868: changelog: use attrs instead of namedtuple

2017-10-23 Thread lothiraldan (Boris Feld)
lothiraldan added a comment.


  The perf difference is not big, but I'm not sure if it's due to the import 
time of attrs because basic_commands.TimeTestSuite.time_version didn't change 
much. I have the impression that we pay a cost the first time an attrs-based 
class is instantiated.
  
  I've pasted all the data because they are a lot of tests (but not all) that 
became worst with this changeset (2-3 ms on average I would say) so if someone 
also finds it fishy, maybe we should take a look?
  
  For comparison, here is `asv compare` between this changeset grand-parent and 
its parent:
  
asv compare 9fb9f8440b71 765eb17a7eb8 -s

Benchmarks that have stayed the same:

   before   after ratio
 [9fb9f844]   [765eb17a]
  82.3±0.02ms  82.2±0.01ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 10)
   218±0.07ms   218±0.01ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 100)
  1.26±0s  1.25±0s 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 1000)
  3.81±0s  3.79±0s 0.99  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 1)
   150±0.02ms   150±0.02ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 10)
   165±0.02ms   165±0.02ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 100)
   359±0.09ms359±0.1ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 1000)
  2.52±0s  2.52±0s 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 1)
  102±0ms   102±0.01ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('netbeans-2017', 10)
   139±0.01ms   138±0.01ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('netbeans-2017', 100)
370±0.2ms369±0.2ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('netbeans-2017', 1000)
 60.4±0ms 60.4±0ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 10)
 78.2±0ms 78.1±0ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 100)
   251±0.05ms   251±0.03ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 1000)
  7.62±0s   7.57±0.01s 0.99  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 1)
   67.1ms   67.2ms 1.00  
basic_commands.TestSuite.track_commit('mercurial-2017')
2.79s2.79s 1.00  
basic_commands.TestSuite.track_commit('mozilla-central-2017')
1.54s1.54s 1.00  
basic_commands.TestSuite.track_commit('netbeans-2017')
192ms192ms 1.00  
basic_commands.TestSuite.track_commit('pypy-2017')
 38.3±0ms 38.2±0ms 1.00  
basic_commands.TimeTestSuite.time_bookmarks('mercurial-2017')
 44.8±0ms 44.7±0ms 1.00  
basic_commands.TimeTestSuite.time_bookmarks('mozilla-central-2017')
 43.5±0ms 43.4±0ms 1.00  
basic_commands.TimeTestSuite.time_bookmarks('netbeans-2017')
 38.7±0ms 38.5±0ms 1.00  
basic_commands.TimeTestSuite.time_bookmarks('pypy-2017')
 46.7±0ms 46.7±0ms 1.00  
basic_commands.TimeTestSuite.time_diff_tip('mercurial-2017')
657±0.2ms   656±0.07ms 1.00  
basic_commands.TimeTestSuite.time_diff_tip('mozilla-central-2017')
   342±0.01ms   342±0.03ms 1.00  
basic_commands.TimeTestSuite.time_diff_tip('netbeans-2017')
 55.7±0ms 55.6±0ms 1.00  
basic_commands.TimeTestSuite.time_diff_tip('pypy-2017')
 44.1±0ms 43.9±0ms 1.00  
basic_commands.TimeTestSuite.time_emptydiff('mercurial-2017')
869±0.2ms   870±0.08ms 1.00  
basic_commands.TimeTestSuite.time_emptydiff('mozilla-central-2017')
   408±0.05ms   408±0.08ms 1.00  
basic_commands.TimeTestSuite.time_emptydiff('netbeans-2017')
 57.2±0ms  57.1±0.01ms 1.00  
basic_commands.TimeTestSuite.time_emptydiff('pypy-2017')
 48.8±0ms 48.7±0ms 1.00  
basic_commands.TimeTestSuite.time_emptystatus('mercurial-2017')
  1.25±0s  1.25±0s 1.00  
basic_commands.TimeTestSuite.time_emptystatus('mozilla-central-2017')
763±0.1ms762±0.9ms 1.00  
basic_commands.TimeTestSuite.time_emptystatus('netbeans-2017')
 66.3±0ms  66.2±0.01ms 1.00  
basic_commands.TimeTestSuite.time_emptystatus('pypy-2017')
 45.1±0ms 45.0±0ms 1.00  
basic_commands.TimeTestSuite.time_id('mercurial-2017')
871±0.1ms872±0.1ms 1.00  

D868: changelog: use attrs instead of namedtuple

2017-10-23 Thread durin42 (Augie Fackler)
durin42 added a comment.


  @lothiraldan you very much buried the lede here (lots of data about things 
that didn't change, but no inline data on what didn't). The regressions appear 
to be:
  
  basic_commands.TimeTestSuite.time_id_current('mercurial-2017') 43.922ms -> 
46.190ms
  basic_commands.TimeTestSuite.time_emptydiff('mercurial-2017') 43.185ms -> 
45.353ms
  
  My guess is that this has to do with the import cost of attr, and that it 
doesn't scale linearly with the size of the repo. I'm disinclined to be 
concerned about the 1-2ms for now, especially given that we'll be able to pay 
the attr import cost once, but namedtuples are known to be expensive *per 
namedtuple* (so as we move from namedtuple to attr we should make this loss 
back.)
  
  (Other reviewers: please chime in if you disagree. I know there's a slippery 
slope for perf here, but I'm not inclined to worry at all about 44 vs 46 ms for 
id, or 43 vs 45 for empty-diff. It very much looks like once any actual 
statting has to be done the import cost is lost in the noise.)

REPOSITORY
  rHG Mercurial

REVISION DETAIL
  https://phab.mercurial-scm.org/D868

To: sid0, #hg-reviewers, durin42
Cc: lothiraldan, mercurial-devel
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel


D868: changelog: use attrs instead of namedtuple

2017-10-23 Thread lothiraldan (Boris Feld)
lothiraldan added a comment.


  We detected a small performance regression on this changeset thanks to our 
ASV instance: http://perf.octobus.net/#regressions?sort=3=desc (look for 
https://phab.mercurial-scm.org/rHGe51c8ffa1ffa3524e01cd1d1f60c79fc5ef02e43).
  
  It seems to have slow down enough `hg id -r .` on Mercurial repository and 
`hg diff` on a clean Mercurial repository for ASV to detect it as a regression.
  
  I'm dumping the raw results of asv compare because they are not available 
else-where if someone wants to take a look. Should I open a ticket on the bug 
tracker?
  
Benchmarks that have stayed the same:

   before   after ratio
 [765eb17a]   [e51c8ffa]
  82.2±0.01ms  83.8±0.01ms 1.02  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 10)
   218±0.01ms   221±0.06ms 1.01  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 100)
  1.25±0s  1.26±0s 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 1000)
  3.79±0s  3.79±0s 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mercurial-2017', 1)
   150±0.02ms   152±0.01ms 1.01  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 10)
   165±0.02ms   166±0.01ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 100)
359±0.1ms362±0.1ms 1.01  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 1000)
  2.52±0s  2.52±0s 1.00  
basic_commands.LogTimeTestSuite.time_log_history('mozilla-central-2017', 1)
   102±0.01ms  103±0ms 1.02  
basic_commands.LogTimeTestSuite.time_log_history('netbeans-2017', 10)
   138±0.01ms   140±0.02ms 1.01  
basic_commands.LogTimeTestSuite.time_log_history('netbeans-2017', 100)
369±0.2ms   371±0.08ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('netbeans-2017', 1000)
 60.4±0ms 62.5±0ms 1.03  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 10)
 78.1±0ms  80.1±0.01ms 1.03  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 100)
   251±0.03ms   251±0.07ms 1.00  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 1000)
   7.57±0.01s  7.59±0s 1.00  
basic_commands.LogTimeTestSuite.time_log_history('pypy-2017', 1)
   67.2ms   69.1ms 1.03  
basic_commands.TestSuite.track_commit('mercurial-2017')
2.79s2.80s 1.00  
basic_commands.TestSuite.track_commit('mozilla-central-2017')
1.54s1.54s 1.00  
basic_commands.TestSuite.track_commit('netbeans-2017')
192ms194ms 1.01  
basic_commands.TestSuite.track_commit('pypy-2017')
 38.2±0ms 39.9±0ms 1.05  
basic_commands.TimeTestSuite.time_bookmarks('mercurial-2017')
 44.7±0ms 46.8±0ms 1.05  
basic_commands.TimeTestSuite.time_bookmarks('mozilla-central-2017')
 43.4±0ms 45.5±0ms 1.05  
basic_commands.TimeTestSuite.time_bookmarks('netbeans-2017')
 38.5±0ms 40.6±0ms 1.05  
basic_commands.TimeTestSuite.time_bookmarks('pypy-2017')
 46.7±0ms 48.3±0ms 1.04  
basic_commands.TimeTestSuite.time_diff_tip('mercurial-2017')
   656±0.07ms659±0.2ms 1.00  
basic_commands.TimeTestSuite.time_diff_tip('mozilla-central-2017')
   342±0.03ms   344±0.02ms 1.01  
basic_commands.TimeTestSuite.time_diff_tip('netbeans-2017')
 55.6±0ms 57.3±0ms 1.03  
basic_commands.TimeTestSuite.time_diff_tip('pypy-2017')
 43.9±0ms   46.1±0.2ms 1.05  
basic_commands.TimeTestSuite.time_emptydiff('mercurial-2017')
   870±0.08ms   873±0.03ms 1.00  
basic_commands.TimeTestSuite.time_emptydiff('mozilla-central-2017')
   408±0.08ms   410±0.02ms 1.01  
basic_commands.TimeTestSuite.time_emptydiff('netbeans-2017')
  57.1±0.01ms 58.9±0ms 1.03  
basic_commands.TimeTestSuite.time_emptydiff('pypy-2017')
 48.7±0ms 50.4±0ms 1.04  
basic_commands.TimeTestSuite.time_emptystatus('mercurial-2017')
  1.25±0s  1.25±0s 1.00  
basic_commands.TimeTestSuite.time_emptystatus('mozilla-central-2017')
762±0.9ms763±0.3ms 1.00  
basic_commands.TimeTestSuite.time_emptystatus('netbeans-2017')
  66.2±0.01ms 67.8±0ms 1.02  
basic_commands.TimeTestSuite.time_emptystatus('pypy-2017')
 45.0±0ms 46.7±0ms 1.04  
basic_commands.TimeTestSuite.time_id('mercurial-2017')
872±0.1ms   874±0.01ms 1.00  
basic_commands.TimeTestSuite.time_id('mozilla-central-2017')
  

Re: [PATCH 01 of 15] pull: store binary node in pullop.remotebookmarks

2017-10-23 Thread Boris Feld
On Wed, 2017-10-18 at 19:25 +0200, Gregory Szorc wrote:
> On Wed, Oct 18, 2017 at 6:09 PM, Boris Feld 
> wrote:
> > # HG changeset patch
> > # User Boris Feld 
> > # Date 1508230905 -7200
> > #      Tue Oct 17 11:01:45 2017 +0200
> > # Node ID a450dc69ef95073af4d4ece34e251ed0bb5b808f
> > # Parent  537de0b14030868e3e850ae388b08f88cabc88e8
> > # EXP-Topic b2.bookmarks
> > # Available At https://bitbucket.org/octobus/mercurial-devel/
> > #              hg pull https://bitbucket.org/octobus/mercurial-deve
> > l/ -r a450dc69ef95
> > pull: store binary node in pullop.remotebookmarks
> > 
> > The internal representation of bookmark value is binary. The fact
> > we stored
> > 'hex' was an implementation detail from using pushkey.
> > 
> > We move the values in 'pullop.remotebookmarks' to binary before
> > adding a way to
> > exchange bookmarks not based on pushkey.
> 
> The overall approach seems reasonable and works. But the wire
> protocol is one of those things that you need to support forever. So
> it is important that any changes get strict scrutiny.
> 
> General questions/feedback:
> 
> * The series does the simplest thing and basically copies the old
> bookmarks logic to bundle2. What are your thoughts on changing the
> structure a bit? e.g. instead of separate check and set bundle parts,
> what about a single part that records the old state of bookmarks?
> We'd need to send this first to facilitate aborting early on
> consistency mismatch, of course. I'm not claiming one approach is
> better: I'm just throwing out an alternative to consider.

Actually, the current logic (with pushkey) is already using this part
for check and set.

One of the goals of this series was to split the two parts:

* The check part is rarely used. It is only necessary for (unforced)
bookmark push.
* Every other usage (pull, bundle, forced push, etc) just need the
other part. So keeping them separated is an improvement.

Also, I'm afraid that receiving the bookmarks part before the changeset
part would make the bookmarks part handling more complex. We would have
to keep the data around 
until the changeset it refers actually shows up.

> 
> * There are a number of places that could benefit from early return
> control flow.
> 
> * I believe after this series we now have both a "bookmarks" query
> string argument *and* a "bookmarks" entry in the listkeys value for
> bundle requests. Is this redundancy needed? Could you please document
> any new arguments in wireproto.txt.

Yes, we would have both but we would use one or the other, never both
at the same time. The redundancy is needed for handling pre-Mercurial
4.4 clients or servers as we could not use the new bookmarks part. We
will update the wireproto.txt documentation.

> 
> * The config option related to pushkey hooks firing is seemingly very
> low-level. I'm tempted to omit the option and instead establish a BC
> schedule to drop the old behavior (assuming we don't want to support
> it forever).

Just dropping it seems dangerous for our users. What about:

* mark the option as 'advanced' (not documented unless -v is used).

* change the default to False in a couple of versions.

> 
> * While we're here, a feature I've long wanted to implement is `hg
> pull --mirror`. Please spend a few seconds contemplating if that
> would require any wire protocol changes to support for bookmarks
> exchange. If so, we may want to implement it now so we don't have to
> implement more "protocol negotiation" later.

We don't need any protocol update for this feature. We can do it with
listkey today and we will be able to do it with the bookmarks part
tomorrow.

> 
> * Do we have sufficient test coverage around force pushing for both
> the old and new style of bookmarks exchange? I could see that as one
> of those things that easily regresses unless we're actively testing
> both variations.

Yes, we made sure to run all existing exchange tests with both versions
(pushkey and bookmarks part). So we should be as covered as before.

> 
> * Landing wire protocol changes just before the freeze is a bit
> scary. I know this is a major bug and I want to see it fixed as well.
> But the schedule is concerning. I'd feel much more comfortable if
> this were behind a config knob until 4.5.

I'm not sure to understand what you mean? Do want us to send a V2 with
a config knob that would be included in the 4.4 release? Or do we wait
for the 4.5 cycle to start to send a V2? Giving the current timing,
waiting for 4.5 is preferred on our side.

>  
> > diff --git a/mercurial/commands.py b/mercurial/commands.py
> > --- a/mercurial/commands.py
> > +++ b/mercurial/commands.py
> > @@ -3911,12 +3911,13 @@
> >              # not ending up with the name of the bookmark because
> > of a race
> >              # condition on the server. (See issue 4689 for
> > details)
> >              remotebookmarks = other.listkeys('bookmarks')
> > +            remotebookmarks =
> > 

Re: [PATCH 2 of 2 STABLE] registrar: host "dynamicdefault" constant by configitem object

2017-10-23 Thread Boris Feld
On Sat, 2017-10-21 at 14:16 +0900, Yuya Nishihara wrote:
> # HG changeset patch
> # User Yuya Nishihara 
> # Date 1508559200 -32400
> #  Sat Oct 21 13:13:20 2017 +0900
> # Branch stable
> # Node ID dc05c59e3f1714c4faceb4c1eed66a5afe0ec000
> # Parent  3600f7eaed2124e575af498043c6401233b8b2ba
> registrar: host "dynamicdefault" constant by configitem object
> 
> This is the common pattern seen in the other registrar classes.

Ha good idea, importing the extra module was annoying. Thanks!
___
Mercurial-devel mailing list
Mercurial-devel@mercurial-scm.org
https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel