Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 02:23:45 +0530] rev 29167
py3: make contrib/undumprevlog use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 02:16:32 +0530] rev 29166
py3: make contrib/dumprevlog use print_function
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 02:14:49 +0530] rev 29165
py3: make contrib/dumprevlog use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 02:13:14 +0530] rev 29164
py3: make contrib/check-commit use print_function
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 02:11:57 +0530] rev 29163
py3: make contrib/check-commit use absolute_import
Jun Wu <quark@fb.com> [Thu, 12 May 2016 01:03:19 +0100] rev 29162
hgcia: remove hgcia (BC)
As discussed at:
https://www.mercurial-scm.org/pipermail/mercurial-devel/2016-March/081018.html,
cia service is down for years. It also uses socket.setdefaulttimeout() which
will break chg. This patch removes the extension.
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 03:31:07 +0530] rev 29161
py3: make tests/hghave use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 03:28:44 +0530] rev 29160
py3: make tests/f use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 03:26:28 +0530] rev 29159
py3: make tests/dummyssh use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 03:18:04 +0530] rev 29158
py3: make raise statement python3 compatible
In python3
raise error, message
has been changed to
raise error(message)
In additional to that nodes.SkipNode is changed to nodes.SkipNode() so that
it creates an instance directly.
Matt Mackall <mpm@selenic.com> [Mon, 16 May 2016 17:21:25 -0500] rev 29157
Added signature for changeset
aaabed77791a
Matt Mackall <mpm@selenic.com> [Mon, 16 May 2016 17:21:19 -0500] rev 29156
Added tag 3.8.2 for changeset
aaabed77791a
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Fri, 13 May 2016 07:19:59 +0900] rev 29155
help: search section of help topic by translated section name correctly
Before this patch, "hg help topic.section" might show unexpected
section of help topic in some encoding.
It applies str.lower() instead of encoding.lower(str) on translated
message to search section case-insensitively, but some encoding uses
0x41(A) - 0x5a(Z) as the second or later byte of multi-byte character
(for example, ja_JP.cp932), and str.lower() causes unexpected result.
To search section of help topic by translated section name correctly,
this patch replaces str.lower() by encoding.lower(str) for both query
string (in commands.help()) and translated help text (in
minirst.getsections()).
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Fri, 13 May 2016 07:19:59 +0900] rev 29154
patch: show lower-ed translated message correctly
Before this patch, patch.filterpatch() shows meaningless translation
of help message for chunk selection in some encoding.
It applies str.lower() instead of encoding.lower(str) on translated
message, but some encoding uses 0x41(A) - 0x5a(Z) as the second or
later byte of multi-byte character (for example, ja_JP.cp932), and
str.lower() causes unexpected result.
To show lower-ed translated message correctly, this patch replaces
str.lower() by encoding.lower(str).
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 03:09:30 +0530] rev 29153
py3: make i18n/posplit use print_function
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 13 May 2016 03:08:46 +0530] rev 29152
py3: make i18n/posplit use absolute_import
Augie Fackler <augie@google.com> [Thu, 12 May 2016 09:39:14 -0400] rev 29151
wireproto: optimize handling of large batch responses
Now that batch can be used by remotefilelog, the quadratic string
copying this was doing was actually disastrous. In my local testing,
fetching a 56 meg file used to take 3 minutes, and now takes only a
few seconds.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Thu, 05 May 2016 19:32:51 +0200] rev 29150
cleanup: replace False identity testing with an explicit token object
The recommended way to check default value (when None is not as option) is a
token object. Identity testing to integer is less explicit and not guaranteed to
work in all implementations.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Wed, 11 May 2016 09:31:47 +0200] rev 29149
devel: officially deprecate dirstate.write without transaction argument
When we introduce the develwarning, we did not had an official deprecation API
and infrastructure. We can now officially deprecate the old way with a version
deadline.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Wed, 11 May 2016 09:31:47 +0200] rev 29148
devel: officially deprecate update without destination
When we introduce the develwarning, we did not had an official deprecation API
and infrastructure. We can now officially deprecate the old way with a version
deadline.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Wed, 11 May 2016 09:34:59 +0200] rev 29147
devel: fix a typo in a deprecation warning
Credit goes to Sean Farley for spotting it.
Pierre-Yves David <pierre-yves.david@ens-lyon.org> [Wed, 11 May 2016 09:31:47 +0200] rev 29146
devel: officially deprecate old style revset
When we introduce the develwarning, we did not had an official deprecation API
and infrastructure. We can now officially deprecate the old way with a version
deadline.
timeless <timeless@mozdev.org> [Wed, 11 May 2016 01:46:11 +0000] rev 29145
check-code: handle py3 open divergence
open() really wants an encoding attribute
timeless <timeless@mozdev.org> [Wed, 11 May 2016 01:44:39 +0000] rev 29144
check-code: switch to opener
timeless <timeless@mozdev.org> [Wed, 11 May 2016 01:39:07 +0000] rev 29143
check-code: handle range/xrange divergence
timeless <timeless@mozdev.org> [Wed, 11 May 2016 01:56:08 +0000] rev 29142
check-code: fix py3 complaint about \NNN being invalid unicode
timeless <timeless@mozdev.org> [Thu, 05 May 2016 09:12:26 +0000] rev 29141
hghave: switch from iteritems to items
With this, test-hghave.t passes on python 3.
Four features fail because mercurial still is not py3 safe:
absimport
cacheable
hardlink
defaultcacerts
But that will be resolved automatically eventually.
timeless <timeless@mozdev.org> [Thu, 05 May 2016 09:07:01 +0000] rev 29140
hghave: matchoutput needs to use bytes for regexp
file output is bytes in py3, so we need each regexp to be bytes
Yuya Nishihara <yuya@tcha.org> [Tue, 03 May 2016 12:36:44 +0900] rev 29139
revset: make dagrange preserve order of input set
Unlike range, dagrange has no inverted range (such as '10:0'). So there should
be no practical reason to keep dagrange as a function that forces its own
ordering.
No performance regression is spotted in contrib/base-revsets.txt.
timeless <timeless@mozdev.org> [Thu, 05 May 2016 09:26:09 +0000] rev 29138
tests: mark test-check-pyflakes.t as requiring hg1.0+
hg does not yet run with py3, so if you try:
./run-tests.py --local test-check-pyflakes.t
... it will try to run the local hg, which does not work
and thus, hg locate will return no output to stdout (and
stderr is sent to /dev/null).
If you do:
./run-tests.py --with-hg=~/bin/hg test-check-pyflakes.t
Then it should work, if your hg is new enough to have
a locate command (hg0.6 does not have locate).
Mateusz Kwapich <mitrandir@fb.com> [Thu, 05 May 2016 17:06:54 -0700] rev 29137
dirstate: make backup methods public
They are called from outside of dirstate anyway and I want the localrepo to
use them too.
Kevin Bullock <kbullock+mercurial@ringworld.org> [Fri, 06 May 2016 08:45:56 -0500] rev 29136
check-code: add a rule banning `env -u`
Kevin Bullock <kbullock+mercurial@ringworld.org> [Fri, 06 May 2016 08:41:24 -0500] rev 29135
subrepo: use unset instead of env -u to fix test on BSDs (
issue5229)
Martijn Pieters <mjpieters@fb.com> [Wed, 04 May 2016 20:11:59 +0100] rev 29134
graphmod: partial edge styling
Allow for a style to only apply to the last N lines (for positive N) or
everything but the first N lines (for negative N) of the section along the
current node. This allows for more subtle grandparent styling.
So from the default:
$ hg log -G ...
o Lorem ipsum dolor sit
:\ amet, consectetur
: : adipiscing elit, sed
: : do eiusmod tempor
: :
o : incididunt ut labore
| : et dolore magna
| : aliqua. Ut enim ad
| : minim veniam, quis
|/
o nostrud exercitation
: ullamco laboris nisi
: ut aliquip ex ea
: commodo consequat.
:
o Duis aute irure dolor
| in reprehenderit in
~ voluptate velit esse
cillum dolore eu
to
$ hg log -G --config "experimental.graphstyle.grandparent=2." ...
o Lorem ipsum dolor sit
|\ amet, consectetur
| | adipiscing elit, sed
. . do eiusmod tempor
. .
o | incididunt ut labore
| | et dolore magna
| | aliqua. Ut enim ad
| | minim veniam, quis
|/
o nostrud exercitation
| ullamco laboris nisi
| ut aliquip ex ea
. commodo consequat.
.
o Duis aute irure dolor
| in reprehenderit in
~ voluptate velit esse
cillum dolore eu
or
$ hg log -G --config "experimental.graphstyle.grandparent=1:" ...
o Lorem ipsum dolor sit
|\ amet, consectetur
| | adipiscing elit, sed
| | do eiusmod tempor
: :
o | incididunt ut labore
| | et dolore magna
| | aliqua. Ut enim ad
| | minim veniam, quis
|/
o nostrud exercitation
| ullamco laboris nisi
| ut aliquip ex ea
| commodo consequat.
:
o Duis aute irure dolor
| in reprehenderit in
~ voluptate velit esse
cillum dolore eu
or
$ hg log -G --config "experimental.graphstyle.grandparent=-2!" ...
o Lorem ipsum dolor sit
|\ amet, consectetur
! ! adipiscing elit, sed
! ! do eiusmod tempor
! !
o | incididunt ut labore
| | et dolore magna
| | aliqua. Ut enim ad
| | minim veniam, quis
|/
o nostrud exercitation
| ullamco laboris nisi
! ut aliquip ex ea
! commodo consequat.
!
o Duis aute irure dolor
| in reprehenderit in
~ voluptate velit esse
cillum dolore eu
Maciej Fijalkowski <fijall@gmail.com> [Sun, 24 Apr 2016 14:21:38 +0300] rev 29133
pure: write a really lazy version of pure indexObject
On PyPy this version performs reasonably well compared to C version.
Example command is "hg id" which gets faster, depending on details
of your operating system and hard drive (it's bottlenecked on stat mostly)
There is potential for improvements by storing extra as a condensed struct too.
Jun Wu <quark@fb.com> [Sat, 07 May 2016 14:12:23 +0100] rev 29132
dispatch: always load extensions before running shell aliases (
issue5230)
Before this patch, we may or may not load extensions for shell aliases
depending on whether the command is abbreviated or not.
Loading extensions may have useful side effects to shell aliases. For example,
the pager extension does not work for shell aliases.
This patch removes the code checking shell aliases before loading extensions
to give the user a more consistent experience. It may hurt performance for
shell aliases a bit without chg but the correctness seems worth it. It will
also make the behavior consistent with chg since chg will always load all
extensions before running commands.
Augie Fackler <augie@google.com> [Mon, 09 May 2016 21:13:50 -0400] rev 29131
httpclient: update to upstream revision
2995635573d2
This is mostly Python 3 compat work thanks to timeless.
Anton Shestakov <av6@dwimlabs.net> [Fri, 06 May 2016 19:52:21 +0800] rev 29130
crecord: call prevsibling() and nextsibling() directly
The 3 classes for items used in crecord (uiheader, uihunk, uihunkline) all have
prevsibling() and nextsibling() methods. The two methods are used to get the
previous/next item of the same type of the same parent element as the current
one: when `a` is a uihunkline instance, a.nextsibling() returns the next line
in this hunk (or None, if `a` is the last line).
There are also two similar methods: previtem() and nextitem(). When called with
constrainlevel=True (the default) they simply returned the result of
prevsibling()/nextsibling(). Only when called with constrainlevel=False they
did something different: they returned previous/next item regardless of its
type (so if `a` is the last line in a hunk, a.nextitem(constrainlevel=False)
could return the next hunk or the next file -- something that is not a line).
Let's simplify this logic and make code call -sibling() methods when only
siblings are needed and -item() methods when any item would do, and then remove
the constrainlevel argument from previtem() and nextitem().
Jordi Gutiérrez Hermoso <jordigh@octave.org> [Thu, 28 Apr 2016 10:37:47 -0400] rev 29129
dispatch: add fail-* family of hooks
The post-* family of hooks will not run in case a command fails (i.e.
raises an exception). This makes it inconvenient to hook into events
such as doing something in case of a failed push.
We catch all exceptions to run the failure hook. I am not sure if this
is too aggressive, but tests apparently pass.
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 22:21:32 +0530] rev 29128
py3: make hgext/rebase.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:54:31 +0530] rev 29127
py3: make hgext/mq.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:52:26 +0530] rev 29126
py3: make hgext/hisedit.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:50:40 +0530] rev 29125
py3: make hgext/hgk.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:46:17 +0530] rev 29124
py3: make hgext/gpg.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:48:17 +0530] rev 29123
py3: make hgext/graphlog.py use absolute_import
liscju <piotr.listkiewicz@gmail.com> [Sat, 07 May 2016 19:59:30 +0200] rev 29122
import-checker: recognize relative imports from parents of current package
So far fromlocal recognizes relative imports of the form:
from . import D
from .. import E
It wasn't prepared for recognizing relative imports like:
from ..F import G
The bug was not found so far because all relative imports starting
from the parent was in the list of allowsymbolicimports like:
from ..i18n import
from ..node import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:44:41 +0530] rev 29121
py3: make hgext/fetch.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Fri, 06 May 2016 21:41:25 +0530] rev 29120
tests: test-check-py3-compat.t output updated
The test output was not updated as the lower section of the test updates
with python3.5, so it might be the case that people have updated the modules
but the test was left as it was. So this patch updates the test output.
Yuya Nishihara <yuya@tcha.org> [Mon, 02 May 2016 12:09:00 +0900] rev 29119
revset: factor out public optimize() function from recursion
New optimize() hides internal arguments and return values. This makes it easy
to add more parameters and return values to _optimize().
Yuya Nishihara <yuya@tcha.org> [Mon, 02 May 2016 12:47:09 +0900] rev 29118
revset: introduce temporary variables in optimize() where they look better
Yuya Nishihara <yuya@tcha.org> [Mon, 02 May 2016 11:50:48 +0900] rev 29117
revset: construct arguments of only() against matched tree
Since _isonly() knows the structure of 'revs' and 'bases', it should be
slightly easier to understand than destructuring 'ta' and 'tb'.
Yuya Nishihara <yuya@tcha.org> [Mon, 02 May 2016 11:27:26 +0900] rev 29116
revset: unnest isonly() closure from optimize()
There were no variables to be captured.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:46:31 -0700] rev 29115
sslutil: stop checking for web.cacerts=! (BC)
The previous patch stopped setting web.cacerts=! to indicate
--insecure.
That left user configs as the only source that could introduce
web.cacerts=!.
The practical impact of this patch is we no longer honor
web.cacerts=! in configs. Instead, we always treat web.cacerts
as a path. The patch is therefore technically BC. However,
since I don't believe web.cacerts=! is documented, it should be
safe to remove.
a939f08fae9c (which introduced --insecure) has
no indication that web.cacerts=! is anything but an implementation
detail, reinforcing my belief it can be removed without major
debate.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:40:01 -0700] rev 29114
dispatch: stop setting web.cacerts=! to indicate --insecure
Consumers needing to know if --insecure was used have already
transitioned to using ui.insecureconnections. The previous
patch removed the last meaningful consumer looking for
web.cacerts=!.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:38:18 -0700] rev 29113
sslutil: use CA loaded state to drive validation logic
Until now, sslkwargs may set web.cacerts=! to indicate
that system certs could not be found. This is really
obtuse because sslkwargs effectively sets state on a global
object which bypasses wrapsocket() and is later consulted
by validator.__call__. This is madness.
This patch introduces an attribute on the wrapped socket
instance indicating whether system CAs were loaded. We
can set this directly inside wrapsocket() because that
function knows everything that sslkwargs() does - and more.
With this attribute set on the socket, we refactor
validator.__call__ to use it.
Since we no longer have a need for setting web.cacerts=!
in sslkwargs, we remove that.
I think the new logic is much easier to understand and will
enable behavior to be changed more easily.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:37:28 -0700] rev 29112
sslutil: handle ui.insecureconnections in validator
Right now, web.cacerts=! means one of two things:
1) Use of --insecure
2) No CAs could be found and were loaded (see sslkwargs)
This isn't very obvious and makes changing behavior of these
different scenarios independent of the other impossible.
This patch changes the validator code to explicit handle the
case of --insecure being used.
As the inline comment indicates, there is room to possibly change
messaging and logic here. For now, we are backwards compatible.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:35:45 -0700] rev 29111
sslutil: check for ui.insecureconnections in sslkwargs
The end result of this function is the same. We now have a more
explicit return branch.
We still keep the old code looking at web.cacerts=! a few lines
below because we're still setting web.cacerts=! and need to react
to the variable. This will be removed in an upcoming patch.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:34:22 -0700] rev 29110
dispatch: set ui.insecureconnections when --insecure is used
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:33:38 -0700] rev 29109
ui: add an instance flag to hold --insecure bit
Currently, when --insecure is used we set web.cacerts=! and
socket validation takes this value into account. web.cacerts=!
is not documented AFAICT and is purely an internal implementation
detail.
Let's be more explicit about what is going on by introducing a
dedicated variable outside of the config values to track that
--insecure is used.
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 05 May 2016 00:32:43 -0700] rev 29108
sslutil: make sslkwargs code even more explicit
The ways in which this code can interact with socket wrapping
and validation later are mind numbing. This patch helps make it
even more clear.
The end behavior should be identical.