Re: [PATCH] chistedit: use magenta for current line as in crecord (issue6071)
test-check-code.t was unhappy with the line length, so I added break before "curses.color_pair()". On Thu, Feb 14, 2019 at 2:42 PM Martin von Zweigbergk wrote: > > On Wed, Feb 13, 2019 at 2:02 PM Jordi Gutiérrez Hermoso < > jord...@octave.org> wrote: > >> # HG changeset patch >> # User Jordi Gutiérrez Hermoso >> # Date 1550095104 18000 >> # Wed Feb 13 16:58:24 2019 -0500 >> # Node ID e31eb021571e1a6a63aab8090819184576236c58 >> # Parent 5d383d9636d0b81b416398913b32b8c715e98db5 >> chistedit: use magenta for current line as in crecord (issue6071) >> > > That looks much clearer. We have had a few users complain about this > internally after rolling out chistedit a few days ago. Queued, thanks. > ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
Re: [PATCH] chistedit: use magenta for current line as in crecord (issue6071)
On Wed, Feb 13, 2019 at 2:02 PM Jordi Gutiérrez Hermoso wrote: > # HG changeset patch > # User Jordi Gutiérrez Hermoso > # Date 1550095104 18000 > # Wed Feb 13 16:58:24 2019 -0500 > # Node ID e31eb021571e1a6a63aab8090819184576236c58 > # Parent 5d383d9636d0b81b416398913b32b8c715e98db5 > chistedit: use magenta for current line as in crecord (issue6071) > That looks much clearer. We have had a few users complain about this internally after rolling out chistedit a few days ago. Queued, thanks. ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5967: chistedit: improve proper username in histedit curses interfacein changeset section (issue6072)
akshjain.jain74 added a comment. okay , thanks @martinvonz REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5967 To: akshjain.jain74, durin42, #hg-reviewers, martinvonz Cc: martinvonz, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5967: chistedit: improve proper username in histedit curses interfacein changeset section (issue6072)
This revision was automatically updated to reflect the committed changes. Closed by commit rHGdf1f3ba56157: chistedit: improve proper username in histedit curses interface (authored by akshjain.jain74, committed by ). REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D5967?vs=14097=14098 REVISION DETAIL https://phab.mercurial-scm.org/D5967 AFFECTED FILES hgext/histedit.py CHANGE DETAILS diff --git a/hgext/histedit.py b/hgext/histedit.py --- a/hgext/histedit.py +++ b/hgext/histedit.py @@ -1260,7 +1260,7 @@ line = "changeset: {0}:{1:<12}".format(ctx.rev(), ctx) win.addstr(1, 1, line[:length]) -line = "user: {0}".format(stringutil.shortuser(ctx.user())) +line = "user: {0}".format(ctx.user()) win.addstr(2, 1, line[:length]) bms = repo.nodebookmarks(ctx.node()) To: akshjain.jain74, durin42, #hg-reviewers, martinvonz Cc: martinvonz, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5967: chistedit: improve proper username in histedit curses interfacein changeset section (issue6072)
martinvonz accepted this revision. martinvonz added a comment. This revision is now accepted and ready to land. Looks like there's plenty of space there to show the full username. I suspect it was the way it was because it came from FB where just the username is enough to identify people. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5967 To: akshjain.jain74, durin42, #hg-reviewers, martinvonz Cc: martinvonz, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5967: curses: improve proper username in histedit curses interfacein changeset section (issue6072)
akshjain.jain74 created this revision. Herald added a reviewer: durin42. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5967 AFFECTED FILES hgext/histedit.py CHANGE DETAILS diff --git a/hgext/histedit.py b/hgext/histedit.py --- a/hgext/histedit.py +++ b/hgext/histedit.py @@ -1246,7 +1246,7 @@ line = "changeset: {0}:{1:<12}".format(ctx.rev(), ctx) win.addstr(1, 1, line[:length]) -line = "user: {0}".format(stringutil.shortuser(ctx.user())) +line = "user: {0}".format(ctx.user()) win.addstr(2, 1, line[:length]) bms = repo.nodebookmarks(ctx.node()) To: akshjain.jain74, durin42, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
[Bug 6078] New: histedit fails with "abort: No module named _curses!"
https://bz.mercurial-scm.org/show_bug.cgi?id=6078 Bug ID: 6078 Summary: histedit fails with "abort: No module named _curses!" Product: Mercurial Version: 4.9 Hardware: PC OS: Windows Status: UNCONFIRMED Severity: bug Priority: wish Component: histedit Assignee: bugzi...@mercurial-scm.org Reporter: br...@vandyk.net.nz CC: mercurial-devel@mercurial-scm.org The histedit command is failing since I bumped to hg 4.9. If I downgrade to mercurial 4.8.2 the command runs without issue. STR: - run command `hg histedit`. - fails with "abort: No module named _curses!", no other output is produced. Further information: - Windows 10. - Running within a Mozilla Build env (https://wiki.mozilla.org/MozillaBuild). -- 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] crecord: remove obsolete version check
On Thu, Feb 14, 2019 at 6:48 PM Jordi Gutiérrez Hermoso wrote: > # HG changeset patch > # User Jordi Gutiérrez Hermoso > # Date 1550158907 18000 > # Thu Feb 14 10:41:47 2019 -0500 > # Node ID 9c5c236afcc631d0dfc6a3e1424e353f6c6c85bf > # Parent 5d383d9636d0b81b416398913b32b8c715e98db5 > crecord: remove obsolete version check > > An internal function shouldn't be checking compatibility with > Mercurial versions. > Queued this, many thanks! ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5940: uncommit: add -f/--force when possibly hiding data (issue5977)
navaneeth.suresh updated this revision to Diff 14096. navaneeth.suresh edited the summary of this revision. REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D5940?vs=14036=14096 REVISION DETAIL https://phab.mercurial-scm.org/D5940 AFFECTED FILES hgext/uncommit.py mercurial/rewriteutil.py tests/test-uncommit.t CHANGE DETAILS diff --git a/tests/test-uncommit.t b/tests/test-uncommit.t --- a/tests/test-uncommit.t +++ b/tests/test-uncommit.t @@ -35,6 +35,7 @@ options ([+] can be repeated): --keepallow an empty commit after uncommiting + -f --force allow uncommit with outstanding changes -I --include PATTERN [+] include names matching the given patterns -X --exclude PATTERN [+] exclude names matching the given patterns @@ -158,6 +159,9 @@ abort: uncommitted changes [255] $ hg uncommit files + abort: uncommitted changes + (use -f to force) + [255] $ cat files abcde foo @@ -170,14 +174,48 @@ abort: uncommitted changes [255] $ hg uncommit --config experimental.uncommitondirtywdir=True + abort: uncommitted changes + (use -f to force) + [255] $ hg commit -m "files abcde + foo" Uncommit in the middle of a stack, does not move bookmark $ hg checkout '.^^^' - 1 files updated, 0 files merged, 2 files removed, 0 files unresolved + 1 files updated, 0 files merged, 1 files removed, 0 files unresolved (leaving bookmark foo) $ hg log -r . -p -T '{rev}:{node} {desc}' + 3:6db330d65db434145c0b59d291853e9a84719b24 added file-abcddiff -r abf2df566fc1 -r 6db330d65db4 file-abcd + --- /dev/nullThu Jan 01 00:00:00 1970 + + +++ b/file-abcd Thu Jan 01 00:00:00 1970 + + @@ -0,0 +1,1 @@ + +abcd + diff -r abf2df566fc1 -r 6db330d65db4 files + --- a/files Thu Jan 01 00:00:00 1970 + + +++ b/files Thu Jan 01 00:00:00 1970 + + @@ -1,1 +1,1 @@ + -abc + +abcd + + $ hg bookmark + foo 9:ad3773de7293 + $ hg uncommit + 3 new orphan changesets + $ hg status + M files + A file-abcd + $ hg heads -T '{rev}:{node} {desc}' + 9:ad3773de72930be60f1ebb39fe89115b81630a8a files abcde + foo (no-eol) + $ hg bookmark + foo 9:ad3773de7293 + $ hg commit -m 'new abc' + created new head + +Partial uncommit in the middle, does not move bookmark + + $ hg checkout '.^' + 1 files updated, 0 files merged, 1 files removed, 0 files unresolved + $ hg log -r . -p -T '{rev}:{node} {desc}' 2:abf2df566fc193b3ac34d946e63c1583e4d4732b added file-abcdiff -r 69a232e754b0 -r abf2df566fc1 file-abc --- /dev/nullThu Jan 01 00:00:00 1970 + +++ b/file-abc Thu Jan 01 00:00:00 1970 + @@ -191,119 +229,85 @@ +abc $ hg bookmark - foo 10:48e5bd7cd583 - $ hg uncommit - 3 new orphan changesets + foo 9:ad3773de7293 + $ hg uncommit file-ab + nothing to uncommit + [1] $ hg status - M files - A file-abc - $ hg heads -T '{rev}:{node} {desc}' - 10:48e5bd7cd583eb24164ef8b89185819c84c96ed7 files abcde + foo (no-eol) - $ hg bookmark - foo 10:48e5bd7cd583 - $ hg commit -m 'new abc' - created new head - -Partial uncommit in the middle, does not move bookmark - - $ hg checkout '.^' - 1 files updated, 0 files merged, 1 files removed, 0 files unresolved - $ hg log -r . -p -T '{rev}:{node} {desc}' - 1:69a232e754b08d568c4899475faf2eb44b857802 added file-abdiff -r 3004d2d9b508 -r 69a232e754b0 file-ab - --- /dev/nullThu Jan 01 00:00:00 1970 + - +++ b/file-abThu Jan 01 00:00:00 1970 + - @@ -0,0 +1,1 @@ - +ab - diff -r 3004d2d9b508 -r 69a232e754b0 files - --- a/files Thu Jan 01 00:00:00 1970 + - +++ b/files Thu Jan 01 00:00:00 1970 + - @@ -1,1 +1,1 @@ - -a - +ab - - $ hg bookmark - foo 10:48e5bd7cd583 - $ hg uncommit file-ab - 1 new orphan changesets - $ hg status - A file-ab $ hg heads -T '{rev}:{node} {desc}\n' - 12:8eb87968f2edb7f27f27fe676316e179de65fff6 added file-ab - 11:5dc89ca4486f8a88716c5797fa9f498d13d7c2e1 new abc - 10:48e5bd7cd583eb24164ef8b89185819c84c96ed7 files abcde + foo + 10:25798b2f714d0937797be0f9fde55aaf5472c052 new abc + 9:ad3773de72930be60f1ebb39fe89115b81630a8a files abcde + foo $ hg bookmark - foo 10:48e5bd7cd583 + foo 9:ad3773de7293 $ hg commit -m 'update ab' + nothing changed + [1] $ hg status $ hg heads -T '{rev}:{node} {desc}\n' - 13:f21039c59242b085491bb58f591afc4ed1c04c09 update ab - 11:5dc89ca4486f8a88716c5797fa9f498d13d7c2e1 new abc - 10:48e5bd7cd583eb24164ef8b89185819c84c96ed7 files abcde + foo + 10:25798b2f714d0937797be0f9fde55aaf5472c052 new abc + 9:ad3773de72930be60f1ebb39fe89115b81630a8a files abcde + foo $ hg log -G -T '{rev}:{node} {desc}' --hidden - @ 13:f21039c59242b085491bb58f591afc4ed1c04c09 update ab +
D5965: test: stabilize test-run-tests.t output
lothiraldan abandoned this revision. lothiraldan added a comment. Replaced by https://phab.mercurial-scm.org/D5966 REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5965 To: lothiraldan, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
[PATCH] crecord: remove obsolete version check
# HG changeset patch # User Jordi Gutiérrez Hermoso # Date 1550158907 18000 # Thu Feb 14 10:41:47 2019 -0500 # Node ID 9c5c236afcc631d0dfc6a3e1424e353f6c6c85bf # Parent 5d383d9636d0b81b416398913b32b8c715e98db5 crecord: remove obsolete version check An internal function shouldn't be checking compatibility with Mercurial versions. diff --git a/mercurial/crecord.py b/mercurial/crecord.py --- a/mercurial/crecord.py +++ b/mercurial/crecord.py @@ -1546,14 +1546,7 @@ are you sure you want to review/edit and new changeset will be created (the normal commit behavior). """ -try: -ver = float(util.version()[:3]) -except ValueError: -ver = 1 -if ver < 2.19: -msg = _("The amend option is unavailable with hg versions < 2.2\n\n" -"Press any key to continue.") -elif opts.get('amend') is None: +if opts.get('amend') is None: opts['amend'] = True msg = _("Amend option is turned on -- committing the currently " "selected changes will not create a new changeset, but " ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5940: uncommit: add -f/--force when possibly hiding data (issue5977)
pulkit added a comment. In https://phab.mercurial-scm.org/D5940#87087, @navaneeth.suresh wrote: > In https://phab.mercurial-scm.org/D5940#87026, @pulkit wrote: > > > Hi, it will be good if you specify that the patch is authored by someone else, mention their name and also provide the link to the original PR of this patch. > > > @pulkit the link of WIP patch to evolve extension's uncommit is given in the bugzilla page itself. Link to the patch is https://bitbucket.org/octobus/evolve-devel/pull-requests/8/bug-5977-uncommit-dirtiness/diff which is authored by Dan Villiom Podlaski Christiansen. Yep, that's how I figured it out. ;) It's always good to include that information in commit message. Commit messages should try to explain all the things related to patch and should contain all the related links. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5940 To: navaneeth.suresh, #hg-reviewers Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5940: uncommit: add -f/--force when possibly hiding data (issue5977)
navaneeth.suresh added a comment. In https://phab.mercurial-scm.org/D5940#87026, @pulkit wrote: > Hi, it will be good if you specify that the patch is authored by someone else, mention their name and also provide the link to the original PR of this patch. @pulkit the link of WIP patch to evolve extension's uncommit is given in the bugzilla page itself. Link to the patch is https://bitbucket.org/octobus/evolve-devel/pull-requests/8/bug-5977-uncommit-dirtiness/diff which is authored by Dan Villiom Podlaski Christiansen. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5940 To: navaneeth.suresh, #hg-reviewers Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
Re: [PATCH V2] fix: change the default fix pattern (issue6077)
On Wed, 13 Feb 2019 17:54:18 -0500, Jordi Gutiérrez Hermoso wrote: > # HG changeset patch > # User Jordi Gutiérrez Hermoso > # Date 1550096863 18000 > # Wed Feb 13 17:27:43 2019 -0500 > # Node ID d8ba3b6466b220a5e04d07a5eccd3c1d45a2f501 > # Parent 5d383d9636d0b81b416398913b32b8c715e98db5 > fix: change the default fix pattern (issue6077) > > The matchutils functions don't know what to do with an empty pattern. > When a fixer doesn't have a pattern at all, a default of None will > make match functions unhappy and stack trace. > > Change this default instead to a pattern that matches everything. > > diff --git a/hgext/fix.py b/hgext/fix.py > --- a/hgext/fix.py > +++ b/hgext/fix.py > @@ -38,7 +38,8 @@ substituted into the command:: > > The :pattern suboption determines which files will be passed through each > configured tool. See :hg:`help patterns` for possible values. If there are > file > -arguments to :hg:`fix`, the intersection of these patterns is used. > +arguments to :hg:`fix`, the intersection of these patterns is used. If no > patterns > +are specified, the default is to apply the tool to all files. > > There is also a configurable limit for the maximum size of file that will be > processed by :hg:`fix`:: > @@ -122,7 +123,7 @@ FIXER_ATTRS = { > 'command': None, > 'linerange': None, > 'fileset': None, > -'pattern': None, > +'pattern': '.', Perhaps it would mean 'relpath:.' (any files under the current directory, not under the repository root.) I think it's better to either pass in an empty list to scmutil.match() or use scmutil.matchall() if _pattern is None. ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5966: test: stabilize test-run-tests.t output
lothiraldan created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY We have reached a point where the duration in JSON reports of `test-run-tests.t` were greater or equal than 10 seconds, which doesn't match anymore the regex. For example here: https://ci.octobus.net/blue/organizations/jenkins/MercurialPy2/detail/MercurialPy2/276/pipeline "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "10.040", "result": "skip", ? (re) Instead of accepting more characters, I changed the regex to accept any number of digits before the `.` then 3 or 4 digits after. This way the regex is more precise (only one `.` is authorized and we can ensure that the precision doesn't change). REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5966 AFFECTED FILES tests/test-run-tests.t CHANGE DETAILS diff --git a/tests/test-run-tests.t b/tests/test-run-tests.t --- a/tests/test-run-tests.t +++ b/tests/test-run-tests.t @@ -1174,31 +1174,31 @@ $ cat report.json testreport ={ "test-failure.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "---.+\+\+\+.+", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\s*\d+\.\d{3,4}", ? (re) "result": "failure", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\s*\d+\.\d{3,4}", ? (re) + "time": "\s*\d+\.\d{3,4}" (re) }, ? (re) "test-skip.t": { - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\s*\d+\.\d{3,4}", ? (re) "result": "skip", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\s*\d+\.\d{3,4}", ? (re) + "time": "\s*\d+\.\d{3,4}" (re) }, ? (re) "test-success.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\s*\d+\.\d{3,4}", ? (re) "result": "success", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\s*\d+\.\d{3,4}", ? (re) + "time": "\s*\d+\.\d{3,4}" (re) } } (no-eol) --json with --outputdir @@ -1231,31 +1231,31 @@ $ cat output/report.json testreport ={ "test-failure.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "---.+\+\+\+.+", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\s*\d+\.\d{3,4}", ? (re) "result": "failure", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\s*\d+\.\d{3,4}", ? (re) + "time": "\s*\d+\.\d{3,4}" (re) }, ? (re) "test-skip.t": { - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\s*\d+\.\d{3,4}", ? (re) "result": "skip", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\s*\d+\.\d{3,4}", ? (re) + "time": "\s*\d+\.\d{3,4}" (re) }, ? (re) "test-success.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\s*\d+\.\d{3,4}", ? (re) "result": "success", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\s*\d+\.\d{3,4}", ? (re) + "time": "\s*\d+\.\d{3,4}" (re) } } (no-eol) $ ls -a output @@ -1287,31 +1287,31 @@ $ cat report.json testreport ={ "test-failure.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\s*\d+\.\d{3,4}", ? (re) + "cuser": "\s*\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re)
D5965: test: stabilize test-run-tests.t output
lothiraldan created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY We have reached a point where the duration in `test-run-tests.t` were greater or equal than 10s, which doesn't match anymore the regex. For example here: https://ci.octobus.net/blue/organizations/jenkins/MercurialPy2/detail/MercurialPy2/276/pipeline "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "10.040", "result": "skip", ? (re) Instead of accepting more characters, I changed the regex to accept any number of digits before the `.` than 3 or 4 digits after. This way the regex is more precise (only one `.` is authorized and we can ensure that the precision doesn't change). REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5965 AFFECTED FILES tests/test-run-tests.t CHANGE DETAILS diff --git a/tests/test-run-tests.t b/tests/test-run-tests.t --- a/tests/test-run-tests.t +++ b/tests/test-run-tests.t @@ -1174,31 +1174,31 @@ $ cat report.json testreport ={ "test-failure.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "---.+\+\+\+.+", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "failure", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\d+\.\d{3,4}", ? (re) + "time": "\d+\.\d{3,4}" (re) }, ? (re) "test-skip.t": { - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "skip", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\d+\.\d{3,4}", ? (re) + "time": "\d+\.\d{3,4}" (re) }, ? (re) "test-success.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "success", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\d+\.\d{3,4}", ? (re) + "time": "\d+\.\d{3,4}" (re) } } (no-eol) --json with --outputdir @@ -1231,31 +1231,31 @@ $ cat output/report.json testreport ={ "test-failure.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "---.+\+\+\+.+", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "failure", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\d+\.\d{3,4}", ? (re) + "time": "\d+\.\d{3,4}" (re) }, ? (re) "test-skip.t": { - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "skip", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\d+\.\d{3,4}", ? (re) + "time": "\d+\.\d{3,4}" (re) }, ? (re) "test-success.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "success", ? (re) - "start": "\s*[\d\.]{4,5}", ? (re) - "time": "\s*[\d\.]{4,5}" (re) + "start": "\d+\.\d{3,4}", ? (re) + "time": "\d+\.\d{3,4}" (re) } } (no-eol) $ ls -a output @@ -1287,31 +1287,31 @@ $ cat report.json testreport ={ "test-failure.t": [\{] (re) - "csys": "\s*[\d\.]{4,5}", ? (re) - "cuser": "\s*[\d\.]{4,5}", ? (re) + "csys": "\d+\.\d{3,4}", ? (re) + "cuser": "\d+\.\d{3,4}", ? (re) "diff": "", ? (re) - "end": "\s*[\d\.]{4,5}", ? (re) + "end": "\d+\.\d{3,4}", ? (re) "result": "success", ? (re) - "start": "\s*[\d\.]{4,5}", ?
D5963: copies: handle the case when both merging csets are not descendant of merge base
khanchi97 added inline comments. INLINE COMMENTS > copies.py:571 > + copy, bothdiverge, bothincompletediverge) > +remainder.update(remainder1) > +elif dirtyc1: I am not sure if combining of partial copies in this case is correct or not. But I did combine these to do the similar behaviour as we are doing at other places. I don't have much knowledge about partial copies :/ REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5963 To: khanchi97, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5964: copies: return True instead of filename as it is expected to return boolean
khanchi97 created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY As the function documentation says this function should True if we hit a match and False otherwise. And I see that we are not using that returned filename anywhere. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5964 AFFECTED FILES mercurial/copies.py CHANGE DETAILS diff --git a/mercurial/copies.py b/mercurial/copies.py --- a/mercurial/copies.py +++ b/mercurial/copies.py @@ -776,7 +776,7 @@ """ if f1 == f2: -return f1 # a match +return True # a match g1, g2 = f1.ancestors(), f2.ancestors() try: To: khanchi97, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5963: copies: handle the case when both merging csets are not descendant of merge base
khanchi97 created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY Previous discussion on this issue can be found at this link: https://phab.mercurial-scm.org/D3896 Copying description from previous patch sent by Pulkit: There can be cases when both the changesets which we are merging are not descendants of the merge base. In those cases dirtyc1 and dirtyc2 both will be true. The existing code assumes that either of them will be true always but that is not a right assumption. Pulkit found this while working with content-divergence resolution. In content-divergence resolution, we use the common predecessor as the merge base for resolving content divergence and there it can be possible that the merge base is not the descendant of both the content-divergence changsets. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5963 AFFECTED FILES mercurial/copies.py tests/test-copytrace-heuristics.t CHANGE DETAILS diff --git a/tests/test-copytrace-heuristics.t b/tests/test-copytrace-heuristics.t --- a/tests/test-copytrace-heuristics.t +++ b/tests/test-copytrace-heuristics.t @@ -930,51 +930,28 @@ $ hg graft -r 6 --base c9241b0f2d5b --hidden grafting 6:99802e4f1e46 "added willconflict and d" (tip) - ** unknown exception encountered, please report by visiting - ** https://mercurial-scm.org/wiki/BugTracker - ** Python 2.7.12 (default, Nov 12 2018, 14:36:49) [GCC 5.4.0 20160609] - ** Mercurial Distributed SCM (version 4.8.1+539-b6c610bf567e+20181221) - ** Extensions loaded: rebase, shelve - Traceback (most recent call last): -File "/home/khanchi/hg/hg-committed/hg", line 43, in - dispatch.run() -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 99, in run - status = dispatch(req) -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 225, in dispatch - ret = _runcatch(req) or 0 -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 376, in _runcatch - return _callcatch(ui, _runcatchfunc) -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 384, in _callcatch - return scmutil.callcatch(ui, func) -File "/home/khanchi/hg/hg-committed/mercurial/scmutil.py", line 165, in callcatch - return func() -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 367, in _runcatchfunc - return _dispatch(req) -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 1021, in _dispatch - cmdpats, cmdoptions) -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 756, in runcommand - ret = _runcommand(ui, options, cmd, d) -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 1030, in _runcommand - return cmdfunc() -File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 1018, in - d = lambda: util.checksignature(func)(ui, *args, **strcmdopt) -File "/home/khanchi/hg/hg-committed/mercurial/util.py", line 1676, in check - return func(*args, **kwargs) -File "/home/khanchi/hg/hg-committed/mercurial/commands.py", line 2378, in graft - return _dograft(ui, repo, *revs, **opts) -File "/home/khanchi/hg/hg-committed/mercurial/commands.py", line 2590, in _dograft - stats = mergemod.graft(repo, ctx, base, ['local', 'graft']) -File "/home/khanchi/hg/hg-committed/mercurial/merge.py", line 2234, in graft - mergeancestor=mergeancestor, labels=labels) -File "/home/khanchi/hg/hg-committed/mercurial/merge.py", line 2075, in update - followcopies, matcher=matcher, mergeforce=mergeforce) -File "/home/khanchi/hg/hg-committed/mercurial/merge.py", line 1342, in calculateupdates - acceptremote, followcopies) -File "/home/khanchi/hg/hg-committed/mercurial/merge.py", line 1146, in manifestmerge - ret = copies.mergecopies(repo, wctx, p2, pa) -File "/home/khanchi/hg/hg-committed/mercurial/copies.py", line 416, in mergecopies - return _fullcopytracing(repo, c1, c2, base) -File "/home/khanchi/hg/hg-committed/mercurial/copies.py", line 568, in _fullcopytracing - assert not both2['incomplete'] - AssertionError - [1] + merging willconflict + warning: conflicts while merging willconflict! (edit, then use 'hg resolve --mark') + abort: unresolved conflicts, can't continue + (use 'hg resolve' and 'hg graft --continue') + [255] + + $ hg diff + diff -r 9a8bb7cc6814 willconflict + --- a/willconflict Thu Jan 01 00:00:00 1970 + + +++ b/willconflict Thu Jan 01 00:00:00 1970 + + @@ -1,1 +1,5 @@ + +<<< local: 9a8bb7cc6814 - test: added c + foobar + +=== + +barfoo + +>>> graft: 99802e4f1e46 - test: added willconflict and d + + $ echo barfoo > willconflict + $ hg resolve -m + (no more unresolved files) + continue: hg graft --continue + $ hg graft --continue + grafting 6:99802e4f1e46 "added
D5962: copies: add test that makes both the merging csets dirty and fails
khanchi97 created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY Discussion related to this issue can be found here: https://phab.mercurial-scm.org/D3896 There can be cases when both the changesets which we are merging are not descendants of the merge base. In those cases dirtyc1 and dirtyc2 both will be true. The existing code assumes that either of them will be true always but that is not a right assumption. Pulkit found this while working with content-divergence resolution. In content-divergence resolution, we use the common predecessor as the merge base for resolving content divergence and there it can be possible that the merge base is not the descendant of both the content-divergence changsets. Added tests reflects the broken behaviour for the above mentioned case. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5962 AFFECTED FILES tests/test-copytrace-heuristics.t CHANGE DETAILS diff --git a/tests/test-copytrace-heuristics.t b/tests/test-copytrace-heuristics.t --- a/tests/test-copytrace-heuristics.t +++ b/tests/test-copytrace-heuristics.t @@ -825,3 +825,156 @@ $ cd .. $ rm -rf repo +Test which demonstrate that fullcopytracing algorithm can fail to handle a case when both the csets are dirty +-- + + $ hg init repo + $ cd repo + $ echo a > a + $ hg add a + $ hg ci -m "added a" + $ echo b > b + $ hg add b + $ hg ci -m "added b" + + $ echo foobar > willconflict + $ hg add willconflict + $ hg ci -m "added willconflict" + $ echo c > c + $ hg add c + $ hg ci -m "added c" + + $ hg log -G -T '{rev} : {node|short} {desc} \n{phase}\n' + @ 3 : 9a8bb7cc6814 added c + | draft + o 2 : d2ea38baf44e added willconflict + | draft + o 1 : 5f6d8a4bf34a added b + | draft + o 0 : 9092f1db7931 added a + draft + + $ hg up .^^ + 0 files updated, 0 files merged, 2 files removed, 0 files unresolved + $ echo d > d + $ hg add d + $ hg ci -m "added d" + created new head + + $ echo barfoo > willconflict + $ hg add willconflict + $ hg ci --amend -m "added willconflict and d" + + $ hg log -G -T '{rev} : {node|short} {desc} \n{phase}\n' + @ 5 : 5018b1509e94 added willconflict and d + | draft + | o 3 : 9a8bb7cc6814 added c + | | draft + | o 2 : d2ea38baf44e added willconflict + |/ draft + o 1 : 5f6d8a4bf34a added b + | draft + o 0 : 9092f1db7931 added a + draft + + $ hg rebase -r . -d 2 + rebasing 5:5018b1509e94 "added willconflict and d" (tip) + merging willconflict + warning: conflicts while merging willconflict! (edit, then use 'hg resolve --mark') + unresolved conflicts (see hg resolve, then hg rebase --continue) + [1] + + $ hg diff + diff -r d2ea38baf44e d + --- /dev/nullThu Jan 01 00:00:00 1970 + + +++ b/d Thu Jan 01 00:00:00 1970 + + @@ -0,0 +1,1 @@ + +d + diff -r d2ea38baf44e willconflict + --- a/willconflict Thu Jan 01 00:00:00 1970 + + +++ b/willconflict Thu Jan 01 00:00:00 1970 + + @@ -1,1 +1,5 @@ + +<<< dest: d2ea38baf44e - test: added willconflict + foobar + +=== + +barfoo + +>>> source: 5018b1509e94 - test: added willconflict and d + + $ echo barfoo > willconflict + $ hg resolve -m + (no more unresolved files) + continue: hg rebase --continue + $ hg rebase --continue + rebasing 5:5018b1509e94 "added willconflict and d" (tip) + + $ hg up 3 -q + + $ hg log -G --hidden -T '{rev} : {node|short} {desc} \n{phase}\n' + o 6 : 99802e4f1e46 added willconflict and d + | draft + | x 5 : 5018b1509e94 added willconflict and d + | | draft + | | x 4 : c9241b0f2d5b added d + | |/ draft + +---@ 3 : 9a8bb7cc6814 added c + | |draft + o | 2 : d2ea38baf44e added willconflict + |/ draft + o 1 : 5f6d8a4bf34a added b + | draft + o 0 : 9092f1db7931 added a + draft + +Now if we trigger a merge between cset revision 3 and 6 using base revision 4, in this case +both the merging csets will be dirty as no one is descendent of base revision: + + $ hg graft -r 6 --base c9241b0f2d5b --hidden + grafting 6:99802e4f1e46 "added willconflict and d" (tip) + ** unknown exception encountered, please report by visiting + ** https://mercurial-scm.org/wiki/BugTracker + ** Python 2.7.12 (default, Nov 12 2018, 14:36:49) [GCC 5.4.0 20160609] + ** Mercurial Distributed SCM (version 4.8.1+539-b6c610bf567e+20181221) + ** Extensions loaded: rebase, shelve + Traceback (most recent call last): +File "/home/khanchi/hg/hg-committed/hg", line 43, in + dispatch.run() +File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 99, in run + status = dispatch(req) +File "/home/khanchi/hg/hg-committed/mercurial/dispatch.py", line 225, in dispatch + ret = _runcatch(req) or 0 +
Re: [PATCH] histedit: remove "chistedit" mention from interface
On Thu, Feb 14, 2019 at 12:05 AM Jordi Gutiérrez Hermoso wrote: > # HG changeset patch > # User Jordi Gutiérrez Hermoso > # Date 1550091764 18000 > # Wed Feb 13 16:02:44 2019 -0500 > # Node ID 94ccf890584ee3bae9e543fade578e0f05281347 > # Parent 5d383d9636d0b81b416398913b32b8c715e98db5 > histedit: remove "chistedit" mention from interface > > "chisted" is internal jargon. The end user should not need to be aware > that it's different from histedit. > Queued this, many thanks! ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5961: copies: add test that makes both the merging csets dirty and run w/o error
khanchi97 created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY Adding a test for fullcopytracing algorithm where both the merging csets are dirty, which means no cset is descendant of merging base. This test shows that for this particular case fullcopytracing algorithm worked and found the copies. But there are the cases when the algorithm can fail to handle this "both dirty" case and errors. Next couple of csets will add those test cases when it fails and fix for the same. Previous patch sent by Pulkit on the same issue is here: https://phab.mercurial-scm.org/D3896 REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5961 AFFECTED FILES tests/test-copytrace-heuristics.t CHANGE DETAILS diff --git a/tests/test-copytrace-heuristics.t b/tests/test-copytrace-heuristics.t --- a/tests/test-copytrace-heuristics.t +++ b/tests/test-copytrace-heuristics.t @@ -716,3 +716,112 @@ saved backup bundle to $TESTTMP/repo/repo/repo/.hg/strip-backup/8b6e13696c38-fc14ac83-rebase.hg $ cd .. $ rm -rf repo + +Test for a in fullcopytracing algorithm where both the merging csets are dirty +which means no cset is descendant of merging base. This test reflect that +for this particular case this algorithm correctly find the copies: + + $ cat >> $HGRCPATH << EOF + > [experimental] + > evolution.createmarkers=True + > evolution.allowunstable=True + > EOF + + $ hg init repo + $ cd repo + $ echo a > a + $ hg add a + $ hg ci -m "added a" + $ echo b > b + $ hg add b + $ hg ci -m "added b" + + $ hg mv b b1 + $ hg ci -m "rename b to b1" + + $ hg up .^ + 1 files updated, 0 files merged, 1 files removed, 0 files unresolved + $ echo d > d + $ hg add d + $ hg ci -m "added d" + created new head + + $ echo baba >> b + $ hg ci --amend -m "added d" + + $ hg log --git -pG --hidden -T "{rev}: {node|short} {desc}\n {phase} \n\n" + @ 4: d70f3e12cfd9 added d + | draft + | + | diff --git a/b b/b + | --- a/b + | +++ b/b + | @@ -1,1 +1,2 @@ + | b + | +baba + | diff --git a/d b/d + | new file mode 100644 + | --- /dev/null + | +++ b/d + | @@ -0,0 +1,1 @@ + | +d + | + | x 3: c9241b0f2d5b added d + |/draft + | + |diff --git a/d b/d + |new file mode 100644 + |--- /dev/null + |+++ b/d + |@@ -0,0 +1,1 @@ + |+d + | + | o 2: 5a4825cc2926 rename b to b1 + |/draft + | + |diff --git a/b b/b1 + |rename from b + |rename to b1 + | + o 1: 5f6d8a4bf34a added b + | draft + | + | diff --git a/b b/b + | new file mode 100644 + | --- /dev/null + | +++ b/b + | @@ -0,0 +1,1 @@ + | +b + | + o 0: 9092f1db7931 added a + draft + + diff --git a/a b/a + new file mode 100644 + --- /dev/null + +++ b/a + @@ -0,0 +1,1 @@ + +a + + +Grafting revision 4 on top of revision 2, showing that it respect the rename: + + $ hg up 2 -q + $ hg graft -r 4 --base c9241b0f2d5b --hidden + grafting 4:d70f3e12cfd9 "added d" (tip) + merging b1 and b to b1 + + $ hg log --git -pG -l 1 -T "{rev}: {node|short} {desc}\n {phase} \n\n" + @ 5: 54ee32fbd09a added d + | draft + ~ + diff --git a/b1 b/b1 + --- a/b1 + +++ b/b1 + @@ -1,1 +1,2 @@ + b + +baba + + $ cd .. + $ rm -rf repo + To: khanchi97, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5960: test: stabilize test-remotefilelog-bgprefetch.t flaky output
lothiraldan created this revision. Herald added a subscriber: mercurial-devel. Herald added a reviewer: hg-reviewers. REVISION SUMMARY When running the test suite with multiple processes, we often get flaky outputs, like here: https://ci.octobus.net/job/MercurialPy2/274/console - $TESTTMP/hgcache/master/packs/8f1443d44e57fec96f72fb2412e01d2818767ef2.histidx - $TESTTMP/hgcache/master/packs/8f1443d44e57fec96f72fb2412e01d2818767ef2.histpack - $TESTTMP/hgcache/master/packs/f4d50848e0b465e9bfd2875f213044c06cfd7407.dataidx - $TESTTMP/hgcache/master/packs/f4d50848e0b465e9bfd2875f213044c06cfd7407.datapack + $TESTTMP/hgcache/master/11/f6ad8ec52a2984abaafd7c3b516503785c2072/1406e74118627694268417491f018a4a883152f0 + $TESTTMP/hgcache/master/11/f6ad8ec52a2984abaafd7c3b516503785c2072/ef95c5376f34698742fe34f315fd82136f8f68c0 + $TESTTMP/hgcache/master/39/5df8f7c51f007019cb30201c49e884b46b92fa/69a1b67522704ec122181c0890bd16e9d3e7516a + $TESTTMP/hgcache/master/95/cb0bfd2977c761298d9624e4b4d4c72a39974a/076f5e2225b3ff0400b98c92aa6cdf403ee24cca + $TESTTMP/hgcache/master/af/f024fe4ab0fece4091de044c58c9ae4233383a/bb6ccd5dceaa5e9dc220e0dad65e051b94f69a2c Add some sleeps after `debugwaitonrepack` calls as it seems it needs some extra time to cleanup. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5960 AFFECTED FILES tests/test-remotefilelog-bgprefetch.t CHANGE DETAILS diff --git a/tests/test-remotefilelog-bgprefetch.t b/tests/test-remotefilelog-bgprefetch.t --- a/tests/test-remotefilelog-bgprefetch.t +++ b/tests/test-remotefilelog-bgprefetch.t @@ -105,6 +105,7 @@ $ hg debugwaitonprefetch >/dev/null 2>%1 $ sleep 0.5 $ hg debugwaitonrepack >/dev/null 2>%1 + $ sleep 0.5 $ find $CACHEDIR -type f | sort $TESTTMP/hgcache/master/packs/6e8633deba6e544e5f8edbd7b996d6e31a2c42ae.histidx $TESTTMP/hgcache/master/packs/6e8633deba6e544e5f8edbd7b996d6e31a2c42ae.histpack @@ -193,6 +194,7 @@ $ hg debugwaitonprefetch >/dev/null 2>%1 $ sleep 1 $ hg debugwaitonrepack >/dev/null 2>%1 + $ sleep 1 $ find $CACHEDIR -type f | sort $TESTTMP/hgcache/master/packs/8f1443d44e57fec96f72fb2412e01d2818767ef2.histidx $TESTTMP/hgcache/master/packs/8f1443d44e57fec96f72fb2412e01d2818767ef2.histpack @@ -243,6 +245,7 @@ $ hg debugwaitonprefetch >/dev/null 2>%1 $ sleep 1 $ hg debugwaitonrepack >/dev/null 2>%1 + $ sleep 1 # Ensure that file 'y' was prefetched - it was not part of the rebase operation and therefore # could only be downloaded by the background prefetch To: lothiraldan, #hg-reviewers Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
Re: [PATCH 3 of 4 V2] changelog: prefilter in headrevs()
On 2/13/19 2:18 PM, Yuya Nishihara wrote: > On Wed, 13 Feb 2019 12:47:56 +0100, Georges Racinet wrote: >> # HG changeset patch >> # User Georges Racinet >> # Date 1547815081 -3600 >> # Fri Jan 18 13:38:01 2019 +0100 >> # Node ID eae29e210636ee44851e0caa385097a090c60af8 >> # Parent 956c5b54b4ce3e8decf5243a7f73c6f9a06f1229 >> # EXP-Topic revset.predicates >> changelog: prefilter in headrevs() > Queued the first two patches, thanks. > >> +def _checknofilteredgenrevs(self, revs): >> +"""rewrap 'revs' generator to include check for filtered revisions >> + >> +This does not consume the incoming generator. >> +""" >> +filteredrevs = self.filteredrevs >> +for r in revs: >> +if r in filteredrevs: >> +raise error.FilteredIndexError(r) >> +yield r >> + >> +def _checknofilteredinrevs(self, revs): >> +"""raise the appropriate error if 'revs' contains a filtered >> revision >> + >> +This returns a version of 'revs' to be used by the caller, that >> works >> +for all cases, including lazy ones >> +""" >> +safehasattr = util.safehasattr >> +if safehasattr(revs, '__next__'): >> +# Note that inspect.isgenerator() is not true for iterators, >> +# and that calling even implicitely iter() on a iterator does >> not >> +# clone it >> +return self._checknofilteredgenrevs(revs) >> + >> +filteredrevs = self.filteredrevs >> +if safehasattr(revs, 'first'): # smartset >> +offenders = revs & filteredrevs >> +else: >> +offenders = filteredrevs.intersection(revs) >> + >> +for rev in offenders: >> +raise error.FilteredIndexError(rev) >> +return revs > Do we need this complexity to handle various types of 'revs' differently? > > IIUC, revlog.headrevs(revs) is just forwarded to dagop.headrevs(revs), where > 'revs' is first converted to a set, and then iterated. Which means 'revs' > can't be an iterator, and the order doesn't basically matter. So to rephrase you're saying that no caller will ever expect an iterator not to be consumed by calling headrevs() on it, due to filtering, because that's what happens anyway, even without any filtering. That's right indeed, I've been overprotective on that one. I'll make a v3 for this patch and its successor, thanks for the review and the queueing ! Note: I'll be offline until the 20th, not sure I can make the v3 before that. ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5941: tweakdefault: Add better documentation for ui.tweakdefault(issue6000)
akshjain.jain74 added a comment. okay REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5941 To: akshjain.jain74, #hg-reviewers, pulkit Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5941: tweakdefault: Add better documentation for ui.tweakdefault(issue6000)
pulkit requested changes to this revision. pulkit added a comment. This revision now requires changes to proceed. In https://phab.mercurial-scm.org/D5941#87025, @akshjain.jain74 wrote: > @pulkit like what else we required to improve the documentation for the issue , in general what tweakdefault do for mercurial is already mention in the issue 樂 As commented on the issue, I don't think we need anything more. (Marking this as Request Changes to move it out of review list) REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5941 To: akshjain.jain74, #hg-reviewers, pulkit Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5940: uncommit: add -f/--force when possibly hiding data (issue5977)
pulkit added a comment. Hi, it will be good if you specify that the patch is authored by someone else, mention their name and also provide the link to the original PR of this patch. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5940 To: navaneeth.suresh, #hg-reviewers Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5941: tweakdefault: Add better documentation for ui.tweakdefault(issue6000)
akshjain.jain74 added a comment. @pulkit like what else we required to improve the documentation for the issue , in general what tweakdefault do for mercurial is already mention in the issue 樂 REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5941 To: akshjain.jain74, #hg-reviewers Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5941: tweakdefault: Add better documentation for ui.tweakdefault(issue6000)
pulkit added a comment. Hi, thanks for the patch. This is adding just un required churn to help text. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5941 To: akshjain.jain74, #hg-reviewers Cc: pulkit, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5953: revset: improve documentation on expectsize()
This revision was automatically updated to reflect the committed changes. Closed by commit rHG735da363556d: revset: improve documentation on expectsize() (authored by navaneeth.suresh, committed by ). CHANGED PRIOR TO COMMIT https://phab.mercurial-scm.org/D5953?vs=14068=14087#toc REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D5953?vs=14068=14087 REVISION DETAIL https://phab.mercurial-scm.org/D5953 AFFECTED FILES mercurial/revset.py CHANGE DETAILS diff --git a/mercurial/revset.py b/mercurial/revset.py --- a/mercurial/revset.py +++ b/mercurial/revset.py @@ -863,7 +863,13 @@ @predicate('expectsize(set[, size])', safe=True, takeorder=True) def expectsize(repo, subset, x, order): -"""Abort if the revset doesn't expect given size""" +"""Return the given revset if size matches the revset size. +Abort if the revset doesn't expect given size. +size can either be an integer range or an integer. + +For example, ``expectsize(0:1, 3:5)`` will abort as revset size is 2 and +2 is not between 3 and 5 inclusive.""" + args = getargsdict(x, 'expectsize', 'set size') minsize = 0 maxsize = len(repo) + 1 To: navaneeth.suresh, #hg-reviewers, pulkit Cc: mjpieters, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5956: scmutil: fix a comment that doesn't match the code
This revision was automatically updated to reflect the committed changes. Closed by commit rHG879495c68e31: scmutil: fix a comment that doesnt match the code (authored by martinvonz, committed by ). REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D5956?vs=14080=14086 REVISION DETAIL https://phab.mercurial-scm.org/D5956 AFFECTED FILES mercurial/scmutil.py CHANGE DETAILS diff --git a/mercurial/scmutil.py b/mercurial/scmutil.py --- a/mercurial/scmutil.py +++ b/mercurial/scmutil.py @@ -1123,7 +1123,7 @@ repo.ui.status(status) # TODO: We should probably have the caller pass in uipathfn and apply it to -# the messages above too. forcerelativevalue=True is consistent with how +# the messages above too. legacyrelativevalue=True is consistent with how # it used to work. uipathfn = getuipathfn(repo, legacyrelativevalue=True) renames = _findrenames(repo, m, added + unknown, removed + deleted, To: martinvonz, #hg-reviewers, pulkit Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5958: remotefilelog: remove strkwargs()
This revision was automatically updated to reflect the committed changes. Closed by commit rHG4eeed5eac0f4: remotefilelog: remove strkwargs() (authored by indygreg, committed by ). REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D5958?vs=14082=14085 REVISION DETAIL https://phab.mercurial-scm.org/D5958 AFFECTED FILES hgext/remotefilelog/remotefilectx.py CHANGE DETAILS diff --git a/hgext/remotefilelog/remotefilectx.py b/hgext/remotefilelog/remotefilectx.py --- a/hgext/remotefilelog/remotefilectx.py +++ b/hgext/remotefilelog/remotefilectx.py @@ -316,7 +316,7 @@ finally: elapsed = time.time() - start repo.ui.log('linkrevfixup', logmsg + '\n', elapsed=elapsed * 1000, -**pycompat.strkwargs(commonlogkwargs)) +**commonlogkwargs) def _verifylinknode(self, revs, linknode): """ To: indygreg, #hg-reviewers, pulkit Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5957: remotefilelog: use raw strings when looking for variable names
This revision was automatically updated to reflect the committed changes. Closed by commit rHGe37bd7ccfee3: remotefilelog: use raw strings when looking for variable names (authored by indygreg, committed by ). REPOSITORY rHG Mercurial CHANGES SINCE LAST UPDATE https://phab.mercurial-scm.org/D5957?vs=14081=14084 REVISION DETAIL https://phab.mercurial-scm.org/D5957 AFFECTED FILES hgext/remotefilelog/remotefilectx.py CHANGE DETAILS diff --git a/hgext/remotefilelog/remotefilectx.py b/hgext/remotefilelog/remotefilectx.py --- a/hgext/remotefilelog/remotefilectx.py +++ b/hgext/remotefilelog/remotefilectx.py @@ -39,11 +39,11 @@ @propertycache def _changeid(self): -if '_changeid' in self.__dict__: +if r'_changeid' in self.__dict__: return self._changeid -elif '_changectx' in self.__dict__: +elif r'_changectx' in self.__dict__: return self._changectx.rev() -elif '_descendantrev' in self.__dict__: +elif r'_descendantrev' in self.__dict__: # this file context was created from a revision with a known # descendant, we can (lazily) correct for linkrev aliases linknode = self._adjustlinknode(self._path, self._filelog, @@ -102,7 +102,7 @@ """ lkr = self.linkrev() attrs = vars(self) -noctx = not ('_changeid' in attrs or '_changectx' in attrs) +noctx = not (r'_changeid' in attrs or r'_changectx' in attrs) if noctx or self.rev() == lkr: return lkr linknode = self._adjustlinknode(self._path, self._filelog, To: indygreg, #hg-reviewers, pulkit Cc: mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
D5792: uncommit: added interactive mode(issue6062)
pulkit added a comment. The import looks fine to me. I will let someone else review the code because I authored this code in first place in evolve extension. Also it will be nice if you specify that the code is imported from evolve extension and also specify the commit hash from which you imported. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5792 To: taapas1128, #hg-reviewers Cc: pulkit, lothiraldan, mercurial-devel ___ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel