Sun, 18 Feb 2018 16:19:26 -0800 tests: expand test coverage for updating phases stable
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 18 Feb 2018 16:19:26 -0800] rev 36243
tests: expand test coverage for updating phases Consolidating the tests demonstrated that there are behavior differences when pushing phases between bundle1 and bundle2. A reason for this is the behavior of legacy pushes where the client queries the state of phases and then conditionally updates phases after an "unbundle" is processed. This behavior is expected. The tests were incomplete because they only tested the case of a publishing repo. In this commit, we add a variant for a non-publishing repo. We still see some differences between the legacy and bundle2 exchanges. But they are less pronounced. The behavior of not firing a pushkey hook when phases are updated as part of changegroup application feels weird to me. I'm not sure if this is a feature or a bug. By the time the "pushkey" or "phases" bundle2 part is applied, the phases have already been moved on a publishing repository. We fire the "pushkey" hook regardless, even though it would be a no-op. This is the part that feels the most buggy.
Sun, 18 Feb 2018 10:00:34 -0800 tests: consolidate test-push-http.t and test-push-http-bundle1.t stable
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 18 Feb 2018 10:00:34 -0800] rev 36242
tests: consolidate test-push-http.t and test-push-http-bundle1.t These tests were initially copies of each other. Now that we have #testcases support in .t tests, we can consolidate them. The changes to test-push-http.t reflect the differences between that file and test-push-http-bundle1.t. The variances in phases push behavior are the biggest differences. The test will be updated in a subsequent commit to make the differences more clear and to expand test coverage. For now, let's just port the differences verbatim to get the tests consolidated.
Sun, 18 Feb 2018 08:52:57 -0800 tests: port value-less unbundle capability test to test-push-http.t stable
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 18 Feb 2018 08:52:57 -0800] rev 36241
tests: port value-less unbundle capability test to test-push-http.t This test is present in test-push-http-bundle1.t. Let's add it to test-push-http.t to further unify the tests.
Sun, 18 Feb 2018 08:49:18 -0800 tests: add phase testing to test-push-http-bundle1.t stable
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 18 Feb 2018 08:49:18 -0800] rev 36240
tests: add phase testing to test-push-http-bundle1.t test-push-http.t and test-push-http-bundle1.t were initially copies. Now that we have support for inline test variants, we can combine them. One of the variances between the tests is testing of phase moving. We add the missing code to test-push-http-bundle1.t.
Sun, 07 Jan 2018 11:26:16 +0900 cmdutil: narrow scope of KeyError in makefilename()
Yuya Nishihara <yuya@tcha.org> [Sun, 07 Jan 2018 11:26:16 +0900] rev 36239
cmdutil: narrow scope of KeyError in makefilename() It seemed too broad to catch a standard Python exception.
Wed, 14 Feb 2018 21:34:12 -0500 node: make bin() be a wrapper instead of just an alias
Augie Fackler <augie@google.com> [Wed, 14 Feb 2018 21:34:12 -0500] rev 36238
node: make bin() be a wrapper instead of just an alias This includes a full backout of 59affe7e and 30d0cb27. Per the review of the former, we'd rather adapt the API to behave like it used to (at least for now), and take a second run at it if it shows up in our performance numbers. I ran perfrevlogindex with and without this change and it didn't make a measurable difference, so maybe it's fine (despite my intuition to the contrary). Differential Revision: https://phab.mercurial-scm.org/D2279
Fri, 16 Feb 2018 11:30:18 -0800 tests: actually check that HGDEMANDIMPORT=disable disables demandimport
Martin von Zweigbergk <martinvonz@google.com> [Fri, 16 Feb 2018 11:30:18 -0800] rev 36237
tests: actually check that HGDEMANDIMPORT=disable disables demandimport At the point in the test where we were checking that the 'node' got eagerly loaded, it had already been loaded (via the pvec module), so our check wasn't doing anything (i.e. the test would pass even if you removed the line that set HGDEMANDIMPORT=disable). Let's move this test earlier so it tests what it was meant to test. Differential Revision: https://phab.mercurial-scm.org/D2286
Thu, 04 Jan 2018 16:29:07 -0800 debugcommands: print out the editor that was searched for (post shlexsplit)
Kyle Lippincott <spectral@google.com> [Thu, 04 Jan 2018 16:29:07 -0800] rev 36236
debugcommands: print out the editor that was searched for (post shlexsplit) A user was in #mercurial and had the following settings in their hgrc: [ui] editor = C:\home\npp\notepad++.exe -multiInst -nosession After shlexsplit, the first argument was mangled into C:homenppnotepad++.exe, which was quite unlikely to exist. It took many back-and-forths to identify that adding " characters around the exe would fix the issue; we were thinking that it's because something was incorrectly *not* splitting and adding/moving the " characters fixed the split boundaries, but when testing afterward it appears that it's just mangled. I considered adding an informational if pycompat.iswindows and \ in the string about this issue, but was worried that might have too many false positives and did not do so at this time. Differential Revision: https://phab.mercurial-scm.org/D1808
Fri, 16 Feb 2018 17:24:31 -0500 merge with stable
Augie Fackler <augie@google.com> [Fri, 16 Feb 2018 17:24:31 -0500] rev 36235
merge with stable
Fri, 16 Feb 2018 13:25:39 -0800 date: fix parsing months stable
Jun Wu <quark@fb.com> [Fri, 16 Feb 2018 13:25:39 -0800] rev 36234
date: fix parsing months Thanks nemo for discovering this on #mercurial IRC channel. Test Plan: Add a test. It fails before this patch: ``` + hg: parse error: invalid date: 'Feb 2018' + hg: parse error: invalid date: 'Apr 2018' + hg: parse error: invalid date: 'Jun 2018' + hg: parse error: invalid date: 'Sep 2018' + hg: parse error: invalid date: 'Nov 2018' ``` Differential Revision: https://phab.mercurial-scm.org/D2289
Thu, 15 Feb 2018 21:14:57 +0800 hgweb: show dates recorded in obsolescence markers
Anton Shestakov <av6@dwimlabs.net> [Thu, 15 Feb 2018 21:14:57 +0800] rev 36233
hgweb: show dates recorded in obsolescence markers Dates of operations that obsolete commits are also important enough to be shown, but maybe not as important as original commit dates, that and also for brevity is why they are wrapped in a <span> with only "age" class. Provided that JS is enabled, such elements only show age (e.g. "3 months ago"), and the exact date is visible in a tooltip. Commits dates, on the other hand, show both date and age (the latter in parenthesis). Example result for f1a0933ce59e from hg-committed: obsolete: pruned by Yuya Nishihara <yuya@tcha.org> 13 days ago
Thu, 15 Feb 2018 21:05:31 +0800 gitweb: make span.age CSS selector more specific
Anton Shestakov <av6@dwimlabs.net> [Thu, 15 Feb 2018 21:05:31 +0800] rev 36232
gitweb: make span.age CSS selector more specific This set of CSS properties is only used on /changelog page to make age elements float to the left and be fixed in size, but span.a is too broad of a selector, because we don't want to apply these properties to all <span> elements that have age class.
Thu, 15 Feb 2018 17:30:43 -0500 wireprotoserver: return to using iscmd() method
Augie Fackler <augie@google.com> [Thu, 15 Feb 2018 17:30:43 -0500] rev 36231
wireprotoserver: return to using iscmd() method This was teased out in part so remotefilelog could disable an old protocol method over http. It got dropped accidentally in the recent refactor, but the code was all still present so it's easy to support for now. I think once we land remotefilelog, we should probably inline this function. Differential Revision: https://phab.mercurial-scm.org/D2285
Sun, 11 Feb 2018 17:23:58 -0800 githelp: cast commands to bytes
Gregory Szorc <gregory.szorc@gmail.com> [Sun, 11 Feb 2018 17:23:58 -0800] rev 36230
githelp: cast commands to bytes This is more compatible with Python 3. Differential Revision: https://phab.mercurial-scm.org/D2165
Wed, 14 Feb 2018 17:43:33 +0530 py3: use util.forcebytestr instead of str for converting errors to bytes
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 14 Feb 2018 17:43:33 +0530] rev 36229
py3: use util.forcebytestr instead of str for converting errors to bytes Differential Revision: https://phab.mercurial-scm.org/D2269
Wed, 14 Feb 2018 16:37:46 +0530 py3: use pycompat.bytestr to convert str to bytes
Pulkit Goyal <7895pulkit@gmail.com> [Wed, 14 Feb 2018 16:37:46 +0530] rev 36228
py3: use pycompat.bytestr to convert str to bytes Differential Revision: https://phab.mercurial-scm.org/D2261
Mon, 12 Feb 2018 10:41:00 -0500 mpatch: allow clang-format oversight
Augie Fackler <augie@google.com> [Mon, 12 Feb 2018 10:41:00 -0500] rev 36227
mpatch: allow clang-format oversight Differential Revision: https://phab.mercurial-scm.org/D2183
Mon, 12 Feb 2018 10:39:46 -0500 base85: allow clang-format oversight
Augie Fackler <augie@google.com> [Mon, 12 Feb 2018 10:39:46 -0500] rev 36226
base85: allow clang-format oversight Differential Revision: https://phab.mercurial-scm.org/D2182
Mon, 12 Feb 2018 10:38:11 -0500 charencode: allow clang-format oversight
Augie Fackler <augie@google.com> [Mon, 12 Feb 2018 10:38:11 -0500] rev 36225
charencode: allow clang-format oversight Nice and easy. Differential Revision: https://phab.mercurial-scm.org/D2181
Wed, 14 Feb 2018 21:12:48 -0500 formatting: enforce system headers before local headers
Augie Fackler <augie@google.com> [Wed, 14 Feb 2018 21:12:48 -0500] rev 36224
formatting: enforce system headers before local headers Differential Revision: https://phab.mercurial-scm.org/D2275
Mon, 12 Feb 2018 17:20:20 -0800 wireprotoserver: add version to HTTP protocol name (API)
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 17:20:20 -0800] rev 36223
wireprotoserver: add version to HTTP protocol name (API) This matches what we did for the SSH protocol handler in ac33dc94e1d5. .. api:: HTTP protocol handlers now advertises its internal name as ``http-v1`` instead of ``http``. Differential Revision: https://phab.mercurial-scm.org/D2219
Mon, 12 Feb 2018 17:19:51 -0800 wireprotoserver: rename webproto to httpv1protocolhandler
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 17:19:51 -0800] rev 36222
wireprotoserver: rename webproto to httpv1protocolhandler This matches our naming convention for the SSH server's protocol handler. Differential Revision: https://phab.mercurial-scm.org/D2218
Mon, 12 Feb 2018 17:16:52 -0800 wireproto: improve docstring for "hello"
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 17:16:52 -0800] rev 36221
wireproto: improve docstring for "hello" Differential Revision: https://phab.mercurial-scm.org/D2217
Mon, 12 Feb 2018 17:14:29 -0800 httppeer: remove httpspeer
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 17:14:29 -0800] rev 36220
httppeer: remove httpspeer All it did was verify at construction time that Mercurial supports TLS. instance() is what's used to construct peer instances. So we can just inline this check into that function and do away with the type variant. Differential Revision: https://phab.mercurial-scm.org/D2216
Mon, 12 Feb 2018 17:10:58 -0800 httppeer: remove redundant code to fetch capabilities
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 17:10:58 -0800] rev 36219
httppeer: remove redundant code to fetch capabilities _fetchcaps() is called by httppeer.instance(), which is the only instantiator of httppeer. Since _fetchcaps() always sets self._caps and since 197d10e157ce removed the fallback for cases where the remote doesn't support capabilities, we can remove some dead code from httppeer.capabilities(). Differential Revision: https://phab.mercurial-scm.org/D2215
Thu, 01 Feb 2018 19:32:42 -0800 httppeer: change logic around argument handling
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 01 Feb 2018 19:32:42 -0800] rev 36218
httppeer: change logic around argument handling The code to process arguments only makes sense if there are arguments. So change an "else" to "elif args", remove an "if" that isn't necessary, and add some docs for good measure. Differential Revision: https://phab.mercurial-scm.org/D2214
Mon, 12 Feb 2018 16:35:06 -0800 tests: test using both versions of SSH protocol
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 16:35:06 -0800] rev 36217
tests: test using both versions of SSH protocol Now that the version 2 of the SSH protocol is usable in core, we can start actively testing it more widely outside of low-level protocol tests. We add #testcases variants to a handful of tests so we exercise both version 1 and version 2 of the SSH protocol when testing. This will allow us to more easily find regressions and variances as protocol 2 is developed. It will also make it easier to continue testing with protocol version 1 once version 2 is enabled by default. There are a handful of tests using ssh:// that should also gain test variances. One - test-push-race.t - already has a #testcases. This would require combinatorial cases. I didn't want to go down that rabbit hole, so that test is unchanged. Thinking aloud, there is probably an opportunity to automatically run tests with multiple server/protocol implementations. Ideally any test that performed server interaction would run with all supported server implementations and protocols so we could find variances between servers and protocols. But this has been a long-standing issue with our test harness. I don't think it is an easily solved problem. But it would be nice... Differential Revision: https://phab.mercurial-scm.org/D2206
Thu, 08 Feb 2018 11:39:23 -0800 sshpeer: log remote capabilities after protocol upgrade
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 08 Feb 2018 11:39:23 -0800] rev 36216
sshpeer: log remote capabilities after protocol upgrade This helps reduce variance with version 1 and will help prevent test output divergence as we start testing protocol version 2 more widely. Differential Revision: https://phab.mercurial-scm.org/D2205
Mon, 12 Feb 2018 16:33:54 -0800 wireprotoserver: handle SSH protocol version 2 upgrade requests
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 12 Feb 2018 16:33:54 -0800] rev 36215
wireprotoserver: handle SSH protocol version 2 upgrade requests This commit teaches the SSH server to recognize the "upgrade" request line that clients send when they wish to switch the channel to version 2 of the SSH protocol. Servers don't honor upgrade requests unless an experimental config option is set. Since the built-in server now supports upgrade requests, our test server to test the handshake has been deleted. Existing tests use the built-in server and their output doesn't change. The upgrade is handled in our state machine. The end result is a bit wonky, as the server transitions back to version 1 state immediately after upgrading. But this will change as soon as version 2 has an actual protocol that differs from version 1. Tests demonstrating that the new server is a bit more strict about the upgrade handshake have been added. Differential Revision: https://phab.mercurial-scm.org/D2204
Thu, 08 Feb 2018 15:09:59 -0800 wireprotoserver: move SSH server operation to a standalone function
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 08 Feb 2018 15:09:59 -0800] rev 36214
wireprotoserver: move SSH server operation to a standalone function The server-side processing logic will soon get a bit more complicated in order to handle protocol switches. We will use a state machine to help make the transitions clearer. To prepare for this, we move SSH server operation into a standalone function. We structure it as a very simple state machine. It only has two states for now, with one state containing the bulk of the logic. But things will evolve shortly. Differential Revision: https://phab.mercurial-scm.org/D2203
(0) -30000 -10000 -3000 -1000 -300 -100 -50 -30 +30 +50 +100 +300 +1000 +3000 +10000 tip