Sun, 20 Mar 2016 15:25:25 -0700 chg: define PRINTF_FORMAT_ for non gnu C compiler
Jun Wu <quark@fb.com> [Sun, 20 Mar 2016 15:25:25 -0700] rev 28604
chg: define PRINTF_FORMAT_ for non gnu C compiler Before this patch, if __GNUC__ is not defined, PRINTF_FORMAT_ will not be defined and will cause compilation error. This patch solves the issue by making sure PRINTF_FORMAT_ is defined. It allows chg to be compiled with tcc (http://bellard.org/tcc/) by: tcc -o chg *.c
Sun, 20 Mar 2016 15:11:34 -0700 chgserver: drop bundle.mainreporoot config
Jun Wu <quark@fb.com> [Sun, 20 Mar 2016 15:11:34 -0700] rev 28603
chgserver: drop bundle.mainreporoot config Before this patch, although chgserver drops repo object by setting it to None, there is another side effect loading a repo: setting bundle.mainreporoot. This patch explicitly sets it to empty to undo the side effect. It will make chg pass test-strip.t.
Sun, 20 Mar 2016 10:44:15 -0700 chgserver: drop old hack to recreate ui on HGPLAIN change
Yuya Nishihara <yuya@tcha.org> [Sun, 20 Mar 2016 10:44:15 -0700] rev 28602
chgserver: drop old hack to recreate ui on HGPLAIN change It's been superseded by config/env hash. A log message is simplified as we no longer need a diff of environment variables. Also, _loadnewui() is changed to require args since it can't copy old --config values without args.
Sat, 19 Mar 2016 16:37:47 -0700 graphmod: allow edges to end early
Martijn Pieters <mjpieters@fb.com> [Sat, 19 Mar 2016 16:37:47 -0700] rev 28601
graphmod: allow edges to end early Rather than draw an edge all the way to the bottom of the graph, make it possible to end an edge to parents that are not part of the graph early on. This results in a far cleaner graph. Any edge type can be set to end early; set the ui.graphstyle.<edgetype> parameter to the empty string to enable this. For example, setting the following configuration: [ui] graphstyle.grandparent = : graphstyle.missing = would result in a graph like this: o changeset: 32:d06dffa21a31 |\ parent: 27:886ed638191b | : parent: 31:621d83e11f67 | : o : changeset: 31:621d83e11f67 |\: parent: 21:d42a756af44d | : parent: 30:6e11cd4b648f | : o : changeset: 30:6e11cd4b648f |\ \ parent: 28:44ecd0b9ae99 | ~ : parent: 29:cd9bb2be7593 | / o : changeset: 28:44ecd0b9ae99 |\ \ parent: 1:6db2ef61d156 | ~ : parent: 26:7f25b6c2f0b9 | / o : changeset: 26:7f25b6c2f0b9 |\ \ parent: 18:1aa84d96232a | | : parent: 25:91da8ed57247 | | : | o : changeset: 25:91da8ed57247 | |\: parent: 21:d42a756af44d | | : parent: 24:a9c19a3d96b7 | | : | o : changeset: 24:a9c19a3d96b7 | |\ \ parent: 0:e6eb3150255d | | ~ : parent: 23:a01cddf0766d | | / | o : changeset: 23:a01cddf0766d | |\ \ parent: 1:6db2ef61d156 | | ~ : parent: 22:e0d9cccacb5d | | / | o : changeset: 22:e0d9cccacb5d |/:/ parent: 18:1aa84d96232a | : parent: 21:d42a756af44d | : | o changeset: 21:d42a756af44d | |\ parent: 19:31ddc2c1573b | | | parent: 20:d30ed6450e32 | | | +---o changeset: 20:d30ed6450e32 | | | parent: 0:e6eb3150255d | | ~ parent: 18:1aa84d96232a | | | o changeset: 19:31ddc2c1573b | |\ parent: 15:1dda3f72782d | ~ ~ parent: 17:44765d7c06e0 | o changeset: 18:1aa84d96232a parent: 1:6db2ef61d156 parent: 15:1dda3f72782d The default configuration leaves all 3 types set to |. This is part of the work towards moving smartlog upstream; currently smartlog injects extra nodes into the graph to indicate grandparent relationships (nodes elided).
Sat, 19 Mar 2016 16:46:15 -0700 graphmod: allow for different styles for different edge types
Martijn Pieters <mjpieters@fb.com> [Sat, 19 Mar 2016 16:46:15 -0700] rev 28600
graphmod: allow for different styles for different edge types Rather than draw all edges as solid lines, allow for using different styles for different edge types. For example you could use dotted lines for edges that do not connect to a parent, and dashed lines when connecting to a grandparent (implying missing nodes in between). For example, setting the following configuration: [ui] graphstyle.grandparent = : graphstyle.missing = . would result in a graph like this: o changeset: 32:d06dffa21a31 |\ parent: 27:886ed638191b | : parent: 31:621d83e11f67 | : o : changeset: 31:621d83e11f67 |\: parent: 21:d42a756af44d | : parent: 30:6e11cd4b648f | : o : changeset: 30:6e11cd4b648f |\ \ parent: 28:44ecd0b9ae99 | . : parent: 29:cd9bb2be7593 | . : o . : changeset: 28:44ecd0b9ae99 |\ \ \ parent: 1:6db2ef61d156 | . . : parent: 26:7f25b6c2f0b9 | . . : o . . : changeset: 26:7f25b6c2f0b9 |\ \ \ \ parent: 18:1aa84d96232a | | . . : parent: 25:91da8ed57247 | | . . : | o-----+ changeset: 25:91da8ed57247 | | . . : parent: 21:d42a756af44d | | . . : parent: 24:a9c19a3d96b7 | | . . : | o . . : changeset: 24:a9c19a3d96b7 | |\ \ \ \ parent: 0:e6eb3150255d | | . . . : parent: 23:a01cddf0766d | | . . . : | o---+ . : changeset: 23:a01cddf0766d | | . . . : parent: 1:6db2ef61d156 | | . . . : parent: 22:e0d9cccacb5d | | . . . : | o-------+ changeset: 22:e0d9cccacb5d | . . . . : parent: 18:1aa84d96232a |/ / / / / parent: 21:d42a756af44d | . . . : | . . . o changeset: 21:d42a756af44d | . . . |\ parent: 19:31ddc2c1573b | . . . | | parent: 20:d30ed6450e32 | . . . | | +-+-------o changeset: 20:d30ed6450e32 | . . . | parent: 0:e6eb3150255d | . . . | parent: 18:1aa84d96232a | . . . | | . . . o changeset: 19:31ddc2c1573b | . . . .\ parent: 15:1dda3f72782d | . . . . | parent: 17:44765d7c06e0 | . . . . | o---+---+ | changeset: 18:1aa84d96232a . . . . | parent: 1:6db2ef61d156 / / / / / parent: 15:1dda3f72782d . . . . . Edge styles can be altered by setting the following one-character config options:: [ui] graphstyle.parent = | graphstyle.grandparent = : graphstyle.missing = . The default configuration leaves all 3 types set to |, leaving graph styles unaffected. This is part of the work towards moving smartlog upstream; currently smartlog injects extra nodes into the graph to indicate grandparent relationships (nodes elided).
Thu, 17 Mar 2016 18:32:10 +0000 chgserver: use global ui instead of repo ui for dispatch.request.ui
Jun Wu <quark@fb.com> [Thu, 17 Mar 2016 18:32:10 +0000] rev 28599
chgserver: use global ui instead of repo ui for dispatch.request.ui Before this patch, chgserver will use repo ui as dispatch.request.ui, while req.ui is designed to be global ui without repo config. Passing repo ui as dispatch.request.ui leads to repo.ui being incorrect, which can lead to unwanted results. For example, if the repo config has [extensions], it could affect which localrepository.featuresetupfuncs get executed and the repo may have an incorrect list of supported requirements. This patch changes _renewui to return both global ui and repo ui. The global ui is passed to req.ui, and the repo ui is used to calculate confighash. It will make chg pass test-largefiles-misc.t and test-requires.t, which are both related to repo requirements.
Thu, 17 Mar 2016 18:34:32 +0000 progress: update comment to reflect implementation
timeless <timeless@mozdev.org> [Thu, 17 Mar 2016 18:34:32 +0000] rev 28598
progress: update comment to reflect implementation Progress has been on by default in core for a while, the comment was written before this happened.
Sun, 20 Mar 2016 04:54:35 +0000 tests: remove lines that enable progress extension
timeless <timeless@mozdev.org> [Sun, 20 Mar 2016 04:54:35 +0000] rev 28597
tests: remove lines that enable progress extension progress has not been an extension for a long time, it has been integrated into core, thus these lines have not done anything for a while.
Sat, 19 Mar 2016 14:26:10 -0400 run-tests: add support for automatically bisecting test failures
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 14:26:10 -0400] rev 28596
run-tests: add support for automatically bisecting test failures
Sat, 19 Mar 2016 20:49:02 -0400 check-code: also ban strcat
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 20:49:02 -0400] rev 28595
check-code: also ban strcat We're not using it now, so it's easy to ban.
Sat, 19 Mar 2016 20:18:38 -0400 check-code: prevent use of strcpy
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 20:18:38 -0400] rev 28594
check-code: prevent use of strcpy
Sat, 19 Mar 2016 20:02:19 -0400 osutil: stop using strcpy
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 20:02:19 -0400] rev 28593
osutil: stop using strcpy strcpy is a security vulnerability masquerading as a utility function. Replace it with memcpy since we know how much to copy anyway.
Sat, 19 Mar 2016 11:39:13 -0700 histedit: add a hint about enabled dropmissing to histedit edit comment
Mateusz Kwapich <mitrandir@fb.com> [Sat, 19 Mar 2016 11:39:13 -0700] rev 28592
histedit: add a hint about enabled dropmissing to histedit edit comment Adds a hint to histedit comment reminding user about enabled dropmissing. This will make the enabled dropmissing more visible. The example comment: # Edit history between b592564a803c and b54649a8a63f # # Commits are listed from least to most recent # # You can reorder changesets by reordering the lines # # Commands: # # e, edit = use commit, but stop for amending # m, mess = edit commit message without changing commit content # p, pick = use commit # b, base = checkout changeset and apply further changesets from there # d, drop = remove commit from history # f, fold = use commit, but combine it with the one above # r, roll = like fold, but discard this commit's description # # Deleting a changeset from the list will DISCARD it from the edited history!
Sat, 19 Mar 2016 13:51:00 -0700 hghave: change ssl check to just check ssl module
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 19 Mar 2016 13:51:00 -0700] rev 28591
hghave: change ssl check to just check ssl module Previously, the "ssl" check effectively looked for PyOpenSSL or Python 2.7.9. After this patch, we simply look for just the "ssl" module. After d962e955da08, there have been no references to PyOpenSSL in the tree (the previous usage of PyOpenSSL was to implement ssl support on old, no longer supported Python versions that didn't have an ssl module (e.g. Python 2.4). So, the check for PyOpenSSL served no purpose. Pythons we support ship with the ssl module. Although it may not be available in all installations. So, we still need the check for whether the ssl module imports, hence the hghave check. The main side-effect of this change is that we now run test-https.t (the only test requiring the "ssl" hghave feature) on Python <2.7.9 when PyOpenSSL is not installed (which is probably most installations) and the ssl module is available. Before, we wouldn't run this test on these older Python versions. I confirmed that test-https.t passes with Python 2.6.9 and 2.7.8 on OS X 10.11.
Sat, 19 Mar 2016 15:17:33 -0700 help: document sharing of revlog header with revision 0
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 19 Mar 2016 15:17:33 -0700] rev 28590
help: document sharing of revlog header with revision 0 The previous docs were incorrect about there being a discrete header on revlogs.
Sat, 19 Mar 2016 16:45:52 -0400 mpatch: move collect() to module level
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 16:45:52 -0400] rev 28589
mpatch: move collect() to module level This helps the code read a little more clearly.
Sat, 19 Mar 2016 16:43:16 -0400 mpatch: un-nest the move() method
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 16:43:16 -0400] rev 28588
mpatch: un-nest the move() method This helps the code read a little more clearly.
Sat, 19 Mar 2016 16:37:30 -0400 mpatch: move pull() method to top level
Augie Fackler <augie@google.com> [Sat, 19 Mar 2016 16:37:30 -0400] rev 28587
mpatch: move pull() method to top level There was no need for this to be nested.
Thu, 17 Mar 2016 18:27:48 +0000 chgserver: use old ui.system if fout is not stdout or needs to be captured
Jun Wu <quark@fb.com> [Thu, 17 Mar 2016 18:27:48 +0000] rev 28586
chgserver: use old ui.system if fout is not stdout or needs to be captured Before this patch, chgui will override the system method, forwarding every process execution to the client so sessions and process groups can work as expected. But the chg client will just use stdout, if ui.fout is not stdout or if the output is set to be captured to safe._buffers, the client will not behave correctly. This can happen especially with code prepending "remote:". For example, bundle2 uses ui.pushbuffer, and sshpeer sets fout to ferr. We may have trouble with interactive commands in the fout set to ferr case but if it really bites us, we can always send file descriptors to the client. This patch adds a check to detect the above situations and fallback to the old ui.system if so. It will make chg happy with test-bundle2-exchange.t, test-phases-exchange.t, test-ssh-bundle1.t and test-ssh.t.
Sat, 12 Mar 2016 14:04:57 -0800 node: use byte literals to construct nullid and wdirid
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 Mar 2016 14:04:57 -0800] rev 28585
node: use byte literals to construct nullid and wdirid Python 3's hex() insists on operating on bytes. This patch gives it what it wants. '' and b'' in Python 2 are equivalent, so this has no impact on Python 2.
Sat, 12 Mar 2016 14:05:23 -0800 tests: try to import modules with Python 3
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 Mar 2016 14:05:23 -0800] rev 28584
tests: try to import modules with Python 3 All of mercurial.* is now using absolute_import. Most of mercurial.* is able to ast parse with Python 3. The next big hurdle is being able to import modules using Python 3. This patch adds testing of hgext.* and mercurial.* module imports in Python 3. As the new test output shows, most modules can't import under Python 3. However, many of the failures are due to a common problem in a highly imported module (e.g. the bytes vs str issue in node.py).
Fri, 18 Mar 2016 16:15:12 -0700 tests: perform an ast parse with Python 3
Gregory Szorc <gregory.szorc@gmail.com> [Fri, 18 Mar 2016 16:15:12 -0700] rev 28583
tests: perform an ast parse with Python 3 Previously, test-check-py3-compat.t parsed Python files with Python 2 and looked for known patterns that are incompatible with Python 3. Now that we have a mechanism for invoking Python 3 interpreters from tests, we can expand check-py3-compat.py and its corresponding .t test to perform an additional AST parse using Python 3. As the test output shows, we identify a number of new parse failures on Python 3. There are some redundant warnings for missing parentheses for the print function. Given the recent influx of patches around fixing these, the redundancy shouldn't last for too long.
Fri, 18 Mar 2016 16:17:56 -0700 run-tests: add --with-python3 to define a Python 3 interpreter
Gregory Szorc <gregory.szorc@gmail.com> [Fri, 18 Mar 2016 16:17:56 -0700] rev 28582
run-tests: add --with-python3 to define a Python 3 interpreter Currently, very few parts of Mercurial run under Python 3, notably the test harness. We want to write tests that run Python 3. For example, we want to extend test-check-py3-compat.t to parse and load Python files. However, we have a problem: finding appropriate files requires running `hg files` and this requires Python 2 until `hg` works with Python 3. As a temporary workaround, we add --with-python3 to the test harness to allow us to define the path to a Python 3 interpreter. This interpreter is made available to the test environment via $PYTHON3 so tests can run things with Python 3 while the test harness and `hg` invocations continue to run from Python 2. To round out the feature, a "py3exe" hghave check has been added.
Fri, 18 Mar 2016 11:06:03 -0700 crecord: add docblock to handlekeypressed
Ryan McElroy <rmcelroy@fb.com> [Fri, 18 Mar 2016 11:06:03 -0700] rev 28581
crecord: add docblock to handlekeypressed This information is pretty useful when reading the code.
Fri, 18 Mar 2016 11:06:03 -0700 crecord: fix docblock indentation
Ryan McElroy <rmcelroy@fb.com> [Fri, 18 Mar 2016 11:06:03 -0700] rev 28580
crecord: fix docblock indentation
Fri, 18 Mar 2016 11:06:03 -0700 crecord: clean up empty lines at ends of docblocks
Ryan McElroy <rmcelroy@fb.com> [Fri, 18 Mar 2016 11:06:03 -0700] rev 28579
crecord: clean up empty lines at ends of docblocks
Thu, 17 Mar 2016 00:36:01 +0000 filemerge: indicate that local/other are p1/p2
timeless <timeless@mozdev.org> [Thu, 17 Mar 2016 00:36:01 +0000] rev 28578
filemerge: indicate that local/other are p1/p2
Sat, 19 Mar 2016 10:10:09 -0700 sslutil: use preferred formatting for import syntax
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 19 Mar 2016 10:10:09 -0700] rev 28577
sslutil: use preferred formatting for import syntax
Sat, 19 Mar 2016 08:28:24 -0700 largefiles: add some docstrings
Mads Kiilerich <madski@unity3d.com> [Sat, 19 Mar 2016 08:28:24 -0700] rev 28576
largefiles: add some docstrings
Sat, 19 Mar 2016 08:27:54 -0700 largefiles: drop partial support for not having a user cache
Mads Kiilerich <madski@unity3d.com> [Sat, 19 Mar 2016 08:27:54 -0700] rev 28575
largefiles: drop partial support for not having a user cache 971c55ce03b8 introduced support for not having a "global" user cache. In the rare cases where the environment didn't provide the location of the current home directory, the usercachepath function could return None. That functionality has since bitrotten and several code paths did not correctly check for usercachepath returning None: $ HOME= XDG_CACHE_HOME= hg up --config extensions.largefiles= getting changed largefiles abort: unknown largefiles usercache location Dropping the partial support for it is thus not really a backward compatibility breaking change. Thus: consistently fail early if the usercache location is unknown. It is relevant to be able to control where the largefiles are stored and how they propagate, but that should probably be done differently. The dysfunctional code just gets in the way.
Sat, 19 Mar 2016 08:23:55 -0700 largefiles: refactor usercachepath - extract user cache path function
Mads Kiilerich <madski@unity3d.com> [Sat, 19 Mar 2016 08:23:55 -0700] rev 28574
largefiles: refactor usercachepath - extract user cache path function It is convenient to have the user cache location explicitly.
Wed, 10 Feb 2016 02:23:27 +0100 shelve: adds restoring newly created branch (issue5048) (BC)
liscju <piotr.listkiewicz@gmail.com> [Wed, 10 Feb 2016 02:23:27 +0100] rev 28573
shelve: adds restoring newly created branch (issue5048) (BC) Before this patch shelve never preserved branch information, so after applying unshelve branch was the same as it was on working copy no matter in which branch shelve took place. This patch makes bare shelving(with no files specified, without interactive,include and exclude option) remembers information if the working directory was on newly created branch ,in other words working directory was on different branch than its first parent. In this situation unshelving restores branch information to the working directory.
Mon, 07 Mar 2016 22:58:11 +0100 shelve: make non bare shelve not saving branch information in bundle
liscju <piotr.listkiewicz@gmail.com> [Mon, 07 Mar 2016 22:58:11 +0100] rev 28572
shelve: make non bare shelve not saving branch information in bundle This patch prepares for restoring newly created branch only on bare shelve later because information about new-branch will be preserved only when shelve was bare and working copy branch was different than branch of its parent. In other case information about new-branch will be gone, so unshelve will not recognise that shelve was made on new-branch and it will not restore branch information from the bundle to the working directory.
Sat, 12 Mar 2016 18:36:31 +0100 shelve: preserve newly created branch on non-bare shelve in wctx (BC)
liscju <piotr.listkiewicz@gmail.com> [Sat, 12 Mar 2016 18:36:31 +0100] rev 28571
shelve: preserve newly created branch on non-bare shelve in wctx (BC) Before this patch current branch in working context wasnt preserved after shelve, this patch makes it restore after update.
Fri, 18 Mar 2016 16:14:57 -0400 crecord: rewrite a comment about filtering patches
Jordi Gutiérrez Hermoso <jordigh@octave.org> [Fri, 18 Mar 2016 16:14:57 -0400] rev 28570
crecord: rewrite a comment about filtering patches I couldn't parse the previous version. I think the rewrite better expresses the intent of that comment.
Thu, 17 Mar 2016 20:52:06 +0000 run-tests: teach _processoutput to handle multiple lines of churn
timeless <timeless@mozdev.org> [Thu, 17 Mar 2016 20:52:06 +0000] rev 28569
run-tests: teach _processoutput to handle multiple lines of churn Instead of treating expected output as happening in a precise order, and assuming that if a line is missing it will never happen, assume that expected output is a prioritized list of likely matching lines. This means that if: foo/bar (glob) baz/bad (glob) changes to: baz/bad foo/bar instead of generating: baz/bad foo/bar For which we've lost both (glob) markers, we will match both lines and generate: baz/bad (glob) foo/bar (glob) This retains any special annotations we have for lines.
Thu, 17 Mar 2016 20:54:36 +0000 run-tests: indent _processoutput to aid readability for next patch
timeless <timeless@mozdev.org> [Thu, 17 Mar 2016 20:54:36 +0000] rev 28568
run-tests: indent _processoutput to aid readability for next patch The next commit will loop over the expected[pos] list, this change makes that change easier to review.
Wed, 16 Mar 2016 23:12:43 +0000 namespaces: fix name/node confusion
timeless <timeless@mozdev.org> [Wed, 16 Mar 2016 23:12:43 +0000] rev 28567
namespaces: fix name/node confusion There was a lot of copy/paste here.
Sun, 13 Mar 2016 23:27:27 +0900 tests: add test for "log -r wdir() -p" (issue4871)
Yuya Nishihara <yuya@tcha.org> [Sun, 13 Mar 2016 23:27:27 +0900] rev 28566
tests: add test for "log -r wdir() -p" (issue4871) The issue has been fixed by 93bcc73df8d5, "cmdutil.changeset_printer: pass context into showpatch()". This patch adds test to prevent future regression.
Sun, 13 Mar 2016 23:21:45 +0900 tests: include modified/added/removed files in "log -r wdir()" output
Yuya Nishihara <yuya@tcha.org> [Sun, 13 Mar 2016 23:21:45 +0900] rev 28565
tests: include modified/added/removed files in "log -r wdir()" output This patch prepares for the test of "hg log -r wdir() -p".
Wed, 16 Mar 2016 04:35:03 +0530 contrib: revsetbenchmarks use absolute_import and print_function
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 16 Mar 2016 04:35:03 +0530] rev 28564
contrib: revsetbenchmarks use absolute_import and print_function
Wed, 16 Mar 2016 04:23:58 +0530 contrib: synthrepo use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 16 Mar 2016 04:23:58 +0530] rev 28563
contrib: synthrepo use absolute_import
Wed, 16 Mar 2016 04:13:28 +0530 contrib: python-hook-examples use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 16 Mar 2016 04:13:28 +0530] rev 28562
contrib: python-hook-examples use absolute_import
Wed, 16 Mar 2016 04:12:16 +0530 contrib: make perf.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 16 Mar 2016 04:12:16 +0530] rev 28561
contrib: make perf.py use absolute_import
Mon, 14 Mar 2016 20:20:22 +0100 largefiles: replace invocation of os.path module by vfs in lfutil.py
liscju <piotr.listkiewicz@gmail.com> [Mon, 14 Mar 2016 20:20:22 +0100] rev 28560
largefiles: replace invocation of os.path module by vfs in lfutil.py Replaces invocations os.path functions to methods in vfs. Unfortunately (in my view) this makes code less readable, because instead of using clear variable names with path it needs to replace them with vfs(..). I need guidance how to make such transition look more readable. For example in this patch there is example with few places with wvfs.join(standindir), standindir before this patch was absolute path, in this it is changed to relative because it is used also in expression wvfs.join(standindir, pat).
Sun, 13 Mar 2016 23:16:44 +0100 largefiles: replace invocation of os.path module by vfs in lfcommands.py
liscju <piotr.listkiewicz@gmail.com> [Sun, 13 Mar 2016 23:16:44 +0100] rev 28559
largefiles: replace invocation of os.path module by vfs in lfcommands.py
Sun, 13 Mar 2016 02:06:23 +0100 cache: rebuild branch cache from scratch when inconsistencies are detected
Mads Kiilerich <madski@unity3d.com> [Sun, 13 Mar 2016 02:06:23 +0100] rev 28558
cache: rebuild branch cache from scratch when inconsistencies are detected This should recover automatically from some corruptions that for unknown reasons are seen in the wild.
Sun, 13 Mar 2016 02:06:22 +0100 cache: safer handling of failing seek when writing revision branch cache
Mads Kiilerich <madski@unity3d.com> [Sun, 13 Mar 2016 02:06:22 +0100] rev 28557
cache: safer handling of failing seek when writing revision branch cache If the seek for some reason fails (perhaps because the file is too short to search to the requested position), make sure we seek to the start and rewrite everything. It is unknown if this fixes a real problem that ever happened.
Sun, 13 Mar 2016 02:06:21 +0100 cache: remove branch revision file before rewriting the branch name file
Mads Kiilerich <madski@unity3d.com> [Sun, 13 Mar 2016 02:06:21 +0100] rev 28556
cache: remove branch revision file before rewriting the branch name file New branch names are usually appended to the branch name file. If that fails or the file has been modified by another process, it is rewritten. That left a small opportunity that there could be references to non-existent entries in the file while it was rewritten. To avoid that, remove the revision branch cache file with the references to the branch name file before rewriting the branch name file. Worst case, when interrupted at the wrong time, the cache will be lost and rebuilt next time. It is unknown if this fixes a real problem that ever happened.
Mon, 14 Mar 2016 15:05:25 +0000 chg: do not redirect stdout to /dev/null
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 15:05:25 +0000] rev 28555
chg: do not redirect stdout to /dev/null Redirecting stdout to /dev/null has unwanted side effects, namely ui.write will stop working. This patch removes the redirection code and helps chg to pass test-bad-extension.t.
Mon, 14 Mar 2016 15:03:19 +0000 pager: skip uisetup if chg is detected
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 15:03:19 +0000] rev 28554
pager: skip uisetup if chg is detected chg has its own pager implementation that it wants to skip pager's uisetup. It is currently done by redirecting stdout to /dev/null, which has unintended side effects. This patch makes pager aware of chg and skip uisetup directly from pager. We may want to merge chg and pager's pager implementation to make this unnecessary in the future.
Mon, 14 Mar 2016 23:08:03 +0000 chgserver: add an explicit gc to trigger __del__
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 23:08:03 +0000] rev 28553
chgserver: add an explicit gc to trigger __del__ SocketServer.ForkingMixIn uses os._exit which will skip all cleanup handlers. We want to run __del__ to make things like transactions, {ssh,http}peer, atomictempfile, dirstateguard, etc. work. This patch adds a "gc.collect()" to trigger __del__. It is helpful for chg to pass some test cases in test-devel-warnings.t.
Tue, 15 Mar 2016 10:36:02 +0000 blackbox: do not assume self._bb{vfs,repo,fp} are set in blackboxui.__init__
Jun Wu <quark@fb.com> [Tue, 15 Mar 2016 10:36:02 +0000] rev 28552
blackbox: do not assume self._bb{vfs,repo,fp} are set in blackboxui.__init__ It's possible for the blackboxui code to do a "del self._bbvfs", then ui.copy() or similar attempt will fail. It will also fail when constructing a blackboxui from a non-blackbox ui. This patch fixes the issue by not assuming any _bb* attr is set.
Mon, 14 Mar 2016 23:28:14 +0000 chg: downgrade "failed to read channel" from abortmsg to debugmsg
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 23:28:14 +0000] rev 28551
chg: downgrade "failed to read channel" from abortmsg to debugmsg If the server has an uncaught exception, it will exit without being able to write the channel information. In this case, the client is likely to complain about "failed to read channel", which looks inconsistent with original hg. This patch silences the error message and makes uncaught exception behavior more like original hg. It will help chg to pass test-fileset.t.
Tue, 15 Mar 2016 00:42:33 +0000 histedit: do not close stdin
Jun Wu <quark@fb.com> [Tue, 15 Mar 2016 00:42:33 +0000] rev 28550
histedit: do not close stdin Closing stdin is unexpected by chgserver and is not a good idea generally. This patch refactors related code a bit and make sure stdin is not closed. It will make chg much happier on test-histedit*.t.
Tue, 15 Mar 2016 09:51:54 +0000 tests: reorder hg serve commands
Jun Wu <quark@fb.com> [Tue, 15 Mar 2016 09:51:54 +0000] rev 28549
tests: reorder hg serve commands chg currently does not support hg serve -d. It has a quick path testing if the command is hg serve -d and fallbacks to hg if so. But the test only works if "serve" is the first argument since the test wants to avoid false positives (for example, "-r serve" is different). This patch reorders "hg server" commands in tests, making them chg friendly.
Sun, 14 Feb 2016 01:06:12 +0900 templater: add debugtemplate command
Yuya Nishihara <yuya@tcha.org> [Sun, 14 Feb 2016 01:06:12 +0900] rev 28548
templater: add debugtemplate command This is useful for debugging template parsing. Several tests are ported to this command.
Sat, 13 Feb 2016 23:20:47 +0900 templater: expand list of parsed templates to template node
Yuya Nishihara <yuya@tcha.org> [Sat, 13 Feb 2016 23:20:47 +0900] rev 28547
templater: expand list of parsed templates to template node This patch eliminates a nested data structure other than the parsed tree. ('template', [(op, data), ..]) -> ('template', (op, data), ..) New expanded tree can be processed by common parser functions. This change will help implementing template aliases. Because a (template ..) node should have at least one child node, an empty template (template []) is mapped to (string ''). Also a trivial string (template [(string ..)]) node is unwrapped to (string ..) at parsing phase, instead of compiling phase.
Sun, 14 Feb 2016 15:42:49 +0900 templater: relax type of mapped template
Yuya Nishihara <yuya@tcha.org> [Sun, 14 Feb 2016 15:42:49 +0900] rev 28546
templater: relax type of mapped template Now compiled template fragments are packed into a generic type, (func, data), a string can be a valid template. This change allows us to unwrap a trivial string node. See the next patch for details.
Sat, 13 Feb 2016 23:54:24 +0900 templater: lift parsed and compiled templates to generic data types
Yuya Nishihara <yuya@tcha.org> [Sat, 13 Feb 2016 23:54:24 +0900] rev 28545
templater: lift parsed and compiled templates to generic data types Before this patch, parsed and compiled templates were kept as lists. That was inconvenient for applying transformation such as alias expansion. This patch changes the types of the outermost objects as follows: stage old new -------- -------------- ------------------------------ parsed [(op, ..)] ('template', [(op, ..)]) compiled [(func, data)] (runtemplate, [(func, data)]) New templater.parse() function has the same signature as revset.parse() and fileset.parse().
Tue, 15 Mar 2016 15:50:57 -0700 tests: python executable path should always be globbed
Danek Duvall <danek.duvall@oracle.com> [Tue, 15 Mar 2016 15:50:57 -0700] rev 28544
tests: python executable path should always be globbed Although this is coming in under the guise of consistency, part of the desire for this is that at least as part of the official Solaris builds, we build with a versioned python interpreter, such as "python2.7", which doesn't match "*python".
Mon, 14 Mar 2016 15:01:27 +0000 crecord: use ui.interface to choose curses interface
Simon Farnsworth <simonfar@fb.com> [Mon, 14 Mar 2016 15:01:27 +0000] rev 28543
crecord: use ui.interface to choose curses interface use ui.interface to select curses mode, instead of experimental.crecord
Mon, 14 Mar 2016 15:01:27 +0000 ui: add new config flag for interface selection
Simon Farnsworth <simonfar@fb.com> [Mon, 14 Mar 2016 15:01:27 +0000] rev 28542
ui: add new config flag for interface selection This patch introduces a new config flag ui.interface to select the interface for interactive commands. It currently only applies to chunks selection. The config can be overridden on a per feature basis with the flag ui.interface.<feature>. features for the moment can only be 'chunkselector', moving forward we expect to have 'histedit' and other commands there. If an incorrect value is given to ui.interface we print a warning and use the default interface: text. If HGPLAIN is specified we also use the default interface: text. Note that we fail quickly if a feature does not handle all the interfaces that we permit in ui.interface; in future, we could design a fallback path (e.g. blackpearl to curses, curses to text), but let's leave that until we need it.
Fri, 11 Mar 2016 10:30:08 +0000 extensions: also search for extension in the 'hgext3rd' package
Pierre-Yves David <pierre-yves.david@fb.com> [Fri, 11 Mar 2016 10:30:08 +0000] rev 28541
extensions: also search for extension in the 'hgext3rd' package Mercurial extensions are not meant to be normal python package/module. Yet the lack of an official location to install them means that a lot of them actually install as root level python package, polluting the global Python package namespace and risking collision with more legit packages. As we recently discovered, core python actually support namespace package. A way for multiples distinct "distribution" to share a common top level package without fear of installation headache. (Namespace package allow submodule installed in different location (of the 'sys.path') to be imported properly. So we are fine as long as extension includes a proper 'hgext3rd.__init__.py' to declare the namespace package.) Therefore we introduce a 'hgext3rd' namespace packages and search for extension in it. We'll then recommend third extensions to install themselves in it. Strictly speaking we could just get third party extensions to install in 'hgext' as it is also a namespace package. However, this would make the integration of formerly third party extensions in the main distribution more complicated as the third party install would overwrite the file from the main install. Moreover, having an explicit split between third party and core extensions seems like a good idea. The name 'hgext3rd' have been picked because it is short and seems explicit enough. Other alternative I could think of where: - hgextcontrib - hgextother - hgextunofficial
Sun, 13 Mar 2016 05:17:06 +0900 hgext: use templatekeyword to mark a function as template keyword
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sun, 13 Mar 2016 05:17:06 +0900] rev 28540
hgext: use templatekeyword to mark a function as template keyword This patch replaces registration of template keyword function in bundled extensions by registrar.templatekeyword decorator all at once.
Sun, 13 Mar 2016 05:17:06 +0900 templatekw: use templatekeyword to mark a function as template keyword
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sun, 13 Mar 2016 05:17:06 +0900] rev 28539
templatekw: use templatekeyword to mark a function as template keyword Using decorator can localize changes for adding (or removing) a template keyword function in source code. This patch also removes leading ":KEYWORD:" part in help document of each keywords, because using templatekeyword makes it useless. For similarity to decorator introduced by subsequent patches, this patch uses 'templatekeyword' instead of 'keyword' as a decorator name, even though the former is a little redundant in 'templatekw.py'. file name reason =================== ================= ================================== templatekw.py templatekeyword for similarity to others templatefilters.py templatefilter 'filter' hides Python built-in one templaters.py templatefunc 'func' is too generic
Sun, 13 Mar 2016 05:17:06 +0900 registrar: add templatekeyword to mark a function as template keyword (API)
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sun, 13 Mar 2016 05:17:06 +0900] rev 28538
registrar: add templatekeyword to mark a function as template keyword (API) _templateregistrarbase is defined as a super class of templatekeyword, for ease of adding template common features between "keyword", "filter" and "function". This patch also adds loadkeyword() to templatekw, because this combination helps to figure out how they cooperate with each other. Listing up loadkeyword() in dispatch.extraloaders causes implicit loading template keyword functions at loading (3rd party) extension. This change requires that "templatekeyword" attribute of (3rd party) extension is registrar.templatekeyword or so.
Wed, 16 Mar 2016 11:57:09 +0000 chgserver: do not keep repo object
Jun Wu <quark@fb.com> [Wed, 16 Mar 2016 11:57:09 +0000] rev 28537
chgserver: do not keep repo object The current chgserver design is to use one server to handle multiple repos which has same [extensions] config. Previously the client uses --cwd / to avoid creating a repo object. Now we need to set repo to None before we have code to make "serve" command norepo when it's chg.
Sat, 12 Mar 2016 04:24:11 +0000 chgserver: invalidate the server if extensions fail to load
Jun Wu <quark@fb.com> [Sat, 12 Mar 2016 04:24:11 +0000] rev 28536
chgserver: invalidate the server if extensions fail to load Previously, if extensions fail to load, chg server will just keep working without those extensions. It will print a warning message but only if a new server starts. This patch invalidates the server if any extension failed to load, but still serve the client (hopefully just) once. It will help chg pass some test cases of test-bad-extension.t.
Mon, 14 Mar 2016 13:48:33 +0000 chgserver: add an explicit "reconnect" instruction to validate
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 13:48:33 +0000] rev 28535
chgserver: add an explicit "reconnect" instruction to validate In some rare cases (next patch), we may want validate to do "unlink" without forcing the client reconnect. This patch addes a new "reconnect" instruction and makes "unlink" not to reconnect by default.
Mon, 14 Mar 2016 11:06:34 +0000 dispatch: flush ui before returning from dispatch
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 11:06:34 +0000] rev 28534
dispatch: flush ui before returning from dispatch A chg client may exit after received the result from runcommand. It is necessary to do a flush to make sure the warning message is printed out and the process waiting for the chg client will actually see the output. This helps chg to pass test-alias.t.
Tue, 15 Mar 2016 00:14:53 +0900 tests: make tests for convert with svn portable
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Tue, 15 Mar 2016 00:14:53 +0900] rev 28533
tests: make tests for convert with svn portable svn 1.6.x (at least, 1.6.12 or 1.6.17) might display empty lines, even though svn 1.9.x (at least, 1.9.3) doesn't. To make tests for convert with svn portable, this patch adds "|(^$)" regexp to egrep in filter_svn_output. To avoid similar future issue, this patch adds "|(^$)" regexp to all filter_svn_output (and adjusts test-subrepo-svn.t), even though only test-convert-svn-source.t fails with svn 1.6.x, AFAIK.
Tue, 15 Mar 2016 14:10:46 -0700 merge with stable
Matt Mackall <mpm@selenic.com> [Tue, 15 Mar 2016 14:10:46 -0700] rev 28532
merge with stable
Fri, 11 Mar 2016 20:34:49 -0500 test-pager: add a test for pager with color enabled
Augie Fackler <augie@google.com> [Fri, 11 Mar 2016 20:34:49 -0500] rev 28531
test-pager: add a test for pager with color enabled
Fri, 11 Mar 2016 11:37:00 -0500 http: support sending hgargs via POST body instead of in GET or headers
Augie Fackler <augie@google.com> [Fri, 11 Mar 2016 11:37:00 -0500] rev 28530
http: support sending hgargs via POST body instead of in GET or headers narrowhg (for its narrow spec) and remotefilelog (for its large batch requests) would like to be able to make requests with argument sets so absurdly large that they blow out total request size limit on some http servers. As a workaround, support stuffing args at the start of the POST body. We will probably want to leave this behavior off by default in servers forever, because it makes the old "POSTs are only for writes" assumption wrong, which might break some of the simpler authentication configurations.
Mon, 14 Mar 2016 21:15:59 -0400 fsmonitor: flag msc_stdint as no-check-code
Augie Fackler <augie@google.com> [Mon, 14 Mar 2016 21:15:59 -0400] rev 28529
fsmonitor: flag msc_stdint as no-check-code I'd rather not modify code that we're vendoring, so I'm just marking it this way.
Mon, 14 Mar 2016 17:53:47 +0100 fsmonitor: use custom stdint.h file when compiling with Visual C
Sune Foldager <sune.foldager@me.com> [Mon, 14 Mar 2016 17:53:47 +0100] rev 28528
fsmonitor: use custom stdint.h file when compiling with Visual C Visual C/C++ 9, which Python 2.7 is compatible with, doesn't have C99 support and thus doesn't contain a stdint.h file. This changeset adds a custom version of stdint.h, created specifically for Visual C, and uses it when building with that compiler.
Sun, 13 Mar 2016 02:36:03 +0100 tests: handle getaddrinfo reporting "No address associated with hostname"
Mads Kiilerich <madski@unity3d.com> [Sun, 13 Mar 2016 02:36:03 +0100] rev 28527
tests: handle getaddrinfo reporting "No address associated with hostname" This has been seen on some Fedora 23 systems.
Mon, 14 Mar 2016 14:08:28 -0700 httpconnection: remove obsolete comment about open()
Martin von Zweigbergk <martinvonz@google.com> [Mon, 14 Mar 2016 14:08:28 -0700] rev 28526
httpconnection: remove obsolete comment about open() When httpsendfile was moved from url.py into httpconnection.py in e7525a555a64 (url: use new http support if requested by the user, 2011-05-06), the comment about not being able to just call open() became obsolete.
Sun, 13 Mar 2016 14:03:58 -0700 sslutil: allow multiple fingerprints per host
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 13 Mar 2016 14:03:58 -0700] rev 28525
sslutil: allow multiple fingerprints per host Certificate pinning via [hostfingerprints] is a useful security feature. Currently, we only support one fingerprint per hostname. This is simple but it fails in the real world: * Switching certificates breaks clients until they change the pinned certificate fingerprint. This incurs client downtime and can require massive amounts of coordination to perform certificate changes. * Some servers operate with multiple certificates on the same hostname. This patch adds support for defining multiple certificate fingerprints per host. This overcomes the deficiencies listed above. I anticipate the primary use case of this feature will be to define both the old and new certificate so a certificate transition can occur with minimal interruption, so this scenario has been called out in the help documentation.
Sun, 13 Mar 2016 13:51:01 -0700 help: add empty lines to hostfingerprints section
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 13 Mar 2016 13:51:01 -0700] rev 28524
help: add empty lines to hostfingerprints section I think this is now much easier to read.
Sat, 12 Mar 2016 18:51:07 -0800 help: document requirements
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 Mar 2016 18:51:07 -0800] rev 28523
help: document requirements We didn't have unified documentation of the various repository requirements. This patch changes that.
Sun, 13 Mar 2016 01:59:18 +0530 showstack: use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Sun, 13 Mar 2016 01:59:18 +0530] rev 28522
showstack: use absolute_import
Mon, 14 Mar 2016 14:12:13 +0530 contrib: use absolute_import in win32/hgwebdir_wsgi.py
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 14 Mar 2016 14:12:13 +0530] rev 28521
contrib: use absolute_import in win32/hgwebdir_wsgi.py
Sun, 27 Dec 2015 13:38:46 +0900 dispatch: catch KeyboardInterrupt more broadly
Yuya Nishihara <yuya@tcha.org> [Sun, 27 Dec 2015 13:38:46 +0900] rev 28520
dispatch: catch KeyboardInterrupt more broadly Because _runcatch() can run long operations in its exception handler, it wasn't enough to catch KeyboardInterrupt at the same level. For example, "hg unknown" will load all extension modules, so we could easily make it crashed by Ctrl-C.
Sun, 13 Mar 2016 16:46:49 -0700 histedit: have dropmissing abort on empty plan
Mateusz Kwapich <mitrandir@fb.com> [Sun, 13 Mar 2016 16:46:49 -0700] rev 28519
histedit: have dropmissing abort on empty plan We noticed that many users have the intuition of laving the editor empty when they want to abort the operation. The fact that dropmissing allows user to delete all edited commits is not intuitive even for users that asked for it. Let's prevent people from this footgun.
Sun, 13 Mar 2016 02:29:11 +0100 streamclone: fix error when store files grow while stream cloning stable
Mads Kiilerich <madski@unity3d.com> [Sun, 13 Mar 2016 02:29:11 +0100] rev 28518
streamclone: fix error when store files grow while stream cloning Effectively a backout of 9fea6b38a8da, but updated to using 'with'.
Sun, 13 Mar 2016 02:28:46 +0100 tests: add test of stream clone of repo that is changing stable
Mads Kiilerich <madski@unity3d.com> [Sun, 13 Mar 2016 02:28:46 +0100] rev 28517
tests: add test of stream clone of repo that is changing This reveals an error introduced by 9fea6b38a8da.
Mon, 14 Mar 2016 12:52:35 +0000 chgserver: handle ParseError during validate
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 12:52:35 +0000] rev 28516
chgserver: handle ParseError during validate Currently the validate command in chgserver expects config can be loaded without issues but the config can be broken and chg will print a stacktrace instead of the parsing error, if a chg server is already running. This patch adds a handler for ParseError in validate and a new instruction "exit" to make the client exit without abortmsg. A test is also added to make sure it will behave as expected.
Mon, 14 Mar 2016 12:32:09 +0000 dispatch: extract common logic for handling ParseError
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 12:32:09 +0000] rev 28515
dispatch: extract common logic for handling ParseError The way ParseError is handled at two different places in dispatch.py is the same. Move common logic into _formatparse.
Mon, 14 Mar 2016 11:23:04 +0000 chgserver: resolve relative path before sending via system channel
Jun Wu <quark@fb.com> [Mon, 14 Mar 2016 11:23:04 +0000] rev 28514
chgserver: resolve relative path before sending via system channel The chgserver may have a different cwd from the client because of the side effect of "--cwd" and other possible os.chdir done by extensions. Therefore relative paths can be misunderstood by the client. This patch solves it by expanding relative cwd path to absolute one before sending them via the 'S' channel. It can help chg to pass a testcase in test-alias.t later.
Sat, 12 Mar 2016 13:19:19 -0800 mercurial: use pure Python module policy on Python 3
Gregory Szorc <gregory.szorc@gmail.com> [Sat, 12 Mar 2016 13:19:19 -0800] rev 28513
mercurial: use pure Python module policy on Python 3 The C extensions don't yet work with Python 3. Let's minimize the work required to get Mercurial running on Python 3 by always using the pure Python module policy on Python 3.
Sat, 12 Mar 2016 22:17:30 +0900 chg: provide early exception to user
Yuya Nishihara <yuya@tcha.org> [Sat, 12 Mar 2016 22:17:30 +0900] rev 28512
chg: provide early exception to user See the previous patch for details. Since the socket will be closed by the server, handleresponse() will never return: Traceback (most recent call last): ... chg: abort: failed to read channel
Sat, 12 Mar 2016 22:03:30 +0900 cmdserver: write early exception to 'e' channel in 'unix' mode
Yuya Nishihara <yuya@tcha.org> [Sat, 12 Mar 2016 22:03:30 +0900] rev 28511
cmdserver: write early exception to 'e' channel in 'unix' mode In 'unix' mode, the server is typically detached from the console. Therefore a client couldn't see the exception that occurred while instantiating the server object. This patch tries to catch the early error and send it to 'e' channel even if the server isn't instantiated yet. This means the error may be sent before the initial hello message. So it's up to the client implementation whether to handle the early error message or error out as protocol violation. The error handling code is also copied to chgserver.py. I'll factor out them later if we manage to get chg passes the test suite.
Sun, 13 Mar 2016 01:32:42 +0530 contrib: make memory.py use absolute_import
Pulkit Goyal <7895pulkit@gmail.com> [Sun, 13 Mar 2016 01:32:42 +0530] rev 28510
contrib: make memory.py use absolute_import
Sun, 13 Mar 2016 01:08:39 +0530 check-code: use absolute_import and print_function
Pulkit Goyal <7895pulkit@gmail.com> [Sun, 13 Mar 2016 01:08:39 +0530] rev 28509
check-code: use absolute_import and print_function
Fri, 11 Mar 2016 21:27:26 -0800 encoding: use range() instead of xrange()
Gregory Szorc <gregory.szorc@gmail.com> [Fri, 11 Mar 2016 21:27:26 -0800] rev 28508
encoding: use range() instead of xrange() Python 3 doesn't have xrange(). Instead, range() on Python 3 is a generator, like xrange() is on Python 2. The benefits of xrange() over range() are when there are very large ranges that are too expensive to pre-allocate. The code here is only creating <128 values, so the benefits of xrange() should be negligible. With this patch, encoding.py imports safely on Python 3.
Fri, 11 Mar 2016 21:23:34 -0800 encoding: make HFS+ ignore code Python 3 compatible
Gregory Szorc <gregory.szorc@gmail.com> [Fri, 11 Mar 2016 21:23:34 -0800] rev 28507
encoding: make HFS+ ignore code Python 3 compatible unichr() doesn't exist in Python 3. chr() is the equivalent there. Unfortunately, we can't use chr() outright because Python 2 only accepts values smaller than 256. Also, Python 3 returns an int when accessing a character of a bytes type (s[x]). So, we have to ord() the values in the assert statement.
Fri, 11 Mar 2016 10:28:58 +0000 extensions: factor import error reporting out
Pierre-Yves David <pierre-yves.david@fb.com> [Fri, 11 Mar 2016 10:28:58 +0000] rev 28506
extensions: factor import error reporting out To clarify third party extensions lookup, we are about to add a third place where extensions are searched for. So we factor the error reporting logic out to be able to easily reuse it in the next patch.
Fri, 11 Mar 2016 10:24:54 +0000 extensions: extract the 'importh' closure as normal function
Pierre-Yves David <pierre-yves.david@fb.com> [Fri, 11 Mar 2016 10:24:54 +0000] rev 28505
extensions: extract the 'importh' closure as normal function There is no reason for this to be a closure so we extract it for clarity.
Fri, 11 Mar 2016 15:40:58 -0800 zeroconf: remove leftover camelcase identifier
Martin von Zweigbergk <martinvonz@google.com> [Fri, 11 Mar 2016 15:40:58 -0800] rev 28504
zeroconf: remove leftover camelcase identifier eb9d0e828c30 (zeroconf: remove camelcase in identifiers, 2016-03-01) forgot one occurrence of "numAuthorities", which makes test-paths.t fail for me. I don't even know what zeroconf is, but this patch seems obviously correct and it fixes the failing test case.
Sat, 12 Mar 2016 04:35:42 +0900 hg: acquire wlock while updating the working directory via updatetotally
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 12 Mar 2016 04:35:42 +0900] rev 28503
hg: acquire wlock while updating the working directory via updatetotally updatetotally() might be invoked outside wlock scope (e.g. invocation via postincoming() at "hg unbundle" or "hg pull"). In such case, acquisition of wlock is needed for consistent view, because parallel "hg update" and/or "hg bookmarks" might change working directory status while executing updatetotally(). Strictly speaking, truly consistent updating should acquire also store lock, because active bookmark might be moved to another one outside wlock scope (e.g. pulling from other repository causes updating current active one). Acquisition of wlock in this patch ensures consistency in as same level as past "hg update".
Sat, 12 Mar 2016 04:35:42 +0900 commands: add postincoming docstring for explanation of arguments
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 12 Mar 2016 04:35:42 +0900] rev 28502
commands: add postincoming docstring for explanation of arguments
Sat, 12 Mar 2016 04:35:42 +0900 commands: centralize code to update with extra care for non-file components
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 12 Mar 2016 04:35:42 +0900] rev 28501
commands: centralize code to update with extra care for non-file components This patch centralizes similar code paths to update the working directory with extra care for non-file components (e.g. bookmark) into newly added function updatetotally(). 'if True' at the beginning of updatetotally() is redundant at this patch, but useful to reduce amount of changes in subsequent patch.
Sat, 12 Mar 2016 04:35:42 +0900 update: omit redundant activating message for already active bookmark
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Sat, 12 Mar 2016 04:35:42 +0900] rev 28500
update: omit redundant activating message for already active bookmark This patch also adds "hg bookmarks" invocation into tests, where redundant message is omitted but bookmark activity isn't clear from context.
Fri, 11 Mar 2016 11:44:03 -0800 tests: make test-verify-repo-operations.py not run by default
Martin von Zweigbergk <martinvonz@google.com> [Fri, 11 Mar 2016 11:44:03 -0800] rev 28499
tests: make test-verify-repo-operations.py not run by default test-verify-repo-operations.py currently starts way too late and extends the running time with -j50 on my machine from around 3:48 min to 6:30 min. We could of course make it run earlier, but the test case seems unlikely to find bugs not covered by other tests, so let's mark it "slow" instead. I think this type of test is better suited to running separately in a long-running job.
Fri, 29 Jan 2016 14:37:16 +0000 ui: log devel warnings
timeless <timeless@mozdev.org> [Fri, 29 Jan 2016 14:37:16 +0000] rev 28498
ui: log devel warnings
Fri, 11 Mar 2016 17:22:04 +0000 util: refactor getstackframes
timeless <timeless@mozdev.org> [Fri, 11 Mar 2016 17:22:04 +0000] rev 28497
util: refactor getstackframes
Fri, 11 Mar 2016 16:50:14 +0000 util: reword debugstacktrace comment
timeless <timeless@mozdev.org> [Fri, 11 Mar 2016 16:50:14 +0000] rev 28496
util: reword debugstacktrace comment
Sun, 06 Mar 2016 15:40:20 -0800 changelog: avoid slicing raw data until needed
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 15:40:20 -0800] rev 28495
changelog: avoid slicing raw data until needed Before, we were slicing the original raw text and storing individual variables with values corresponding to each field. This is avoidable overhead. With this patch, we store the offsets of the fields at construction time and perform the slice when a property is accessed. This appears to show a very marginal performance win on its own and the gains are so small as to not be worth reporting. However, this patch marks the end of our parsing refactor, so it is worth reporting the gains from the entire series: author(mpm) 0.896565 0.795987 89% desc(bug) 0.887169 0.803438 90% date(2015) 0.878797 0.773961 88% extra(rebase_source) 0.865446 0.761603 88% author(mpm) or author(greg) 1.801832 1.576025 87% author(mpm) or desc(bug) 1.812438 1.593335 88% date(2015) or branch(default) 0.968276 0.875270 90% author(mpm) or desc(bug) or date(2015) or extra(rebase_source) 3.656193 3.183104 87% Pretty consistent speed-up across the board for any revset accessing changelog revision data. Not bad! It's also worth noting that PyPy appears to experience a similar to marginally greater speed-up as well! According to statprof, revsets accessing changelog revision data are now clearly dominated by zlib decompression (16-17% of execution time). Surprisingly, it appears the most expensive part of revision parsing are the various text.index() calls to search for newlines! These appear to cumulatively add up to 5+% of execution time. I reckon implementing the parsing in C would make things marginally faster. If accessing larger strings (such as the commit message), encoding.tolocal() is the most expensive procedure outside of decompression.
Sun, 06 Mar 2016 13:13:54 -0800 changelog: parse description last
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 13:13:54 -0800] rev 28494
changelog: parse description last Before, we first searched for the double newline as the first step in the parse then moved to the front of the string and worked our way to the back again. This made sense when we were splitting the raw text on the double newline. But in our new newline scanning based approach, this feels awkward. This patch updates the parsing logic to parse the text linearly and deal with the description field last. Because we're avoiding an extra string scan, revsets appear to demonstrate a very slight performance win. But the percentage change is marginal, so the numbers aren't worth reporting.
Sun, 06 Mar 2016 14:31:06 -0800 changelog: lazily parse files
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 14:31:06 -0800] rev 28493
changelog: lazily parse files More of the same. Again, modest revset performance wins: author(mpm) 0.896565 0.822961 0.805156 desc(bug) 0.887169 0.847054 0.798101 date(2015) 0.878797 0.811613 0.786689 extra(rebase_source) 0.865446 0.797756 0.777408 author(mpm) or author(greg) 1.801832 1.668172 1.626547 author(mpm) or desc(bug) 1.812438 1.677608 1.613941 date(2015) or branch(default) 0.968276 0.896032 0.869017
Sun, 06 Mar 2016 14:30:25 -0800 changelog: lazily parse date/extra field
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 14:30:25 -0800] rev 28492
changelog: lazily parse date/extra field This is probably the most complicated patch in the parsing refactor. Because the date and extras are encoded in the same field, we stuff the entire field into a dedicated variable and add a property for accessing the sub-components of each. There is some duplicated code here. But the code is relatively simple, so it shouldn't be a big deal. We see revset performance wins across the board: author(mpm) 0.896565 0.876713 0.822961 desc(bug) 0.887169 0.895514 0.847054 date(2015) 0.878797 0.820987 0.811613 extra(rebase_source) 0.865446 0.823811 0.797756 author(mpm) or author(greg) 1.801832 1.784160 1.668172 author(mpm) or desc(bug) 1.812438 1.822756 1.677608 date(2015) or branch(default) 0.968276 0.910981 0.896032 author(mpm) or desc(bug) or date(2015) or extra(rebase_source) 3.656193 3.516788 3.265024 We see a speed-up on revsets accessing date and extras because the new parsing code only parses what you access. Even though they are stored the same text field, we avoid parsing dates when accessing extras and vice-versa. But strangely revsets accessing both date and extras appeared to speed up as well! I'm not sure if this is due to refactoring the parsing code or due to an optimization in revsets. You can't argue with the results!
Sun, 06 Mar 2016 14:29:46 -0800 changelog: lazily parse user
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 14:29:46 -0800] rev 28491
changelog: lazily parse user Same strategy as before. Revsets not accessing the user demonstrate a slight performance win: desc(bug) 0.887169 0.910400 0.895514 date(2015) 0.878797 0.870697 0.820987 extra(rebase_source) 0.865446 0.841644 0.823811 date(2015) or branch(default) 0.968276 0.945792 0.910981
Sun, 06 Mar 2016 14:29:13 -0800 changelog: lazily parse manifest node
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 14:29:13 -0800] rev 28490
changelog: lazily parse manifest node Like the description, we store the raw bytes and convert from hex on access. This patch also marks the beginning of our new parsing method, which is based on newline offsets and doesn't rely on str.split(). Many revsets showed a performance improvement: author(mpm) 0.896565 0.869085 0.868598 desc(bug) 0.887169 0.928164 0.910400 extra(rebase_source) 0.865446 0.871500 0.841644 author(mpm) or author(greg) 1.801832 1.791589 1.731503 author(mpm) or desc(bug) 1.812438 1.851003 1.798764 date(2015) or branch(default) 0.968276 0.974027 0.945792
Sun, 06 Mar 2016 14:28:46 -0800 changelog: lazily parse description
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 14:28:46 -0800] rev 28489
changelog: lazily parse description Before, the description field was converted to a localstr at parse time. With this patch, we store the raw description and convert to a localstr when it is first accessed. We see a revset speedup for revsets that don't access the description: author(mpm) 0.896565 0.914234 0.869085 date(2015) 0.878797 0.891980 0.862525 extra(rebase_source) 0.865446 0.912514 0.871500 author(mpm) or author(greg) 1.801832 1.860402 1.791589 date(2015) or branch(default) 0.968276 0.994673 0.974027 author(mpm) or desc(bug) or date(2015) or extra(rebase_source) 3.656193 3.721032 3.643593 As you can see, most of these revsets are already faster than from before this refactoring: we have already offset the performance loss from the introduction of the new class representing parsed changelog entries!
Sun, 06 Mar 2016 13:26:37 -0800 context: use changelogrevision
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 13:26:37 -0800] rev 28488
context: use changelogrevision Upcoming patches will make the changelogrevision object perform lazy parsing. Let's switch to it. Because we're switching from a tuple to an object, everthing that accesses the internal cached attribute needs to be updated to access via attributes. A nice side-effect is this makes the code easier to read! Surprisingly, this appears to make revsets accessing this data slightly faster (values are before series, p1, this patch): author(mpm) 0.896565 0.929984 0.914234 desc(bug) 0.887169 0.935642 0.921073 date(2015) 0.878797 0.908094 0.891980 extra(rebase_source) 0.865446 0.922624 0.912514 author(mpm) or author(greg) 1.801832 1.902112 1.860402 author(mpm) or desc(bug) 1.812438 1.860977 1.844850 date(2015) or branch(default) 0.968276 1.005824 0.994673 author(mpm) or desc(bug) or date(2015) or extra(rebase_source) 3.656193 3.743381 3.721032
Sun, 06 Mar 2016 14:28:02 -0800 changelog: add class to represent parsed changelog revisions
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 06 Mar 2016 14:28:02 -0800] rev 28487
changelog: add class to represent parsed changelog revisions Currently, changelog entries are parsed into their respective components at read time. Many operations are only interested in a subset of fields of a changelog entry. The parsing and storing of all the fields adds avoidable overhead. This patch introduces the "changelogrevision" class. It takes changelog raw text and exposes the parsed results as attributes. The code for parsing changelog entries has been moved into its construction function. changelog.read() has been modified to use the new class internally while maintaining its existing API. Future patches will make revision parsing lazy. We implement the construction function of the new class with __new__ instead of __init__ so we can use a named tuple to represent the empty revision. This saves overhead and complexity of coercing later versions of this class to represent an empty instance. While we are here, we add a method on changelog to obtain an instance of the new type. The overhead of constructing the new class regresses performance of revsets accessing this data: author(mpm) 0.896565 0.929984 desc(bug) 0.887169 0.935642 105% date(2015) 0.878797 0.908094 extra(rebase_source) 0.865446 0.922624 106% author(mpm) or author(greg) 1.801832 1.902112 105% author(mpm) or desc(bug) 1.812438 1.860977 date(2015) or branch(default) 0.968276 1.005824 author(mpm) or desc(bug) or date(2015) or extra(rebase_source) 3.656193 3.743381 Once lazy parsing is implemented, these revsets will all be faster than before. There is no performance change on revsets that do not access this data. There /could/ be a performance regression on operations that perform several changelog reads. However, I can't think of anything outside of revsets and `hg log` (basically the same as a revset) that would be impacted.
Fri, 11 Mar 2016 11:51:22 -0500 httppeer: compute header names only once
Augie Fackler <augie@google.com> [Fri, 11 Mar 2016 11:51:22 -0500] rev 28486
httppeer: compute header names only once This also helps make the code a little more readable.
Fri, 11 Mar 2016 11:33:43 -0500 httppeer: indent existing argument handling with if True
Augie Fackler <augie@google.com> [Fri, 11 Mar 2016 11:33:43 -0500] rev 28485
httppeer: indent existing argument handling with if True I'm about to add another case, so it makes sense to split this out to make the semantic changes in the next change more obvious.
Fri, 11 Mar 2016 11:26:12 -0500 httppeer: move size computation later in _callstream
Augie Fackler <augie@google.com> [Fri, 11 Mar 2016 11:26:12 -0500] rev 28484
httppeer: move size computation later in _callstream A future change will alter some of the arg-sending logic in a way that matters for request body size. Centralizing the logic now will make later patches easier to review.
Fri, 11 Mar 2016 11:24:50 -0500 httppeer: do less splitting on httpheader value
Augie Fackler <augie@google.com> [Fri, 11 Mar 2016 11:24:50 -0500] rev 28483
httppeer: do less splitting on httpheader value We only care about the first value split off, so only split off the first value.
Sat, 27 Feb 2016 21:17:37 +0900 chgserver: remove outdated comment about setvbuf()
Yuya Nishihara <yuya@tcha.org> [Sat, 27 Feb 2016 21:17:37 +0900] rev 28482
chgserver: remove outdated comment about setvbuf() I've replaced setvbuf() by fdopen() before merging chg into the core, so this comment is wrong. https://bitbucket.org/yuja/chg/commits/5c24e72bc447
Tue, 01 Mar 2016 04:53:43 +0000 transplant: use absolute_import
timeless <timeless@mozdev.org> [Tue, 01 Mar 2016 04:53:43 +0000] rev 28481
transplant: use absolute_import
Fri, 11 Mar 2016 16:07:22 +0000 transplant: switch to using nodemod for hex+short
timeless <timeless@mozdev.org> [Fri, 11 Mar 2016 16:07:22 +0000] rev 28480
transplant: switch to using nodemod for hex+short
Wed, 02 Mar 2016 16:32:52 +0000 convert: bzr use absolute_import
timeless <timeless@mozdev.org> [Wed, 02 Mar 2016 16:32:52 +0000] rev 28479
convert: bzr use absolute_import
Fri, 11 Mar 2016 13:00:20 +0000 chgserver: include [extdiff] in confighash
Jun Wu <quark@fb.com> [Fri, 11 Mar 2016 13:00:20 +0000] rev 28478
chgserver: include [extdiff] in confighash extdiff's uisetup will register new commands. If we do not include it in confighash, changes to [extdiff] will not get new commands registered. This patch adds extdiff to confighash and makes it possible for chg to pass test-extdiff.t.
Fri, 11 Mar 2016 02:52:06 +0000 chg: silently inherit server exit code
Jun Wu <quark@fb.com> [Fri, 11 Mar 2016 02:52:06 +0000] rev 28477
chg: silently inherit server exit code If chgserver aborts during startup, for example, error.ParseError when parsing a config file, chg client probably just wants to exit with a same exit code without printing other unrelated text. This patch changes the text "cmdserver exited with status" from abortmsg to debugmsg and exits with a same exit code.
(0) -10000 -3000 -1000 -128 +128 +1000 +3000 +10000 tip