Durham Goode <durham@fb.com> [Wed, 06 Mar 2013 20:13:09 -0800] rev 18760
strip: make --keep option not set all dirstate times to 0
hg strip -k was using dirstate.rebuild() which reset all the dirstate
entries timestamps to 0. This meant that the next time hg status was
run every file was considered to be 'unsure', which caused it to do
expensive read operations on every filelog. On a repo with >150,000
files it took 70 seconds when everything was in memory. From a cold
cache it took several minutes.
The fix is to only reset files that have changed between the working
context and the destination context.
For reference, --keep means the working directory is left alone during
the strip. We have users wanting to use this operation to store their
work-in-progress as a commit on a branch while they go work on another
branch, then come back later and be able to uncommit that work and
continue working. They currently use 'git reset HARD^' to accomplish
this in git.
Durham Goode <durham@fb.com> [Fri, 08 Mar 2013 16:59:36 -0800] rev 18759
sshpeer: store subprocess so it cleans up correctly
When running 'hg pull --rebase', I was seeing this exception 100% of the
time as the python process was closing down:
Exception TypeError: TypeError("'NoneType' object is not callable",) in
<bound method Popen.__del__ of <subprocess.Popen object at 0x937c10>> ignored
By storing the subprocess on the sshpeer, the subprocess seems to clean up
correctly, and I no longer see the exception. I have no idea why this actually
works, but I get a 0% repro if I store the subprocess in self.subprocess,
and a 100% repro if I store None in self.subprocess.
Possibly related to issue 2240.
Durham Goode <durham@fb.com> [Thu, 28 Feb 2013 10:12:26 -0800] rev 18758
blackbox: fix exception when logging commands with format characters
When running commands like 'hg export -o mypatch-%N.patch', the blackbox
would throw an exception because it tried to format %N. This change
prevents it from trying to format the command string.
Idan Kamara <idankk86@gmail.com> [Sat, 23 Mar 2013 13:34:50 +0200] rev 18757
localrepo: always write the filtered phasecache when nodes are destroyed (
issue3827)
When the strip command is run, it calls repo.destroyed, which in turn checks if
we read _phasecache, and if we did calls filterunknown on it and flushes the
changes immediately. But in some cases, nothing causes _phasecache to be read,
so we miss out on this and the file remains the same on-disk.
Then a call to invalidate comes, which should refresh _phasecache if it
changed, but it didn't, so it keeps using the old one with the stripped
revision which causes an IndexError.
Test written by Yuya Nishihara.
Bryan O'Sullivan <bryano@fb.com> [Tue, 19 Mar 2013 16:19:20 -0700] rev 18756
merge with stable
Durham Goode <durham@fb.com> [Mon, 11 Mar 2013 15:37:28 -0700] rev 18755
rebase: restore active bookmark after rebase --continue
When a rebase has conflicts and the user uses rebase --continue, the previously
active bookmark was not being made active once again. With this change that
bookmark is made active again, just as if the rebase had never been interrupted.
This changes the rebasestate file format, but should handle old formats correctly.
Since the file is transient, this is even less of a problem.
Adds a test to verify the new behavior. I manually tested continuing rebases
with and without an active bookmark, and with and without being on the bookmark
being rebased.
Benoit Boissinot <benoit.boissinot@ens-lyon.org> [Mon, 04 Mar 2013 10:05:52 +0100] rev 18754
setup.py: ignore warnings from obsolete
Fix version detection with recent hg versions.
Benoit Boissinot <benoit.boissinot@ens-lyon.org> [Mon, 04 Mar 2013 10:13:28 +0100] rev 18753
setup.py: add metadata to register package to PyPI
This allows updating PyPI with just 'setup.py register' (assuming the user is
an owner or maintainer of the PyPI package).
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 21:51:21 +0000] rev 18752
minirst: optimize HTML table generation a bit
avoid a couple of array copies and string interpolations
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 21:51:21 +0000] rev 18751
minirst: HTML formatter tweaks
output table rows on distinct lines
don't make the first row a table header
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 17:44:25 -0500] rev 18750
minirst: CGI escape strings prior to embedding it in the HTML
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 21:51:21 +0000] rev 18749
minirst: don't generate TH elements for the first row in table
We mainly use them for option tables -- browsers bolding and centering
them looks wrong.
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sun, 10 Feb 2013 12:58:57 +0100] rev 18748
help: use a full header for topic titles
...for prettier HTML!
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 21:51:21 +0000] rev 18747
hgweb: generate HTML documentation
It's generated from the raw ReST source, as returned from help.help_().
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 21:51:21 +0000] rev 18746
help: move the majority of the help command to the help module
We move the logic for generating the unformatted ReST source to the
help module, in order to eventually avoid calling commands.help_()
from hgweb.
No functionality change.
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Sat, 09 Feb 2013 21:51:21 +0000] rev 18745
hgweb help: split up long lines (in generated output)
Dan Villiom Podlaski Christiansen <danchr@gmail.com> [Fri, 01 Mar 2013 19:42:42 +0100] rev 18744
hgweb help: add tests
Kevin Bullock <kbullock@ringworld.org> [Fri, 01 Mar 2013 10:05:37 -0600] rev 18743
merge with stable
Matt Mackall <mpm@selenic.com> [Thu, 28 Feb 2013 21:58:37 -0600] rev 18742
merge with crew
Matt Mackall <mpm@selenic.com> [Thu, 28 Feb 2013 21:53:13 -0600] rev 18741
Added signature for changeset
5b7175377bab
Matt Mackall <mpm@selenic.com> [Thu, 28 Feb 2013 21:53:04 -0600] rev 18740
Added tag 2.5.2 for changeset
5b7175377bab
Matt Mackall <mpm@selenic.com> [Thu, 28 Feb 2013 21:29:31 -0600] rev 18739
setparents: drop copies from dropped p2 (
issue3843)
Matt Mackall <mpm@selenic.com> [Sun, 17 Feb 2013 14:41:31 -0600] rev 18738
httppeer: avoid large dumps when we don't see an hgweb repo
When we don't get an hgweb protocol response, we dump the response to
the user for diagnostic purposes (it might be a cgitb message, for
instance).
But if we try to clone a bundle, we don't want to show the
entire bundle in the error message. Also, we don't want fetch the
full bundle multiple times during fallback. So we only fetch 1k here.
Matt Mackall <mpm@selenic.com> [Sun, 17 Feb 2013 14:34:53 -0600] rev 18737
httppeer: improve protocol check
Pre-0.6c hgweb used text/plain for protocol responses. This meant
that a web server could serve a static file and confuse a client into
generating a nasty traceback.
Now we insist that text/plain protocol responses not include a
Content-Length, which older hgweb didn't generate but will typically
be produced for static files.
Bryan O'Sullivan <bryano@fb.com> [Thu, 28 Feb 2013 13:11:42 -0800] rev 18736
util: add a timed function for use during development
I often want to measure the cost of a function call before/after
an optimization, where using top level "hg --time" timing introduces
enough other noise that I can't tell if my efforts are having an
effect.
This decorator allows a developer to measure a function's cost with
finer granularity.
Bryan O'Sullivan <bryano@fb.com> [Thu, 28 Feb 2013 12:51:18 -0800] rev 18735
util: generalize bytecount to unitcountfn
This gives us a function we can reuse to count units of other kinds.
Thomas Arendsen Hein <thomas@intevation.de> [Thu, 28 Feb 2013 21:34:44 +0100] rev 18734
help: new SHA-1 fingerprint of hg.intevation.org in hostfingerprints example
The certificate was updated in March 2012.
You can verify the certificate by using the Root CA certificate downloadable
from https://ssl.intevation.de/
The intermediate CA is sent by https://hg.intevation.org/
Mads Kiilerich <madski@unity3d.com> [Tue, 26 Feb 2013 21:04:50 +0100] rev 18733
tests: work around msys bash mangling of paths in test-mq.t
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 14:05:15 +0100] rev 18732
largefiles: remove wrong comment on standin matcher and code for creating dirs
The existence of these directories could not be relied on anyway and all
dependencies on them should have been removed.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 14:51:59 +0100] rev 18731
merge with stable
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:55:00 +0100] rev 18730
templatefilters: add missing import of _
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:45:18 +0100] rev 18729
largefiles: updatelfiles should use working dir standins, not standins from p1
This makes a difference when working directory is dirty, especially when
merging with a revision for which we don't have largefiles.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:45:18 +0100] rev 18728
largefiles: simplify cachelfiles - don't spend a lot of time checking hashes
cachelfiles jumped through loops to handle merges and modified files ... but it
did apparently no longer have a valid reason to do so. It should just always
make sure that the largefiles referenced from the standins are present - no
matter which actual largefile is stored in the working directory. If there is
no standin then there is nothing to fetch.
The old code usually verified the hash of all largefiles every time this
function was invoked - for examply by 'update'.
This change makes a trivial noop update 5-10 seconds faster on our repo (with
the other 50% spent doing another unnecessary hashing of all largefiles).
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:45:18 +0100] rev 18727
largefiles: don't let update leave wrong largefiles in wd if fetch fails
Situations where a largefile for some reason wasn't available sometimes caused
wrong largefile content and state. It has mostly been seen when interrupting
download of largefiles ... and when introducing programming errors.
Instead we now make sure to delete the old and wrong largefile. A missing file
is a well-known error condition and much more reasonable way to handle the
situation.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:45:18 +0100] rev 18726
largefiles: missing largefiles should not be committed as removed
Largefiles can easily become missing - for example if it simply isn't available
or the download fail. It might even be convenient to be able to work that way
in some cases.
But commiting missing largefiles as if they had been 'hg remove'd is plain wrong.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:45:18 +0100] rev 18725
largefiles: don't assume that .hg/largefiles/ still exists
It might not have been created and it might have been removed.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:45:18 +0100] rev 18724
largefiles: getstandinmatcher should not depend on existence of directories
Looking for a (potentially empty) directory was not reliable - both because it
is a reasonable assumption that empty directories can be removed and because it
wasn't created in all cases ... such as when pulling to an existing repository.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:44:59 +0100] rev 18723
tests: don't rely on broken behaviour in test-largefiles-cache.t
The test relied on the bug that 'pull largefiles from branchheads' didn't pull
any largefiles from tip revision when it seemed like no largefiles had been
checked out before.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:44:24 +0100] rev 18722
largefiles: fix download of largefiles from an empty list of changesets
The empty list was interpreted as all revisions - just like None is.
The empty list is now handled explicitly.
Mads Kiilerich <madski@unity3d.com> [Thu, 28 Feb 2013 13:44:22 +0100] rev 18721
largefiles: fix off-by-one error on pull --all-largefiles
Test output is changed in a case where one revision was pulled, but because of
the off-by-one error it thought that 0 revisions were pulled ... and because of
another bug it thus (tried to) fetch largefiles for all revisions.
After this change it no longer reports failure when it failed while trying to
fetch largefiles it shouldn't fetch. Largefiles that it shouldn't fetch but
managed to fetch anyway will now correctly be missing later on.
This change thus resolves some of unexplained test output introduced in
1e4eb1faba6e.
Simon Heimberg <simohe@besonet.ch> [Sat, 23 Feb 2013 22:54:57 +0100] rev 18720
tests: remove glob lines which unnecessary match / for \ on windows
This lines were reported as unnecessary when running the tests on windows
because the path was already printed with a slash and not a backslash.
Simon Heimberg <simohe@besonet.ch> [Sat, 23 Feb 2013 22:07:38 +0100] rev 18719
tests: append glob to filename output when required for windows
The test failed on windows before this patch.
Matt Mackall <mpm@selenic.com> [Fri, 22 Feb 2013 16:40:27 -0600] rev 18718
convert: stabilize cvsps commitid sort order
Matt Mackall <mpm@selenic.com> [Fri, 22 Feb 2013 15:17:33 -0600] rev 18717
pager: catch ctrl-c on exit (
issue3834)
Matt Mackall <mpm@selenic.com> [Fri, 22 Feb 2013 13:46:54 -0600] rev 18716
merge with crew
Matt Mackall <mpm@selenic.com> [Fri, 22 Feb 2013 13:45:46 -0600] rev 18715
templater: properly handle file_copies with %
Bryan O'Sullivan <bryano@fb.com> [Fri, 22 Feb 2013 10:05:22 -0800] rev 18714
localrepo: iterate over manifest key/value pairs in status
This saves us a couple of dict lookups in the common case, and improves
the performance of the status method by 5% (measured with util.timed)
in a repo with a large manifest.
Bryan O'Sullivan <bryano@fb.com> [Thu, 21 Feb 2013 12:55:39 -0800] rev 18713
match: more accurately report when we're always going to match
This improves the performance of log --patch and --stat by about
20% for moderately large manifests (e.g. mozilla-central) for the
common case of no -I/-X patterns.
Kevin Bullock <kbullock@ringworld.org> [Thu, 21 Feb 2013 13:16:02 -0600] rev 18712
scmutil: fix NameError on windows
Forgot to import util in mercurial.scmwindows. Error was introduced in:
changeset: 18862:
4c6f7f0dadab
user: Kevin Bullock <kbullock@ringworld.org>
date: Tue Feb 12 11:36:21 2013 -0600
summary: scmutil: split platform-specific bits into their own modules
Bryan O'Sullivan <bryano@fb.com> [Wed, 20 Feb 2013 11:31:41 -0800] rev 18711
commands: exit from the log loop at the right time
Previously, we'd run the iterator one more time than necessary,
potentially doing a lot of extra work in the process.
Bryan O'Sullivan <bryano@fb.com> [Wed, 20 Feb 2013 11:31:38 -0800] rev 18710
cmdutil: use a small initial window with --limit
In a large repo, running a command like "log -l1 -p" was expensive because
it would always traverse 8 commits, as 8 was the initial window size.
We now choose the lesser of 8 or the limit, speeding up the "log -l1 -p"
case by a factor of 5.
Bryan O'Sullivan <bryano@fb.com> [Wed, 20 Feb 2013 11:31:34 -0800] rev 18709
worker: handle worker failures more aggressively
We now wait for worker processes in a separate thread, so that we can
spot failures in a timely way, wihout waiting for the progress pipe
to drain.
If a worker fails, we recover the pre-parallel-update behaviour of
failing early by killing its peers before propagating the failure.
Bryan O'Sullivan <bryano@fb.com> [Wed, 20 Feb 2013 11:31:31 -0800] rev 18708
worker: fix a race in SIGINT handling
This is almost impossible to trigger due to the tiny time window involved.
Bryan O'Sullivan <bryano@fb.com> [Wed, 20 Feb 2013 11:31:27 -0800] rev 18707
worker: on error, exit similarly to the first failing worker
Previously, if a worker failed, we exited with status 1. We now exit
with the correct exit code (killing ourselves if necessary).
Kevin Bullock <kbullock@ringworld.org> [Tue, 19 Feb 2013 13:35:39 -0600] rev 18706
merge with stable
Kevin Bullock <kbullock@ringworld.org> [Tue, 19 Feb 2013 13:35:25 -0600] rev 18705
merge with main
Na'Tosha Bard <natosha@unity3d.com> [Sat, 09 Feb 2013 21:07:42 +0000] rev 18704
largefiles: don't cache largefiles for pulled heads by default
After discussion, we've agreed that largefiles for newly pulled heads should
not be cached by default. The use case for this is using largefiles repos
with multiple remote servers (and therefore multiple remote largefiles caches),
where users will be pulling from non-default locations on a regular basis. We
think this use case will be significantly less common than the use case where
all largefiles are stored on the same central server, so the default should be
no caching.
The old behavior can be obtained by passing the --cache-largefiles flag to
pull.
Matt Mackall <mpm@selenic.com> [Mon, 18 Feb 2013 13:21:27 -0600] rev 18703
merge with stable
Matt Mackall <mpm@selenic.com> [Mon, 18 Feb 2013 13:20:59 -0600] rev 18702
merge with crew
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Mon, 18 Feb 2013 00:04:28 +0900] rev 18701
bundle: treat branches created newly on the local correctly (
issue3828)
Before this patch, "hg bundle --branch foo other" fails to create
bundle file, if specified "foo" branch is created newly on the local
repository.
"hg bundle" uses "hg.addbranchrevs(repo, other, ...)" to look branch
names up, even though other outgoing-like implementation uses
"hg.addbranchrevs(repo, repo, ...)". In the former invocation, "other"
repository recognizes such branches as unknown, so execution is
aborted.
This patch uses "hg.addbranchrevs(repo, repo, ..)" in "hg bundle" to
bundle revisions on such branches correctly.