Thu, 10 Sep 2020 22:00:00 -0700 templater: fix reading of templates in frozen binaries with py3 < 3.7
Martin von Zweigbergk <martinvonz@google.com> [Thu, 10 Sep 2020 22:00:00 -0700] rev 45451
templater: fix reading of templates in frozen binaries with py3 < 3.7 When using a frozen binary with py3 < 3.7, there's no `importlib.resources` module, so we use the code path that reads the resources from the file system. That code path expects bytes for package name and resource name. Differential Revision: https://phab.mercurial-scm.org/D9008
Fri, 11 Sep 2020 09:35:49 -0700 histedit: cache description line
Martin von Zweigbergk <martinvonz@google.com> [Fri, 11 Sep 2020 09:35:49 -0700] rev 45450
histedit: cache description line Navigating the curses-based histedit interface can be pretty slow because it redraws everything whenever you make a change. This patch simply replaces `@property` by `@util.propertycache` on the `histeditrule.desc()` function so it's not re-calculated every time the screen needs to be re-rendered. I timed it on an example of 30 simple commits, where I moved the top commit down 25 steps and then up 25 steps after. Before this patch, that (the whole `hg histedit` invocation) took 11.6 s of CPU and after this patch it took 0.8 s). Differential Revision: https://phab.mercurial-scm.org/D9016
Fri, 11 Sep 2020 09:55:08 -0700 tests: make emacs test less strict
Martin von Zweigbergk <martinvonz@google.com> [Fri, 11 Sep 2020 09:55:08 -0700] rev 45449
tests: make emacs test less strict It was failing like this for me: ``` @@ -2,7 +2,7 @@ $ emacs -q -no-site-file -batch -l $TESTDIR/../contrib/hg-test-mode.el \ > -f ert-run-tests-batch-and-exit Running 1 tests (*) (glob) - passed 1/1 hg-test-mode--compilation-mode-support + passed 1/1 hg-test-mode--compilation-mode-support (0.045732 sec) - Ran 1 tests, 1 results as expected (*) (glob) + Ran 1 tests, 1 results as expected, 0 unexpected (2020-09-11 16:49:56+0000, 0.046034 sec) ``` Differential Revision: https://phab.mercurial-scm.org/D9017
Thu, 10 Sep 2020 13:12:34 -0700 graphlog: use '%' only if there are *unresolved* conflicts
Martin von Zweigbergk <martinvonz@google.com> [Thu, 10 Sep 2020 13:12:34 -0700] rev 45448
graphlog: use '%' only if there are *unresolved* conflicts In 14d0e89520a2, I made graphlog use '%' for the "other" context when there's an existing merge state. However, that has confused many people because it shows up even if all conflicts are already resolved, which makes it show up even after e.g. `hg update -m` with automatically resolved conflicts. This patch makes it so we show the '%' only if there still unresolved conflicts. This patch replaces my earlier attempt in D8930, where I decided to automatically clear the mergestate if there are no remaining conflicts. That had the problem that it wouldn't let the user re-resolve the conflicts using `hg resolve`. Note that an in-progress "proper" merge (one that will result in a commit with two parents, such as after `hg merge`) will already have two dirstate parents before the commit happens. That means that both sides of the merge will get drawn as '@' in the graph, since "is dirstate parent" takes precedence over "is involved in merge conflict". Differential Revision: https://phab.mercurial-scm.org/D9007
Wed, 26 Aug 2020 17:24:22 +0530 merge: show number of ancestors in bid merge debug notes
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 26 Aug 2020 17:24:22 +0530] rev 45447
merge: show number of ancestors in bid merge debug notes A good number of times, we don't generate an action for a file in manifestmerge() which can result in bid merge doing the wrong thing. Mentioning the number of ancestors from which we are bidding will help spot such cases where we are not returning an action. Differential Revision: https://phab.mercurial-scm.org/D8967
Thu, 03 Sep 2020 14:45:16 +0530 debugmergestate: sort extras before printing
Pulkit Goyal <7895pulkit@gmail.com> [Thu, 03 Sep 2020 14:45:16 +0530] rev 45446
debugmergestate: sort extras before printing Prevents flaky output. Differential Revision: https://phab.mercurial-scm.org/D8986
Mon, 24 Aug 2020 18:59:19 +0530 debugmergestate: show extras for files which are not in mergestate
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 24 Aug 2020 18:59:19 +0530] rev 45445
debugmergestate: show extras for files which are not in mergestate With recent changes and future changes, we will like to store extras information about files which were merged automatically. Hence, we will have merge extras for files which are not in the mergestate. Differential Revision: https://phab.mercurial-scm.org/D8942
Thu, 10 Sep 2020 16:51:40 +0530 tests: update lockdelay.py to handle the `wait` argument
Pulkit Goyal <7895pulkit@gmail.com> [Thu, 10 Sep 2020 16:51:40 +0530] rev 45444
tests: update lockdelay.py to handle the `wait` argument Spotted by a future change.
Thu, 03 Sep 2020 14:14:04 +0530 commit: pass mergestate into _filecommit() instead of re-reading it
Pulkit Goyal <7895pulkit@gmail.com> [Thu, 03 Sep 2020 14:14:04 +0530] rev 45443
commit: pass mergestate into _filecommit() instead of re-reading it mergestate reading although cheap is not free. Let's read mergestate once on top and pass it into `_filecommit()`. In upcoming patches, we will be reading mergestate more in `_filecommit()`. Differential Revision: https://phab.mercurial-scm.org/D8984
Fri, 11 Sep 2020 13:04:05 +0530 py3: fix bytes and str mixup in run-tests
Sushil khanchi <sushilkhanchi97@gmail.com> [Fri, 11 Sep 2020 13:04:05 +0530] rev 45442
py3: fix bytes and str mixup in run-tests Differential Revision: https://phab.mercurial-scm.org/D9009
Mon, 17 Aug 2020 10:59:30 +0200 hg-core: fix some `clippy` warnings
Antoine Cezar <antoine.cezar@octobus.net> [Mon, 17 Aug 2020 10:59:30 +0200] rev 45441
hg-core: fix some `clippy` warnings Differential Revision: https://phab.mercurial-scm.org/D8957
Mon, 17 Aug 2020 16:55:43 +0200 rhg: print error message when argument parsing fails
Antoine Cezar <antoine.cezar@octobus.net> [Mon, 17 Aug 2020 16:55:43 +0200] rev 45440
rhg: print error message when argument parsing fails Differential Revision: https://phab.mercurial-scm.org/D8956
Thu, 13 Aug 2020 16:36:42 +0200 rhg: fix `clippy` warnings
Antoine Cezar <antoine.cezar@octobus.net> [Thu, 13 Aug 2020 16:36:42 +0200] rev 45439
rhg: fix `clippy` warnings Differential Revision: https://phab.mercurial-scm.org/D8955
Tue, 04 Aug 2020 16:11:23 +0200 rhg: pass `ui` to `Command` `run`
Antoine Cezar <antoine.cezar@octobus.net> [Tue, 04 Aug 2020 16:11:23 +0200] rev 45438
rhg: pass `ui` to `Command` `run` Allow implementation of `From<clap::ArgMatches> for Command` Differential Revision: https://phab.mercurial-scm.org/D8954
Mon, 03 Aug 2020 11:55:59 +0200 rhg: add harness tests for rhg files
Antoine Cezar <antoine.cezar@octobus.net> [Mon, 03 Aug 2020 11:55:59 +0200] rev 45437
rhg: add harness tests for rhg files Differential Revision: https://phab.mercurial-scm.org/D8873
Thu, 30 Jul 2020 16:55:44 +0200 rhg: make output of `files` relative to the current directory and the root
Raphaël Gomès <rgomes@octobus.net> [Thu, 30 Jul 2020 16:55:44 +0200] rev 45436
rhg: make output of `files` relative to the current directory and the root This matches the behavior of `hg files`. The util is added in `hg-core` instead of `rhg` because this operation could be useful for other external tools. (this was definitely not prompted by rust issue #50784, I swear) Differential Revision: https://phab.mercurial-scm.org/D8872
Tue, 08 Sep 2020 19:36:40 +0530 tags: take lock instead of wlock before writing hgtagsfnodes1 cache
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 08 Sep 2020 19:36:40 +0530] rev 45435
tags: take lock instead of wlock before writing hgtagsfnodes1 cache This cache is shared across stores and hence we should take store lock before writing to it. Otherwise there will be race where one share with wlock is writing to this cache and other share with wlock is trying to read it simultaneously. Differential Revision: https://phab.mercurial-scm.org/D9001
Thu, 10 Sep 2020 13:37:35 +0530 statichttprepo: use LockUnavailable() instead of Abort() for lock (API)
Pulkit Goyal <7895pulkit@gmail.com> [Thu, 10 Sep 2020 13:37:35 +0530] rev 45434
statichttprepo: use LockUnavailable() instead of Abort() for lock (API) If we try to get a lock on statichttprepo, we get `error.Abort()` instead of subclass of `error.LockError()`. The callers which catches `error.LockError` fails to catch this case as the correct error is not raised. Raising `error.LockUnavaible()` is same as what is done for wlock also.
Tue, 08 Sep 2020 18:46:01 +0530 localrepo: warn if we are writing to cache without a lock
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 08 Sep 2020 18:46:01 +0530] rev 45433
localrepo: warn if we are writing to cache without a lock From quite sometime we have two types of cache, `cache` and `wcache`. The later one is a working copy cache and the first one is a store cache. Let's add a check for warning if we are missing store lock while writing to these caches. This is inspired from some tag cache breakage which is observed when multiple shares are in play. The interesting part is that although we are still taking wlock to write store caches at many places, but still the test pases. Differential Revision: https://phab.mercurial-scm.org/D9000
Thu, 03 Sep 2020 14:14:40 +0530 commit: fix a wrong argument name in documentation
Pulkit Goyal <7895pulkit@gmail.com> [Thu, 03 Sep 2020 14:14:40 +0530] rev 45432
commit: fix a wrong argument name in documentation Differential Revision: https://phab.mercurial-scm.org/D8985
Thu, 10 Sep 2020 17:03:38 +0530 git: remove unrequired assignment of listignored and listunknown
Pulkit Goyal <7895pulkit@gmail.com> [Thu, 10 Sep 2020 17:03:38 +0530] rev 45431
git: remove unrequired assignment of listignored and listunknown Caught by test-check-pyflakes.t
Wed, 09 Sep 2020 11:41:18 +0900 grep: fix hash(linestate) to not include linenum
Yuya Nishihara <yuya@tcha.org> [Wed, 09 Sep 2020 11:41:18 +0900] rev 45430
grep: fix hash(linestate) to not include linenum linestate.__eq__() just compares the line values whereas __hash__() does hash both self.line and self.linenum, which violates the rule. __hash__() was added at fb502719c75c, "python 2.6 compatibility: add __hash__ to classes that have __eq__" with no additional remarks, so this would probably be a simple mistake. The test output changed because difflib.SequenceMatcher() internally uses a dict. As you can see, the line "export" is unchanged at the revision 2, so the new output is correct.
Tue, 08 Sep 2020 21:38:10 +0900 test-grep: document that trivially moved lines might not be detected
Yuya Nishihara <yuya@tcha.org> [Tue, 08 Sep 2020 21:38:10 +0900] rev 45429
test-grep: document that trivially moved lines might not be detected I'm not going to fix this. I just learned "grep --diff" does clever thing than a simple grep(patch.diff(context=0)), and I think it's better to document how things work.
Wed, 09 Sep 2020 11:51:51 +0900 revset: remove indirect indexing of status tuple
Yuya Nishihara <yuya@tcha.org> [Wed, 09 Sep 2020 11:51:51 +0900] rev 45428
revset: remove indirect indexing of status tuple Just use the attribute name.
Tue, 25 Aug 2020 23:18:42 -0400 rewriteutil: relax the sha1 hash references to handle future hash types
Matt Harbison <matt_harbison@yahoo.com> [Tue, 25 Aug 2020 23:18:42 -0400] rev 45427
rewriteutil: relax the sha1 hash references to handle future hash types Per discussion with nbjoerg in IRC. Differential Revision: https://phab.mercurial-scm.org/D8951
Mon, 24 Aug 2020 18:51:25 -0400 phabricator: update the hashes in commit messages as they get submitted
Matt Harbison <matt_harbison@yahoo.com> [Mon, 24 Aug 2020 18:51:25 -0400] rev 45426
phabricator: update the hashes in commit messages as they get submitted Due to the sequence of actions (posting, amending the local commit, and then updating the Differential properties), the message in the commit is updated on the initial send but the message displayed in Phabricator is not. It should get updated there if the review is reposted. The data in the Commits tab is accurate for the first `phabsend`. Differential Revision: https://phab.mercurial-scm.org/D8950
Mon, 24 Aug 2020 18:44:15 -0400 rewriteutil: also consider pending obsoletes when updating hashes in messages
Matt Harbison <matt_harbison@yahoo.com> [Mon, 24 Aug 2020 18:44:15 -0400] rev 45425
rewriteutil: also consider pending obsoletes when updating hashes in messages Phabricator builds up the replacement commits and mapping in a single transaction, and then finalizes everything once the commits have been rewritten. That's too late when trying to update the messages for those commits. I'm a little concerned that this isn't a generic enough interface, since it doesn't mimic the list of list return of `obsutil.successorssets()`. But this is the type of mapping that phabricator maintains, and I don't think the methods that would be interested in calling this need to worry about split and divergence. We can fix that later if the need arises. Differential Revision: https://phab.mercurial-scm.org/D8949
Mon, 24 Aug 2020 12:43:53 -0400 rewriteutil: extract evolve code used to replace obsolete hashes in commits
Matt Harbison <matt_harbison@yahoo.com> [Mon, 24 Aug 2020 12:43:53 -0400] rev 45424
rewriteutil: extract evolve code used to replace obsolete hashes in commits The evolve command uses it, but there are core things like `phabsend` and `rebase` that would also benefit. Differential Revision: https://phab.mercurial-scm.org/D8948
Mon, 07 Sep 2020 17:16:16 -0400 git: fix index handling of removed files during commit (issue6398)
Augie Fackler <raf@durin42.com> [Mon, 07 Sep 2020 17:16:16 -0400] rev 45423
git: fix index handling of removed files during commit (issue6398) Other changes in this series also changed the behavior here in positive ways, but this was the final step that actually fixed things. Differential Revision: https://phab.mercurial-scm.org/D8999
Mon, 07 Sep 2020 17:14:59 -0400 git: make dirstate actually support listclean parameter
Augie Fackler <raf@durin42.com> [Mon, 07 Sep 2020 17:14:59 -0400] rev 45422
git: make dirstate actually support listclean parameter As far as I can tell listignored and listunknown should already work. I'm vexed that there doesn't seem to be a way to get clean files out of the pygit2 status method, but this at least makes things work better. Differential Revision: https://phab.mercurial-scm.org/D8998
(0) -30000 -10000 -3000 -1000 -300 -100 -50 -30 +30 +50 +100 +300 +1000 +3000 tip