Tue, 27 Jun 2017 01:36:20 +0200 obsutil: move 'allsuccessors' to the new modules
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 27 Jun 2017 01:36:20 +0200] rev 33151
obsutil: move 'allsuccessors' to the new modules We have a new 'obsutil' module now. We move the high level utility there to bring 'obsolete.py' back to a more reasonable size.
Tue, 27 Jun 2017 01:31:18 +0200 obsutil: move 'allprecursors' to the new modules
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 27 Jun 2017 01:31:18 +0200] rev 33150
obsutil: move 'allprecursors' to the new modules We have a new 'obsutil' module now. We move the high level utility there to bring 'obsolete.py' back to a more reasonable size.
Tue, 27 Jun 2017 01:11:56 +0200 obsutil: move 'exclusivemarkers' to the new modules
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 27 Jun 2017 01:11:56 +0200] rev 33149
obsutil: move 'exclusivemarkers' to the new modules We have a new 'obsutil' module now. We move the high level utility there to bring 'obsolete.py' back to a more reasonable size.
Tue, 27 Jun 2017 01:03:01 +0200 obsutil: move 'successorssets' to the new modules
Pierre-Yves David <pierre-yves.david@octobus.net> [Tue, 27 Jun 2017 01:03:01 +0200] rev 33148
obsutil: move 'successorssets' to the new modules We have a new 'obsutil' module now. We move this high level utility there to bring 'obsolete.py' back to a more reasonable size.
Thu, 29 Jun 2017 11:29:19 -0700 tests: fix variable name regular expression in _genrestoreenv()
Adam Simpkins <simpkins@fb.com> [Thu, 29 Jun 2017 11:29:19 -0700] rev 33147
tests: fix variable name regular expression in _genrestoreenv() Update the code to correctly anchor the expression on the end of the name, to require that the entire name match this expression. It was already anchored at the start by using re.match(), but this does not anchor it at the end.
Thu, 29 Jun 2017 15:21:52 -0700 merge with stable
Martin von Zweigbergk <martinvonz@google.com> [Thu, 29 Jun 2017 15:21:52 -0700] rev 33146
merge with stable
Wed, 28 Jun 2017 17:41:25 +0200 pushrace: avoid crash on bare push when using concurrent push mode
Pierre-Yves David <pierre-yves.david@octobus.net> [Wed, 28 Jun 2017 17:41:25 +0200] rev 33145
pushrace: avoid crash on bare push when using concurrent push mode If the remote is empty, we do now bother computing head changes and the 'pushbranchmap' attribute stays at None. We now handle and tests this case.
Sun, 25 Jun 2017 22:20:37 -0700 show: config option to register aliases for views
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 25 Jun 2017 22:20:37 -0700] rev 33144
show: config option to register aliases for views As part of using `hg show` in my daily workflow, I've found it slightly annoying to have to type full view names, complete with a space. I've locally registered an alias for "swork = show work." I think others will have this same complaint and could benefit from some automation to streamline the creation of aliases. So, this commit introduces a config option that allows `hg show` views to be automatically aliased using a given prefix. e.g. a value of "s" will automatically register "swork" and "sbookmarks." Multiple values can be given for ultimate flexibility. This arguably isn't needed now. But since we don't register aliases if there will be a collision and we're bound to have a collision, it makes sense to allow multiple prefixes so specific views can avoid collisions by using different prefixes.
Sun, 18 Jun 2017 20:49:08 +0200 blackbox: use a human readable version of the default
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 18 Jun 2017 20:49:08 +0200] rev 33143
blackbox: use a human readable version of the default Now that the default value is also converted we can use a human readable version for it. This will be useful if we start to automatically display the default config value in various place.
Sat, 17 Jun 2017 13:21:06 +0200 configitems: register 'blackbox.maxsize' as an example of 'configbytes'
Pierre-Yves David <pierre-yves.david@octobus.net> [Sat, 17 Jun 2017 13:21:06 +0200] rev 33142
configitems: register 'blackbox.maxsize' as an example of 'configbytes' This exercise the default value handling in 'configbytes'.
Sat, 17 Jun 2017 13:41:28 +0200 blackbox: minor code reordering
Pierre-Yves David <pierre-yves.david@octobus.net> [Sat, 17 Jun 2017 13:41:28 +0200] rev 33141
blackbox: minor code reordering The version declaration should come first in my opinion. This will help gather the command table with the config table.
Sun, 18 Jun 2017 19:52:54 +0200 configitems: add a devel warning for extensions items overiding core one
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 18 Jun 2017 19:52:54 +0200] rev 33140
configitems: add a devel warning for extensions items overiding core one We do not want such case to pass silently. In the future we'll likely have useful tool for an extension to alter the existing definition in core.
Sat, 17 Jun 2017 13:48:20 +0200 configitems: add an official API for extensions to register config item
Pierre-Yves David <pierre-yves.david@octobus.net> [Sat, 17 Jun 2017 13:48:20 +0200] rev 33139
configitems: add an official API for extensions to register config item Extensions can have a 'configtable' mapping and use 'registrar.configitem(table)' to retrieve the registration function. This behave in the same way as the other way for extensions to register new items (commands, colors, etc).
Sat, 17 Jun 2017 13:38:53 +0200 configitems: extract the logic to build a registrar on any configtable
Pierre-Yves David <pierre-yves.david@octobus.net> [Sat, 17 Jun 2017 13:38:53 +0200] rev 33138
configitems: extract the logic to build a registrar on any configtable Having the logic available independently from the mapping used is a necessary step toward extensions support.
Mon, 19 Jun 2017 01:08:11 +0200 obsolete: skip 'changectx' usage in unstable computation
Pierre-Yves David <pierre-yves.david@octobus.net> [Mon, 19 Jun 2017 01:08:11 +0200] rev 33137
obsolete: skip 'changectx' usage in unstable computation We simplify the unstable computation code, skipping the expensive creation of changectx object. We focus on efficient set operation and revnumber centric functions. In my mercurial development repository, this provides a 3x speedup to the function: before: 5.319 ms after: 1.844 ms repo details: total changesets: 40886 obsolete changesets: 7756 mutable (not obsolete): 293 unstable: 30
Sun, 18 Jun 2017 22:38:11 +0200 obsolete: provide a small function to retrieve all mutable revisions
Pierre-Yves David <pierre-yves.david@octobus.net> [Sun, 18 Jun 2017 22:38:11 +0200] rev 33136
obsolete: provide a small function to retrieve all mutable revisions More obsolescence related algorithm focus on the mutable revision. We provide a tiny utility function to make it easy to access this set.
Tue, 27 Jun 2017 14:38:00 -0700 bundle2: add debug info about the number of stream params
Siddharth Agarwal <sid0@fb.com> [Tue, 27 Jun 2017 14:38:00 -0700] rev 33135
bundle2: add debug info about the number of stream params Seems like the %i was never substituted.
Tue, 27 Jun 2017 14:30:55 -0700 bundle2: add some debugging information to the not-a-bundle error
Siddharth Agarwal <sid0@fb.com> [Tue, 27 Jun 2017 14:30:55 -0700] rev 33134
bundle2: add some debugging information to the not-a-bundle error I found this useful while trying to debug wireproto-related issues.
Wed, 28 Jun 2017 12:23:22 -0700 tests: more completely restore the environment in syshgenv
Adam Simpkins <simpkins@fb.com> [Wed, 28 Jun 2017 12:23:22 -0700] rev 33133
tests: more completely restore the environment in syshgenv Update the syshgenv function to attempt to completely restore the original environment, rather than only updating a few specific variables. run_tests.py now generates a shell script that can be used to restore the original environment, and syshgenv sources it. This is a bit more complicated than the previous code, but should do a better job of running the system hg in the correct environment. I've tested it on Linux using python 2.x, but let me know if it causes issues in other environments. I'm not terribly familiar with how the tests get run on Windows, for instance, and how the environment needs to be updated there.
Wed, 28 Jun 2017 13:45:51 -0700 tests: do not use system hg if it does not have "files" command
Jun Wu <quark@fb.com> [Wed, 28 Jun 2017 13:45:51 -0700] rev 33132
tests: do not use system hg if it does not have "files" command Ancient hg does not have "hg files" so test-check-*.t will fail with "unknown command 'files'": $ hg files hg: unknown command 'files' $ hg --version Mercurial Distributed SCM (version 2.6.2) Test "hg files" and give up using syshg if it does not have "files" command.
Wed, 28 Jun 2017 10:50:37 -0700 setup: fix runcmd() usage on darwin
Adam Simpkins <simpkins@fb.com> [Wed, 28 Jun 2017 10:50:37 -0700] rev 33131
setup: fix runcmd() usage on darwin Fix one invocation of runcmd() that was missed in the recent change to make runcmd() also return the process exit status.
Tue, 27 Jun 2017 21:16:08 +0530 py3: update the python3-whitelist with new tests which pass on Python 3
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 27 Jun 2017 21:16:08 +0530] rev 33130
py3: update the python3-whitelist with new tests which pass on Python 3 We have now 34 tests passing on Python 3.
Wed, 28 Jun 2017 06:49:01 -0700 setup: fix localhgenv
Jun Wu <quark@fb.com> [Wed, 28 Jun 2017 06:49:01 -0700] rev 33129
setup: fix localhgenv It should return env as a dict instead of None.
Tue, 27 Jun 2017 17:24:31 -0700 tests: use the system hg for examining the local repository
Adam Simpkins <simpkins@fb.com> [Tue, 27 Jun 2017 17:24:31 -0700] rev 33128
tests: use the system hg for examining the local repository Most test scripts use "hg" to interact with a temporary test repository. However a few tests also want to run hg commands to interact with the local repository containing the mercurial source code. Notably, many of the test-check-* tests want to check local files and commit messages. These tests were previously using the version of hg being tested to query the source repository. However, this will fail if the source repository requires extensions or other settings not supported by the version of mercurial being tested. The source repository was typically initially cloned using the system hg installation, so we should use the system hg installation to query it. There was already a helpers-testrepo.sh script designed to help cope with different requirements for the source repository versus the test repositories. However, it only handled the evolve extension. This new behavior works with any extensions that are different between the system installation and the test installation.
Tue, 27 Jun 2017 17:24:31 -0700 tests: save the original PATH and PYTHONPATH variables
Adam Simpkins <simpkins@fb.com> [Tue, 27 Jun 2017 17:24:31 -0700] rev 33127
tests: save the original PATH and PYTHONPATH variables When running the tests, define ORIG_PATH and ORIG_PYTHONPATH environment variables that contain the original contents of PATH and PYTHONPATH, before they were modified by run-tests.py This will make it possible for tests to refer to the original contents of these variables if necessary. In particular, this is necessary for invoking the correct version of hg for examining the local repository (the mercurial repository itself, not the temporary test repositories). Various tests examine the local repository to check the file lists and contents of commit messages.
Tue, 27 Jun 2017 16:15:32 -0700 setup: prefer using the system hg to interact with the local repository
Adam Simpkins <simpkins@fb.com> [Tue, 27 Jun 2017 16:15:32 -0700] rev 33126
setup: prefer using the system hg to interact with the local repository Add a findhg() function that tries to be smarter about figuring out how to run hg for examining the local repository. It first tries running "hg" from the user's PATH, with the default HGRCPATH settings intact, but with HGPLAIN enabled. This will generally use the same version of mercurial and the same settings used to originally clone the repository, and should have a higher chance of working successfully than trying to run the hg script from the local repository. If that fails findhg() falls back to the existing behavior of running the local hg script.
Tue, 27 Jun 2017 16:15:32 -0700 setup: replace runhg() with an hgcommand helper class
Adam Simpkins <simpkins@fb.com> [Tue, 27 Jun 2017 16:15:32 -0700] rev 33125
setup: replace runhg() with an hgcommand helper class Replace the runhg() function with an hgcommand helper class. hgcommand has as run() function similar to runhg(), but no longer requires the caller to pass in the exact path to python and the hg script, and the environment settings for invoking hg. For now this diff contains no behavior changes, but in the future this will make it easier for the hgcommand helper class to more intelligently figure out the proper way to invoke hg.
Mon, 26 Jun 2017 11:31:30 -0700 setup: move environment computation into a helper function
Adam Simpkins <simpkins@fb.com> [Mon, 26 Jun 2017 11:31:30 -0700] rev 33124
setup: move environment computation into a helper function Add a helper function to compute the environment used for invoking mercurial, rather than doing this computation entirely at global scope. This will make it easier to do some subsequent refactoring.
Mon, 26 Jun 2017 11:31:30 -0700 setup: update runcmd() to also return the exit status
Adam Simpkins <simpkins@fb.com> [Mon, 26 Jun 2017 11:31:30 -0700] rev 33123
setup: update runcmd() to also return the exit status Update the runcmd() helper function so it also returns the process exit status. This allows callers to more definitively determine if a command failed, rather than testing only for the presence of data on stderr. I don't expect this to have any behavioral changes for now: the commands invoked by setup generally should print data on stderr if and only if they failed.
Mon, 26 Jun 2017 11:31:30 -0700 setup: fail if we cannot determine the version number
Adam Simpkins <simpkins@fb.com> [Mon, 26 Jun 2017 11:31:30 -0700] rev 33122
setup: fail if we cannot determine the version number If running hg fails, exit the setup script unsuccessfully, rather than proceeding to use a bogus version of "+0-". Using an invalid version number causes various tests to fail later. Failing early makes it easier to identify the source of the problem. It is currently easy for setup.py to fail this way since it sets HGRCPTH to the empty string before running "hg", which may often disable extensions necessary to interact with the local repository.
Tue, 27 Jun 2017 23:50:22 +0900 smartset: fix generatorset.last() to not return the first element (issue5609)
Yuya Nishihara <yuya@tcha.org> [Tue, 27 Jun 2017 23:50:22 +0900] rev 33121
smartset: fix generatorset.last() to not return the first element (issue5609)
Mon, 26 Jun 2017 21:11:02 -0700 strip: respect the backup option in stripcallback
Jun Wu <quark@fb.com> [Mon, 26 Jun 2017 21:11:02 -0700] rev 33120
strip: respect the backup option in stripcallback The backup option was mistakenly ignored. It should be respected. Thanks Martin von Zweigbergk for finding this out!
Mon, 26 Jun 2017 23:58:27 +0530 py3: use pycompat.bytestr() to convert str to bytes
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 26 Jun 2017 23:58:27 +0530] rev 33119
py3: use pycompat.bytestr() to convert str to bytes
Mon, 26 Jun 2017 23:57:49 +0530 py3: pass the memoryview object into bytes() to get the value
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 26 Jun 2017 23:57:49 +0530] rev 33118
py3: pass the memoryview object into bytes() to get the value
Mon, 26 Jun 2017 17:23:10 +0530 py3: use pycompat.bytestr instead of str
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 26 Jun 2017 17:23:10 +0530] rev 33117
py3: use pycompat.bytestr instead of str
Mon, 26 Jun 2017 17:22:45 +0530 py3: use '%d' to convert integers to bytes
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 26 Jun 2017 17:22:45 +0530] rev 33116
py3: use '%d' to convert integers to bytes
Sun, 25 Jun 2017 08:36:51 +0530 py3: slice over bytes to prevent getting it's ascii value
Pulkit Goyal <7895pulkit@gmail.com> [Sun, 25 Jun 2017 08:36:51 +0530] rev 33115
py3: slice over bytes to prevent getting it's ascii value
Tue, 27 Jun 2017 00:23:32 +0530 py3: use pycompat.strkwargs() to convert kwargs keys to str
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 27 Jun 2017 00:23:32 +0530] rev 33114
py3: use pycompat.strkwargs() to convert kwargs keys to str
Tue, 27 Jun 2017 00:15:56 +0530 py3: use r'' to prevent the addition of b'' by transformer
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 27 Jun 2017 00:15:56 +0530] rev 33113
py3: use r'' to prevent the addition of b'' by transformer There are cases in opts handling in debugcommands.py where we don't need to convert opts keys back to bytes as there are some handful cases and no other function using opts value. Using r'', we prevent the transformer to add a b'' which will keep the value str.
Tue, 27 Jun 2017 00:20:55 +0530 py3: use pycompat.byteskwargs() to convert kwargs' keys to bytes
Pulkit Goyal <7895pulkit@gmail.com> [Tue, 27 Jun 2017 00:20:55 +0530] rev 33112
py3: use pycompat.byteskwargs() to convert kwargs' keys to bytes This is used where ever required like where kwargs are passed into ui.formatter(), scmutil.match() or cmdutil.openrevlog() which expects bytes.
Tue, 27 Jun 2017 02:24:38 +0900 tests: use cgienv to minimize environment setup at hgweb tests
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Tue, 27 Jun 2017 02:24:38 +0900] rev 33111
tests: use cgienv to minimize environment setup at hgweb tests This patch follows other hgweb tests.
Tue, 27 Jun 2017 02:24:37 +0900 tests: avoid test failure for mangling path-like string by MSYS
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Tue, 27 Jun 2017 02:24:37 +0900] rev 33110
tests: avoid test failure for mangling path-like string by MSYS
Sun, 25 Jun 2017 08:20:05 +0530 py3: make sure commands name are bytes in tests
Pulkit Goyal <7895pulkit@gmail.com> [Sun, 25 Jun 2017 08:20:05 +0530] rev 33109
py3: make sure commands name are bytes in tests
Sun, 25 Jun 2017 03:11:55 +0530 py3: add b'' to make the regex pattern bytes
Pulkit Goyal <7895pulkit@gmail.com> [Sun, 25 Jun 2017 03:11:55 +0530] rev 33108
py3: add b'' to make the regex pattern bytes
Mon, 26 Jun 2017 17:20:46 +0530 py3: use hex() to convert the hash to bytes
Pulkit Goyal <7895pulkit@gmail.com> [Mon, 26 Jun 2017 17:20:46 +0530] rev 33107
py3: use hex() to convert the hash to bytes
Sat, 24 Jun 2017 19:57:50 +0530 py3: add b'' to make a triple quoted string bytes on Python 3
Pulkit Goyal <7895pulkit@gmail.com> [Sat, 24 Jun 2017 19:57:50 +0530] rev 33106
py3: add b'' to make a triple quoted string bytes on Python 3 Transformer does not adds b'' in front of triple quoted strings to prevent converting docs to bytes.
Sat, 24 Jun 2017 19:55:41 +0530 py3: add tests to show `hg bookmarks` and `hg branches` work on Python 3
Pulkit Goyal <7895pulkit@gmail.com> [Sat, 24 Jun 2017 19:55:41 +0530] rev 33105
py3: add tests to show `hg bookmarks` and `hg branches` work on Python 3
Sat, 24 Jun 2017 19:55:01 +0530 py3: fix kwargs handling for `hg bookmarks`
Pulkit Goyal <7895pulkit@gmail.com> [Sat, 24 Jun 2017 19:55:01 +0530] rev 33104
py3: fix kwargs handling for `hg bookmarks`
(0) -30000 -10000 -3000 -1000 -300 -100 -48 +48 +100 +300 +1000 +3000 +10000 tip