Danny Hooper <hooper@google.com> [Mon, 07 Jan 2019 15:25:41 -0800] rev 41126
tests: use more portable flags in test-fix.t
`head --lines N` is known to not exist on OSX.
Differential Revision: https://phab.mercurial-scm.org/D5517
Yuya Nishihara <yuya@tcha.org> [Mon, 07 Jan 2019 21:43:06 +0900] rev 41125
amend: add -D/--currentdate option
It bumps the date field even if there's no other change. The help text is
copied from commands.graft().
Unlike graft, --date with --currentdate is disallowed, which I think is
saner behavior.
Yuya Nishihara <yuya@tcha.org> [Mon, 07 Jan 2019 21:39:35 +0900] rev 41124
amend: add boolean to ignore date-only change
I want to add -D/--currentdate option, which should behave slightly different
from the update-timestamp option.
Yuya Nishihara <yuya@tcha.org> [Mon, 07 Jan 2019 21:29:58 +0900] rev 41123
amend: refactor commit date handling
There's no need to parse a date tuple. Just do it for user option.
Yuya Nishihara <yuya@tcha.org> [Mon, 07 Jan 2019 21:57:23 +0900] rev 41122
test-amend: remove uninteresting fields from log output to deduplicate tests
We aren't testing the behavior of obsolescence-based amend.
Pulkit Goyal <pulkit@yandex-team.ru> [Wed, 26 Dec 2018 17:36:53 +0300] rev 41121
pull: use opts.get('bookmark') instead of opts['bookmark']
This is done because at places in hgsubversion, we call the function directly. I
expect there might be more instances in extensions out there which calls
commands.push() directly. So let's not require explicitly passing of bookmark
value.
The use of opts['bookmark'] was introduced in
bad05a6afdc89cc58a2af320698ab29bd8de62d4.
Differential Revision: https://phab.mercurial-scm.org/D5484
Taapas Agrawal <taapas2897@gmail.com> [Fri, 04 Jan 2019 20:27:17 +0530] rev 41120
amend: add config option to update time to current in hg amend (
issue5828)
The given config option i.e. `rewrite.update-timestamp` updates date to
current when //True//. However when only date is to be updated to current
with the working directory clean and no other attributes changing then it
does not amend as stated in issue 5828. Further when `--date` flag is specified
along with the new config option then `--date` is given priority over the
config option.
Differential Revision: https://phab.mercurial-scm.org/D5491
Augie Fackler <raf@durin42.com> [Sun, 06 Jan 2019 15:25:10 -0500] rev 41119
tests: correct version check in clientreactor test
Experimentally, `(3, 6, 3)` is less than `sys.version_info` on an actual
Python 3.6.3 installation. Let's just check `< (3, 6, 4)` instead of
`<= (3, 6, 3)` so we stop seeing this bogus failure.
Differential Revision: https://phab.mercurial-scm.org/D5502
Augie Fackler <raf@durin42.com> [Sun, 06 Jan 2019 15:17:03 -0500] rev 41118
py3: buildbot spotted more passing tests
Differential Revision: https://phab.mercurial-scm.org/D5501
Augie Fackler <raf@durin42.com> [Sun, 06 Jan 2019 15:15:35 -0500] rev 41117
tests: add lots of b prefix goo to test-fastannotate-revmap.py
All the paths are now bytes, so now things work correctly.
# skip-blame just bytes/str issues in this test
Differential Revision: https://phab.mercurial-scm.org/D5500
Augie Fackler <raf@durin42.com> [Sun, 06 Jan 2019 15:14:53 -0500] rev 41116
fastannotate: add a missing b prefix
Spotted while debugging a test failure, but this wasn't the problem.
# skip-blame b prefix
Differential Revision: https://phab.mercurial-scm.org/D5499
Georges Racinet <gracinet@anybox.fr> [Thu, 06 Dec 2018 20:04:35 +0100] rev 41115
rust-cpython: using the new bindings from Python
The Python callers detect if we have cpython or
direct-ffi bindings and fallback to the Python
implementation if none is present.
This intermediate state allows to compare the
three possibilities.
Differential Revision: https://phab.mercurial-scm.org/D5442
Georges Racinet <gracinet@anybox.fr> [Thu, 13 Dec 2018 18:53:40 +0100] rev 41114
rust-cpython: binding for LazyAncestors
The `mercurial.rustext.ancestor` module will not in the foreseeable
future be a drop-in replacement for the pure `mercurial.ancestor`, because the
Rust variants take the index at instantiation whereas the Python ones
take a parents function. From the Python side, using the index from `ancestor`
would leak internal details out of `mercurial.revlog`, and that's unwanted.
Therefore, given that classes defined in
`rust-cpython` have the same names in both language, we keep the Rust naming
convention (CamelCase).
Eventually, though, the ancestor module can be placed under control of
`mercurial.policy`, but it will still be up to `revlog` to be aware of
that and play the role of a factory for instantiation.
Differential Revision: https://phab.mercurial-scm.org/D5441
Boris Feld <boris.feld@octobus.net> [Fri, 28 Dec 2018 03:28:02 +0100] rev 41113
discovery: move common heads computation inside partialdiscovery object
This remove one of the private attribute access. In additions, head tracking
and computation is a typical operation we can speed up using Rust.
Boris Feld <boris.feld@octobus.net> [Fri, 28 Dec 2018 03:14:34 +0100] rev 41112
discovery: introduce a partialdiscovery object
This object will ultimately gather the data about common, undecided and
missing revs in a single place and deal with most graph related computations.
The goal is both to clarify the algorithm and to help provides a simple and
clear API that can be reimplemented in Rust.
For now, we only moved the `common` set in the object. In this commit, some
direct access to the "private" `disco._common` attribute persist. They have
not been removed yet because we won't need to expose a full API identical to
`incrementalmissingancestors` and it seems simpler to access the attribute
directly until the replacement is in place.
Boris Feld <boris.feld@octobus.net> [Fri, 14 Dec 2018 12:01:15 +0100] rev 41111
discovery: move handling of sampling special case inside sampling function
The handling of cases where the number of revisions to sample is smaller than
the sample size can be moved with the sample function themselves. This
simplifies main logic, preparing a coming refactoring.
Boris Feld <boris.feld@octobus.net> [Fri, 04 Jan 2019 17:49:59 +0100] rev 41110
discovery: minor fix to some conditionals
Since `size` is the upper limit of the sample, we should include it in the
check. Otherwize the `more` variable will be zero and the sampling will be
useless
Boris Feld <boris.feld@octobus.net> [Thu, 20 Dec 2018 10:16:24 +0100] rev 41109
delta: reuse _findsnapshot call from previous stage
Two different stage of the sparse-revlog logic needs the _findsnapshot data.
To avoid recomputing it twice, make it possible to reuse the first computation
in the second step.
example affected manifest write
before: 0.067141s
after: 0.064252s (-5%)
(total gain since start of series: 95%)
Boris Feld <boris.feld@octobus.net> [Thu, 20 Dec 2018 10:15:20 +0100] rev 41108
delta: have a native implementation of _findsnapshot
The function might traverse a lot of revision, a native implementation get
significantly faster.
example affected manifest write
before: 0.114989
after: 0.067141 (-42%)
Yuya Nishihara <yuya@tcha.org> [Sun, 23 Dec 2018 12:39:20 +0900] rev 41107
transaction: do not overwrite atomic-temp files on error
Even though the original files can be restored from the backup, it should be
better to not write back a temporary file if we know it can be corrupted.
Ludovic Chabant <ludovic@chabant.com> [Thu, 03 Jan 2019 10:13:34 -0800] rev 41106
help: fix typo
Yuya Nishihara <yuya@tcha.org> [Tue, 18 Dec 2018 22:23:48 +0900] rev 41105
rust: use 'impl Trait' in method argument of AncestorsIterator
I just didn't know it's stabilized. Let's switch to new convenient syntax.
Differential Revision: https://phab.mercurial-scm.org/D5451
Yuya Nishihara <yuya@tcha.org> [Tue, 18 Dec 2018 22:12:16 +0900] rev 41104
rust: use .rev() for reverse range
Differential Revision: https://phab.mercurial-scm.org/D5450
Navaneeth Suresh <navaneeths1998@gmail.com> [Fri, 04 Jan 2019 00:00:44 +0530] rev 41103
histedit: add warning message on editing tagged commits (
issue4017)
Differential Revision: https://phab.mercurial-scm.org/D5489
Boris Feld <boris.feld@octobus.net> [Wed, 02 Jan 2019 05:12:07 +0100] rev 41102
strip: extract bookmark movement into a separate function
We will need it for the soft-strip case.
Boris Feld <boris.feld@octobus.net> [Wed, 02 Jan 2019 05:07:03 +0100] rev 41101
strip: compute bookmark target only if we have bookmark to move
This is a small change that seems to make sense.
Boris Feld <boris.feld@octobus.net> [Wed, 02 Jan 2019 05:01:15 +0100] rev 41100
strip: extract code to create strip backup
We will reuse this for soft stripping.
Boris Feld <boris.feld@octobus.net> [Wed, 02 Jan 2019 04:57:47 +0100] rev 41099
strip: clarify comment around bundle create
We may create two bundles, one for the changeset actually stripped, and one
for the changeset affected by the strip we want to keep. (Changesets with a
higher rev number than the striped ones).
For soft stripping, we still need to the first one (used for "restoring" the
changesets), but not the second one.
We start with clarifying which bits of the code is used for what.
Boris Feld <boris.feld@octobus.net> [Wed, 02 Jan 2019 05:02:25 +0100] rev 41098
strip: move attributes shortcut assigned earlier
This series will add support for "soft" stripping using the archived phase in
addition to the usual heavy weight revlog stripping. First, we need to
refactor the strip function to extract logic common to the "soft-strip" case.
We are about to extract bits of the strip function into separate functions.
Those blocks of code contain variables for frequently accessed attributes. We
move those variables outside of the soon to be moved blocks.
Navaneeth Suresh <navaneeths1998@gmail.com> [Thu, 27 Dec 2018 17:16:40 +0530] rev 41097
log: fix line wrap on diffstat with -G/--graph (
issue5800)
Differential Revision: https://phab.mercurial-scm.org/D5485
Matt Harbison <matt_harbison@yahoo.com> [Wed, 02 Jan 2019 21:49:40 -0500] rev 41096
registrar: minor cleanup to the merge function
Pointed out by Yuya.
Boris Feld <boris.feld@octobus.net> [Wed, 02 Jan 2019 10:31:14 +0100] rev 41095
vfs: raise NotImplementedError in abstractvfs._auditvfs
This make sure that auditing is implemented.