Mon, 11 Sep 2017 13:39:22 -0700 changegroup: add source parameter to generatemanifests
Durham Goode <durham@fb.com> [Mon, 11 Sep 2017 13:39:22 -0700] rev 34149
changegroup: add source parameter to generatemanifests Extensions, like remotefilelog, will want to look at the source of a pull when determining what manifests to add to a changegroup. For instance, on push they will include everything, while on pull they won't. Differential Revision: https://phab.mercurial-scm.org/D686
Wed, 13 Sep 2017 10:43:44 -0700 changegroup: remove changegroup dependency from revlog.addgroup
Durham Goode <durham@fb.com> [Wed, 13 Sep 2017 10:43:44 -0700] rev 34148
changegroup: remove changegroup dependency from revlog.addgroup Previously revlog.addgroup would accept a changegroup and a linkmapper and use it to iterate of the deltas. As part of untangling the revlog-changegroup interdependency, let's move the changegroup delta iteration logic to it's own function and pass the simple iterator to the revlog instead. This will make it easier to introduce non-revlogs stores in the future, without reinventing any changegroup specific logic. Differential Revision: https://phab.mercurial-scm.org/D688
Wed, 13 Sep 2017 10:43:16 -0700 revlog: refactor chain variable
Durham Goode <durham@fb.com> [Wed, 13 Sep 2017 10:43:16 -0700] rev 34147
revlog: refactor chain variable Previously the addgroup loop would set chain to be the result of self._addrevision(node,...). Since _addrevision now always returns the passed in node, we can drop that behavior and just always set chain = node in the loop. This will be useful in a future patch where we refactor the cg.deltachunk logic to another function and therefore chain disappears entirely from this function. Differential Revision: https://phab.mercurial-scm.org/D699
Mon, 11 Sep 2017 17:49:49 +0000 scmutil: don't append .orig to backups in origbackuppath (BC)
Mark Thomas <mbthomas@fb.com> [Mon, 11 Sep 2017 17:49:49 +0000] rev 34146
scmutil: don't append .orig to backups in origbackuppath (BC) When ui.origbackuppath is set, .orig files are stored outside of the working copy, however they still have a .orig suffix appended to them. This can cause unexpected conflicts, particularly when tracked files or directories have .orig at the end. This change removes the .orig suffix from files stored in an out-of-tree origbackuppath. Test Plan: Update and run unit tests. Differential Revision: https://phab.mercurial-scm.org/D679
Mon, 11 Sep 2017 15:59:18 -0700 ssh: fix flakey ssh errors on BSD systems stable
Durham Goode <durham@fb.com> [Mon, 11 Sep 2017 15:59:18 -0700] rev 34145
ssh: fix flakey ssh errors on BSD systems This is a trivial backport of c037fd655b47 performed by augie@google.com, but the change is still really Durham's not mine, so I [augie] am leaving him as the author.
Thu, 14 Sep 2017 11:16:57 -0700 repair: preserve phase also when not using generaldelta (issue5678) stable
Martin von Zweigbergk <martinvonz@google.com> [Thu, 14 Sep 2017 11:16:57 -0700] rev 34144
repair: preserve phase also when not using generaldelta (issue5678) It seems like we used to pick the oldest possible version of the changegroup to use for bundles created by the repair module (used e.g. by "hg strip" and for temporary bundles by "hg rebase"). I tried to preserve that behavior when I created the changegroup.safeversion() method in 3b2ac2115464 (changegroup: introduce safeversion(), 2016-01-19). However, we have recently chagned our minds and decided that these commands are only used locally and downgrades are unlikely. That decicion allowed us to start adding obsmarker and phase information to these bundles. However, as the bug report shows, it means we get different behavior e.g. when generaldelta is not enabled (because when it was enabled, it forced us to use bundle2). The commit that actually caused the reported bug was 8e3021fd1a44 (strip: include phases in bundle (BC), 2017-06-15). So, since we now depend on having more information in the bundles, let's make sure we instead pick the newest possible changegroup version. Differential Revision: https://phab.mercurial-scm.org/D715
Thu, 14 Sep 2017 11:16:47 -0700 tests: add test for issue5678 stable
Martin von Zweigbergk <martinvonz@google.com> [Thu, 14 Sep 2017 11:16:47 -0700] rev 34143
tests: add test for issue5678 In addition to a test case for the direct problem described in the bug report, this also adds a test case showing how obsmarkers can also get lost when not using generaldelta. Differential Revision: https://phab.mercurial-scm.org/D714
Tue, 12 Sep 2017 19:27:01 -0700 merge: move cwd-missing detection to helper functions
Phil Cohen <phillco@fb.com> [Tue, 12 Sep 2017 19:27:01 -0700] rev 34142
merge: move cwd-missing detection to helper functions This will exist in two places with defered writes, so we want to avoid duplication. Differential Revision: https://phab.mercurial-scm.org/D626
Sun, 03 Sep 2017 15:09:04 +0900 doctest: enable tests by default on Python 3
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 15:09:04 +0900] rev 34141
doctest: enable tests by default on Python 3 Still several tests fail mostly because of the string issues, sigh. I'll fix them one by one.
Thu, 24 Aug 2017 22:33:28 +0900 doctest: normalize b'', u'' and exception output on Python 3
Yuya Nishihara <yuya@tcha.org> [Thu, 24 Aug 2017 22:33:28 +0900] rev 34140
doctest: normalize b'', u'' and exception output on Python 3 The idea is described in the following page. https://dirkjan.ochtman.nl/writing/2014/07/06/single-source-python-23-doctests.html # no-check-commit
Sun, 03 Sep 2017 17:33:10 +0900 doctest: coerce dict.keys() to list
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 17:33:10 +0900] rev 34139
doctest: coerce dict.keys() to list Otherwise it would be printed as odict_keys([...]) on Python 3.
Sun, 03 Sep 2017 15:16:01 +0900 doctest: upgrade old-style "except" clause
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 15:16:01 +0900] rev 34138
doctest: upgrade old-style "except" clause
Sun, 03 Sep 2017 14:56:31 +0900 doctest: use print_function and convert bytes to unicode where needed
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 14:56:31 +0900] rev 34137
doctest: use print_function and convert bytes to unicode where needed
Sun, 03 Sep 2017 15:47:17 +0900 doctest: do not embed non-ascii characters in docstring
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 15:47:17 +0900] rev 34136
doctest: do not embed non-ascii characters in docstring Since the outer docstring is parsed as a unicode on Python 3, we have to either double-escape or construct non-ascii string from ascii string.
Sun, 03 Sep 2017 15:42:27 +0900 doctest: pass encoding name as system string
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 15:42:27 +0900] rev 34135
doctest: pass encoding name as system string
Sun, 03 Sep 2017 14:38:58 +0900 doctest: replace str() with bytes()
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 14:38:58 +0900] rev 34134
doctest: replace str() with bytes()
Sun, 03 Sep 2017 14:37:25 +0900 doctest: replace chr() with pycompat.bytechr()
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 14:37:25 +0900] rev 34133
doctest: replace chr() with pycompat.bytechr()
Sun, 03 Sep 2017 14:35:37 +0900 doctest: replace .iteritems() with .items()
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 14:35:37 +0900] rev 34132
doctest: replace .iteritems() with .items()
Sun, 03 Sep 2017 14:32:11 +0900 doctest: bulk-replace string literals with b'' for Python 3
Yuya Nishihara <yuya@tcha.org> [Sun, 03 Sep 2017 14:32:11 +0900] rev 34131
doctest: bulk-replace string literals with b'' for Python 3 Our code transformer can't rewrite string literals in docstrings, and I don't want to make the transformer more complex.
Thu, 07 Sep 2017 22:36:54 +0900 debuginstall: do not pass exception object to formatter (issue5676)
Yuya Nishihara <yuya@tcha.org> [Thu, 07 Sep 2017 22:36:54 +0900] rev 34130
debuginstall: do not pass exception object to formatter (issue5676)
Thu, 07 Sep 2017 22:27:23 +0900 debuginstall: use codecs.lookup() to detect invalid encoding
Yuya Nishihara <yuya@tcha.org> [Thu, 07 Sep 2017 22:27:23 +0900] rev 34129
debuginstall: use codecs.lookup() to detect invalid encoding encoding.fromlocal() never tries to decode an ascii string since 853574db5b12, and there's no universal non-ascii string which can be decoded as any valid character set.
Sun, 10 Sep 2017 23:37:14 +0900 extensions: fix wrapcommand/function of class instance
Yuya Nishihara <yuya@tcha.org> [Sun, 10 Sep 2017 23:37:14 +0900] rev 34128
extensions: fix wrapcommand/function of class instance 5361771f9714 changed _updatewrapper() to copy the __name__ attribute, but not all callable objects has __name__. Spotted by loading mq with extdiff.
Tue, 12 Sep 2017 09:13:02 -0700 changegroup: avoid creating empty changegroup part
Durham Goode <durham@fb.com> [Tue, 12 Sep 2017 09:13:02 -0700] rev 34127
changegroup: avoid creating empty changegroup part Previously this check happened in the changegroup code itself. Since its refactor, this logic needs to move out to callers that care about it, such as this one. Otherwise we get empty bundle devel-warnings in certain extensions. Differential Revision: https://phab.mercurial-scm.org/D690
Tue, 12 Sep 2017 15:12:27 -0700 tests: split test-revset.t in half
Durham Goode <durham@fb.com> [Tue, 12 Sep 2017 15:12:27 -0700] rev 34126
tests: split test-revset.t in half This test has gotten so large that running it can exceed the normal timeout on systems under load (like if we're running all the tests in parallel). This patch splits the test cleanly in half. Differential Revision: https://phab.mercurial-scm.org/D694
Mon, 11 Sep 2017 13:17:43 -0700 merge: flush any deferred writes just before recordupdates()
Phil Cohen <phillco@fb.com> [Mon, 11 Sep 2017 13:17:43 -0700] rev 34125
merge: flush any deferred writes just before recordupdates() ``recordupdates`` calls into the dirstate which requires the files to be there, so this is the last possible moment we can flush anything. Differential Revision: https://phab.mercurial-scm.org/D673
Mon, 11 Sep 2017 13:03:27 -0700 merge: flush any deferred writes before, and after, running any workers
Phil Cohen <phillco@fb.com> [Mon, 11 Sep 2017 13:03:27 -0700] rev 34124
merge: flush any deferred writes before, and after, running any workers Since we fork to create workers, any changes they queue up will be lost after the worker terminates, so the easiest solution is to have each worker flush the writes they accumulate--we are close to the end of the merge in any case. To prevent duplicated writes, we also have the master processs flush before forking. In an in-memory merge (M2), we'll instead disable the use of workers. Differential Revision: https://phab.mercurial-scm.org/D628
Mon, 11 Sep 2017 13:03:27 -0700 filemerge: flush if using deferred writes when running a merge tool
Phil Cohen <phillco@fb.com> [Mon, 11 Sep 2017 13:03:27 -0700] rev 34123
filemerge: flush if using deferred writes when running a merge tool Since merge tools might read from the filesystem, we need to write out our deferred writes here. No-ops if not using deferred writes. Differential Revision: https://phab.mercurial-scm.org/D627
Mon, 11 Sep 2017 13:03:27 -0700 merge: pass wctx to premerge, filemerge
Phil Cohen <phillco@fb.com> [Mon, 11 Sep 2017 13:03:27 -0700] rev 34122
merge: pass wctx to premerge, filemerge In the in-memory merge branch. we'll need to call a function (``flushall``) on the wctx inside of _xmerge. This prepares the way so it can be done without hacks like ``fcd.ctx()``. Differential Revision: https://phab.mercurial-scm.org/D449
Mon, 11 Sep 2017 18:07:29 +0200 cmdutil: fix amend when passing a date
Boris Feld <boris.feld@octobus.net> [Mon, 11 Sep 2017 18:07:29 +0200] rev 34121
cmdutil: fix amend when passing a date Following https://phab.mercurial-scm.org/D636, passing the same date that the changeset to amend would results in no new commits but the output changed from: $ hg amend -d '0 0' nothing changed [1] to: $ hg amend -d '0 0' Restore the old behavior by parsing the date passed as parameter so the condition "date == old.date()" correctly works in cases both dates are identical. Add a test for covering this regression. This bug was found thanks to Evolve test suite. Differential Revision: https://phab.mercurial-scm.org/D691
Tue, 12 Sep 2017 11:18:35 -0400 merge with stable
Augie Fackler <augie@google.com> [Tue, 12 Sep 2017 11:18:35 -0400] rev 34120
merge with stable
Fri, 30 Jun 2017 03:39:32 +0200 configitems: register the 'eol.only-consistent' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:39:32 +0200] rev 34119
configitems: register the 'eol.only-consistent' config
Fri, 30 Jun 2017 03:39:26 +0200 configitems: register the 'eol.native' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:39:26 +0200] rev 34118
configitems: register the 'eol.native' config
Fri, 30 Jun 2017 03:39:21 +0200 configitems: register the 'eol.fix-trailing-newline' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:39:21 +0200] rev 34117
configitems: register the 'eol.fix-trailing-newline' config
Fri, 30 Jun 2017 03:43:43 +0200 configitems: register the 'patchbomb.publicurl' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:43:43 +0200] rev 34116
configitems: register the 'patchbomb.publicurl' config
Fri, 30 Jun 2017 03:43:41 +0200 configitems: register the 'patchbomb.intro' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:43:41 +0200] rev 34115
configitems: register the 'patchbomb.intro' config
Fri, 30 Jun 2017 03:43:40 +0200 configitems: register the 'patchbomb.from' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:43:40 +0200] rev 34114
configitems: register the 'patchbomb.from' config
Fri, 30 Jun 2017 03:43:39 +0200 configitems: register the 'patchbomb.flagtemplate' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:43:39 +0200] rev 34113
configitems: register the 'patchbomb.flagtemplate' config
Fri, 30 Jun 2017 03:43:38 +0200 configitems: register the 'patchbomb.confirm' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:43:38 +0200] rev 34112
configitems: register the 'patchbomb.confirm' config
Fri, 30 Jun 2017 03:43:37 +0200 configitems: register the 'patchbomb.bundletype' config
Boris Feld <boris.feld@octobus.net> [Fri, 30 Jun 2017 03:43:37 +0200] rev 34111
configitems: register the 'patchbomb.bundletype' config
Wed, 06 Sep 2017 21:12:27 -0700 blackbox: remove _bbvfs state
Jun Wu <quark@fb.com> [Wed, 06 Sep 2017 21:12:27 -0700] rev 34110
blackbox: remove _bbvfs state `_bbvfs` is redundant because it could be calcualted from `_bbrepo`. Differential Revision: https://phab.mercurial-scm.org/D651
Wed, 06 Sep 2017 21:08:59 -0700 blackbox: do not cache file objects
Jun Wu <quark@fb.com> [Wed, 06 Sep 2017 21:08:59 -0700] rev 34109
blackbox: do not cache file objects Having the blackbox file objects cached in `ui._bbfp` could in theory be troublesome if multiple processes (ex. chg servers) have file objects referring to a same file. (Although I spent some time and failed to build a convincing test case) This patch makes blackbox re-open the file every time to make the situation better. Ideally we also need proper locking. The caching logic traces back to the commit introducing blackbox (18242716a). That commit does not have details about why caching is necessary. Consider the fact that blackbox logs are not many, it seems fine to remove the fp cache to be more confident. Differential Revision: https://phab.mercurial-scm.org/D650
Wed, 06 Sep 2017 20:54:53 -0700 blackbox: inline _bbwrite
Jun Wu <quark@fb.com> [Wed, 06 Sep 2017 20:54:53 -0700] rev 34108
blackbox: inline _bbwrite There is no need to make it a separate method. This makes the next change easier to read. Differential Revision: https://phab.mercurial-scm.org/D649
Wed, 06 Sep 2017 19:27:30 -0700 blackbox: fix rotation with chg
Jun Wu <quark@fb.com> [Wed, 06 Sep 2017 19:27:30 -0700] rev 34107
blackbox: fix rotation with chg The added test will show: $ $PYTHON showsize.py .hg/blackbox* .hg/blackbox.log: < 500 .hg/blackbox.log.1: < 500 .hg/blackbox.log.2: < 500 .hg/blackbox.log.3: < 500 .hg/blackbox.log.4: < 500 .hg/blackbox.log.5: >= 500 with previous code. The issue is caused by blackbox caching file objects *by path*, and the rotation size check could run on a wrong file object (i.e. it should check "blackbox.log", but `filehandles["blackbox.log"]` contains a file object that has been renamed to "blackbox.log.5"). This patch removes the "filehandlers" global cache added by 45313f5a3a8c to solve the issue. I think the original patch was trying to make different ui objects use a same file object if their blackbox.log path is the same. In theory it could also be problematic in the rotation case. Anyway, that should become unnecessary after D650. Differential Revision: https://phab.mercurial-scm.org/D648
Wed, 06 Sep 2017 18:31:25 -0700 test-blackbox: make it compatible with chg
Jun Wu <quark@fb.com> [Wed, 06 Sep 2017 18:31:25 -0700] rev 34106
test-blackbox: make it compatible with chg Differential Revision: https://phab.mercurial-scm.org/D647
Mon, 11 Sep 2017 15:59:18 -0700 ssh: fix flakey ssh errors on BSD systems
Durham Goode <durham@fb.com> [Mon, 11 Sep 2017 15:59:18 -0700] rev 34105
ssh: fix flakey ssh errors on BSD systems There's been a persistent issue with flakiness on BSD systems (like OSX) where the 'no suitable response from remote hg' message would sometimes not appear. This was caused by one of the earlier calls failing with a "IOError: Broken pipe". Catching those errors and printing the same message removes the flakiness. Differential Revision: https://phab.mercurial-scm.org/D687
Mon, 11 Sep 2017 13:03:27 -0700 context: add overlayworkingcontext and overlayworkingfilectx
Phil Cohen <phillco@fb.com> [Mon, 11 Sep 2017 13:03:27 -0700] rev 34104
context: add overlayworkingcontext and overlayworkingfilectx These two classes will be used extensively in the first in-memory merge milestone. Differential Revision: https://phab.mercurial-scm.org/D616
Sun, 10 Sep 2017 18:52:40 -0700 changegroup: rename getsubsetraw to makestream
Durham Goode <durham@fb.com> [Sun, 10 Sep 2017 18:52:40 -0700] rev 34103
changegroup: rename getsubsetraw to makestream Now that nothing uses getsubsetraw except makestream, let's move the functionality into the makestream. This removes the last remaining excess changegroup creation function, getsubsetraw. Differential Revision: https://phab.mercurial-scm.org/D671
Sun, 10 Sep 2017 18:51:31 -0700 changegroup: remove external uses of getbundler
Durham Goode <durham@fb.com> [Sun, 10 Sep 2017 18:51:31 -0700] rev 34102
changegroup: remove external uses of getbundler Now that makestream and makechangegroup are the primary creation methods for changegroups, let's get rid of this rogue use of getbundler and getsubsetraw. Differential Revision: https://phab.mercurial-scm.org/D670
(0) -30000 -10000 -3000 -1000 -300 -100 -48 +48 +100 +300 +1000 +3000 +10000 tip