Fri, 07 Nov 2014 17:54:59 -0800 changegroup.cg2packer: lookup 'group' via inheritance chain
Siddharth Agarwal <sid0@fb.com> [Fri, 07 Nov 2014 17:54:59 -0800] rev 23243
changegroup.cg2packer: lookup 'group' via inheritance chain This lets extensions insert themselves in the class hierarchy.
Thu, 23 Oct 2014 17:00:38 -0700 context.status: only filter suspect symlinks in the dirstate status
Martin von Zweigbergk <martinvonz@google.com> [Thu, 23 Oct 2014 17:00:38 -0700] rev 23242
context.status: only filter suspect symlinks in the dirstate status We don't care about filtering out symlinks that have already been committed with full content, only those that have been accidentally resolved in the working directory.
Thu, 23 Oct 2014 16:19:56 -0700 context.status: inline _poststatus()
Martin von Zweigbergk <martinvonz@google.com> [Thu, 23 Oct 2014 16:19:56 -0700] rev 23241
context.status: inline _poststatus() By inlining _poststatus() into _buildstatus(), it becomes clearer that it is only called for the workingctx.
Sun, 12 Oct 2014 00:06:40 -0700 context.status: remove now-empty _prestatus()
Martin von Zweigbergk <martinvonz@gmail.com> [Sun, 12 Oct 2014 00:06:40 -0700] rev 23240
context.status: remove now-empty _prestatus()
Sat, 11 Oct 2014 23:30:08 -0700 context.status: call _dirstatestatus() from within _buildstatus()
Martin von Zweigbergk <martinvonz@gmail.com> [Sat, 11 Oct 2014 23:30:08 -0700] rev 23239
context.status: call _dirstatestatus() from within _buildstatus() By making the call to _dirstatestatus() within _buildstatus(), it becomes clearer that it's called only for the workingctx.
Sun, 12 Oct 2014 00:00:13 -0700 context.status: move manifest caching trick to _buildstatus()
Martin von Zweigbergk <martinvonz@gmail.com> [Sun, 12 Oct 2014 00:00:13 -0700] rev 23238
context.status: move manifest caching trick to _buildstatus() In basectx._buildstatus(), we read the manifests for the two revisions being compared. For "caching reasons" unknown to me, it is better to read the earlier manifest first, which basectx._prestatus() takes care of. However, if the 'self' context is a committablectx and the 'other' context is the parent of the working directory (as in the very common case of plain "hg status"), there is no need to read any manifests at all -- all that's needed is the dirstate status. To avoid reading the manifests, _prestatus() is overridden in committablectx and avoids calling its super method, and _buildstatus() calls its super method only if the 'other' context is not the parent of the working directory. It seems easier to follow what's happening if we move the pre-fetching to _buildstatus() just before the place where the manifests are fetched. We just need to add an extra check that the revision is not None to handle the case that was previously handled by subclass overriding. That also makes it safe for committablectx._prestatus() to call its parent, although the latter now becomes empty, so we won't bother.
Sat, 11 Oct 2014 23:18:53 -0700 context.status: remove unused arguments from _matchstatus()
Martin von Zweigbergk <martinvonz@gmail.com> [Sat, 11 Oct 2014 23:18:53 -0700] rev 23237
context.status: remove unused arguments from _matchstatus()
Thu, 23 Oct 2014 13:43:20 -0700 context.status: remove overriding in workingctx
Martin von Zweigbergk <martinvonz@google.com> [Thu, 23 Oct 2014 13:43:20 -0700] rev 23236
context.status: remove overriding in workingctx The workingctx method simply calls the super method. The only effect it has is that it uses a different default argument for the 'other' argument. The only in-tree caller is patch.diff, which always passes an argument to the method, so it should be safe to remove the overriding. Having the default argument depend on the type seems rather dangerous anyway.
Mon, 20 Oct 2014 14:20:43 -0400 synthrepo: when adding files, ensure new path is not a directory
Mike Edgar <adgar@google.com> [Mon, 20 Oct 2014 14:20:43 -0400] rev 23235
synthrepo: when adding files, ensure new path is not a directory
Mon, 20 Oct 2014 13:59:13 -0400 synthrepo: synthesized dates must be positive, fit in 32-bit signed ints
Mike Edgar <adgar@google.com> [Mon, 20 Oct 2014 13:59:13 -0400] rev 23234
synthrepo: synthesized dates must be positive, fit in 32-bit signed ints
Thu, 06 Nov 2014 01:48:29 +0100 discovery: test coverage for issue4438 / 86c35b7ae300 / 73cfaa348650
Mads Kiilerich <madski@unity3d.com> [Thu, 06 Nov 2014 01:48:29 +0100] rev 23233
discovery: test coverage for issue4438 / 86c35b7ae300 / 73cfaa348650 The randomness in the discovery protocol made this problem hard to reproduce. The test mocks random.sample to make sure we hit the problem every time. The set iteration order also made the output unstable ... but with the issue fixed, it is stable.
Wed, 05 Nov 2014 21:33:45 -0500 hgweb: fix a crash when using web.archivesubrepos stable
Matt Harbison <matt_harbison@yahoo.com> [Wed, 05 Nov 2014 21:33:45 -0500] rev 23232
hgweb: fix a crash when using web.archivesubrepos A matcher is required when enabling the subrepo option on archival.archive(), because that calls match.narrowmatcher(), which accesses fields on the object. It's therefore probably a bad idea to default the matcher to None on archive(), but that's a fix for default.
Wed, 05 Nov 2014 20:31:58 -0500 tests: introduce a subrepository to test-archive.t stable
Matt Harbison <matt_harbison@yahoo.com> [Wed, 05 Nov 2014 20:31:58 -0500] rev 23231
tests: introduce a subrepository to test-archive.t This will be used in an upcoming patch to add coverage for web.archivesubrepos.
Tue, 04 Nov 2014 21:45:26 -0800 test-status-rev: add tests for plain dirstate and inter-revision status
Martin von Zweigbergk <martinvonz@google.com> [Tue, 04 Nov 2014 21:45:26 -0800] rev 23230
test-status-rev: add tests for plain dirstate and inter-revision status We have tests for the status across from '.^' to the working copy. It makes sense to have the similar tests for the inter-revision status between '.^' and '.' and for the dirstate status in the same place.
Tue, 04 Nov 2014 21:22:46 -0800 test-status-rev: remove unnecessary initial commit
Martin von Zweigbergk <martinvonz@google.com> [Tue, 04 Nov 2014 21:22:46 -0800] rev 23229
test-status-rev: remove unnecessary initial commit The initial commit was there when we had a group of tests that compared against an empty base, but since those tests no longer exist, we can drop the empty commit.
Tue, 04 Nov 2014 16:10:20 -0800 test-status-rev: use one glob for each expected status
Martin von Zweigbergk <martinvonz@google.com> [Tue, 04 Nov 2014 16:10:20 -0800] rev 23228
test-status-rev: use one glob for each expected status It's getting a little hard to read the ~30 calls to 'hg status' with one per file. Instead, let's use one glob for each expected status. For example, modified files can be listed with 'glob:content1_*_content[23]-tracked'. That also nicely becomes an explanation for why each status is expected.
Tue, 04 Nov 2014 15:36:35 -0800 test-status-rev: remove duplicate tests
Martin von Zweigbergk <martinvonz@google.com> [Tue, 04 Nov 2014 15:36:35 -0800] rev 23227
test-status-rev: remove duplicate tests The second group of tests in test-status-rev compare to an empty revision. The first group of tests that compare to the first commit should be testing all the same states with the missing_* files, so drop the second group of tests.
Thu, 06 Nov 2014 22:48:20 -0800 changegroup: sparsely populate fnodes stable
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 06 Nov 2014 22:48:20 -0800] rev 23226
changegroup: sparsely populate fnodes Previously, fnodes had a key and empty dict value for every element in changedfiles. This is somewhat wasteful. Empty dicts in CPython consume a lot more memory than you would expect - 280 bytes. On mozilla-central, which has ~190,000 files/fnodes keys, the previous loop populating fnodes allocated 91,924 KB of memory, most of that for the empty dicts. With this patch in place, our peak RSS during mozilla-central clone drops: before: 364,356 KB after: 326,008 KB delta: -38,348 KB When combined with the previous patch, total peak RSS decrease is now 190,116 KB.
Thu, 06 Nov 2014 22:33:48 -0800 changegroup: don't store unused value on fnodes (issue4443) stable
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 06 Nov 2014 22:33:48 -0800] rev 23225
changegroup: don't store unused value on fnodes (issue4443) The contents of fnodes are only accessed once per key. It is wasteful to cache the value since nobody will use it. Before this patch, the caching of unused data in fnodes was effectively causing a memory leak during the file streaming part of bundle creation. On mozilla-central (which has ~190,000 entries in fnodes), this patch has a significant impact on RSS at the end of generate(): before: 516,124 KB after: 364,356 KB delta: -151,768 KB The origin of this code can be traced back to 627cd7842e5d and has been with us since the 2.7 release.
Thu, 06 Nov 2014 20:57:12 -0800 changegroup: don't define lookupmf() until it is needed stable
Gregory Szorc <gregory.szorc@gmail.com> [Thu, 06 Nov 2014 20:57:12 -0800] rev 23224
changegroup: don't define lookupmf() until it is needed lookupmf() is currently defined earlier than when it is needed. Future patches further refactoring this code will be easier to read when lookupmf() is in its new home.
Wed, 05 Nov 2014 18:31:39 +0000 mail: actually use the verifycert config value stable
Pierre-Yves David <pierre-yves.david@fb.com> [Wed, 05 Nov 2014 18:31:39 +0000] rev 23223
mail: actually use the verifycert config value The mail module only verifies the smtp ssl certificate if 'verifycert' is enabled (the default). The 'verifycert' can take three possible values: - 'strict' - 'loose' - any "False" value, eg: 'false' or '0' We tested the validity of the third value, but never converted it to actual falseness, making 'False' an equivalent for 'loose'. This changeset fixes it.
Tue, 28 Oct 2014 14:58:36 +0100 exchange: use the postclose API on transaction
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 28 Oct 2014 14:58:36 +0100] rev 23222
exchange: use the postclose API on transaction As with changegroup, we should wait for the transaction to be really closed before scheduling hook execution.
Tue, 28 Oct 2014 15:44:23 +0100 changegroup: use the 'postclose' API on transaction
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 28 Oct 2014 15:44:23 +0100] rev 23221
changegroup: use the 'postclose' API on transaction The post-transaction hooks run after the lock release (because hooks may want to touch the repository), but they must only run if the transaction is successfully closed. We use the new 'addpostclose' method on transaction to register a callback installing this post-lock-release call.
Tue, 28 Oct 2014 14:24:43 +0100 transaction: allow registering a post-close callback
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 28 Oct 2014 14:24:43 +0100] rev 23220
transaction: allow registering a post-close callback The addchangegroup code considers the transaction done after a 'tr.close()' call and schedules the hook's execution for after lock release. In the nested transaction case, the transaction is not yet committed and we must delay this scheduling. We add an 'addpostclose' method (like the 'addpending' and 'addfinalize' ones) that registers code to be run if the transaction is successfully committed.
Fri, 24 Oct 2014 15:58:46 -0400 exchange: swap "push" for "pull" in pulloperation docstring
Mike Edgar <adgar@google.com> [Fri, 24 Oct 2014 15:58:46 -0400] rev 23219
exchange: swap "push" for "pull" in pulloperation docstring
Wed, 29 Oct 2014 12:46:08 -0400 exchange: prepare kwargs for bundle2 part generation exactly once
Mike Edgar <adgar@google.com> [Wed, 29 Oct 2014 12:46:08 -0400] rev 23218
exchange: prepare kwargs for bundle2 part generation exactly once
Sat, 25 Oct 2014 00:40:51 -0400 exchange: fix indentation in _pullchangeset
Mike Edgar <adgar@google.com> [Sat, 25 Oct 2014 00:40:51 -0400] rev 23217
exchange: fix indentation in _pullchangeset
Fri, 24 Oct 2014 16:26:44 -0400 dagutil: fix id/ix typos in docstrings
Mike Edgar <adgar@google.com> [Fri, 24 Oct 2014 16:26:44 -0400] rev 23216
dagutil: fix id/ix typos in docstrings
Thu, 06 Nov 2014 11:55:37 +0000 patchbomb: extract 'getpatchmsgs' closure into its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Thu, 06 Nov 2014 11:55:37 +0000] rev 23215
patchbomb: extract 'getpatchmsgs' closure into its own function Keep marching toward the promised land of simplification!
Thu, 06 Nov 2014 11:57:48 +0000 patchbomb: extract 'makeintro' closure into its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Thu, 06 Nov 2014 11:57:48 +0000] rev 23214
patchbomb: extract 'makeintro' closure into its own function Keep marching toward the promised land of simplification!
Tue, 04 Nov 2014 21:48:23 +0000 patchbomb: extract 'getbundlemsgs' closure in its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 04 Nov 2014 21:48:23 +0000] rev 23213
patchbomb: extract 'getbundlemsgs' closure in its own function Keep marching toward the promised land of simplification!
Tue, 04 Nov 2014 21:41:35 +0000 patchbomb: extract 'getdescription' closure in its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 04 Nov 2014 21:41:35 +0000] rev 23212
patchbomb: extract 'getdescription' closure in its own function Keep marching toward the promised land of simplification!
Tue, 04 Nov 2014 21:33:57 +0000 patchbomb: extract 'getbundle' closure in its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 04 Nov 2014 21:33:57 +0000] rev 23211
patchbomb: extract 'getbundle' closure in its own function Keep marching toward the promised land of simplification!
Tue, 04 Nov 2014 21:28:57 +0000 patchbomb: extract 'getpatches' closure in its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 04 Nov 2014 21:28:57 +0000] rev 23210
patchbomb: extract 'getpatches' closure in its own function Keep marching toward the promised land of simplification!
Tue, 04 Nov 2014 21:22:59 +0000 patchbomb: extract 'getoutgoing' closure into its own function
Pierre-Yves David <pierre-yves.david@fb.com> [Tue, 04 Nov 2014 21:22:59 +0000] rev 23209
patchbomb: extract 'getoutgoing' closure into its own function The patchbomb command is a gigantic 300 line function full of closures. As a first step to simplify it in smaller bits, I'm extracting the closures into full featured functions. The first victim is 'getoutgoing'. It gains a docstring in the process.
Thu, 06 Nov 2014 09:52:57 +0000 bundle2: handle empty 'b2x:changegroup' value in push and pull
Pierre-Yves David <pierre-yves.david@fb.com> [Thu, 06 Nov 2014 09:52:57 +0000] rev 23208
bundle2: handle empty 'b2x:changegroup' value in push and pull Changeset e4dc2b0be056 added advertising of supported changegroup version through the new 'b2x:changegroup' capability. However, this capability is not new and has been around since 3.1 with an empty value. This makes new clients unable to push to 3.2 servers through bundle2 as they cannot find a common changegroup version to use from and empty list. Treating empty 'b2x:changegroup' value as old client fixes it.
Thu, 06 Nov 2014 10:05:43 +0000 bundle2: drop duplicated definition of 'b2x:exchange'
Pierre-Yves David <pierre-yves.david@fb.com> [Thu, 06 Nov 2014 10:05:43 +0000] rev 23207
bundle2: drop duplicated definition of 'b2x:exchange' This bundle2 capability is going to be dynamically computed in 'getrepocaps'. We do not need to include it in the static value.
Thu, 06 Nov 2014 09:36:39 +0100 convert: use git diff-tree -Cn% instead of --find-copies=n% for older git stable
Thomas Arendsen Hein <thomas@intevation.de> [Thu, 06 Nov 2014 09:36:39 +0100] rev 23206
convert: use git diff-tree -Cn% instead of --find-copies=n% for older git The option --find-copies was added in a later git version than the one included in Debian squeeze-lts (1.7.2.5), probably around 1.7.4.
Sat, 18 Oct 2014 01:09:41 -0700 changelog: rely on transaction for finalization
Pierre-Yves David <pierre-yves.david@fb.com> [Sat, 18 Oct 2014 01:09:41 -0700] rev 23205
changelog: rely on transaction for finalization Instead of calling 'cl.finalize()' by hand (possibly at a bogus time) we register it in the transaction during 'delayupdate' and rely on 'tr.close()' to call it at the right time.
Fri, 17 Oct 2014 22:28:09 -0700 transaction: allow registering a finalization callback
Pierre-Yves David <pierre-yves.david@fb.com> [Fri, 17 Oct 2014 22:28:09 -0700] rev 23204
transaction: allow registering a finalization callback The new 'addfinalize' method allows people to register a callback to be triggered when the transaction is closed. This aims to get rid of explicit calls to 'changelog.finalize'. This also obsoletes the 'onclose' function but removing it is not in the scope of this series.
Fri, 17 Oct 2014 21:55:31 -0700 changelog: handle writepending in the transaction
Pierre-Yves David <pierre-yves.david@fb.com> [Fri, 17 Oct 2014 21:55:31 -0700] rev 23203
changelog: handle writepending in the transaction The 'delayupdate' method now takes a transaction object and registers its '_writepending' method for execution in 'transaction.writepending()'. The hook can then use 'transaction.writepending()' directly. At some point this will allow the addition of other file creation during writepending.
Fri, 17 Oct 2014 21:19:54 -0700 transaction: add 'writepending' logic
Pierre-Yves David <pierre-yves.david@fb.com> [Fri, 17 Oct 2014 21:19:54 -0700] rev 23202
transaction: add 'writepending' logic The contents of the transaction must be flushed to disk before running a hook. But it must be flushed to a special file so that the normal reader does not use it. This logic is currently in the changelog only. We add some facility to register such operations in the transaction itself.
Sat, 18 Oct 2014 01:12:18 -0700 changelog: rework the delayupdate mechanism
Pierre-Yves David <pierre-yves.david@fb.com> [Sat, 18 Oct 2014 01:12:18 -0700] rev 23201
changelog: rework the delayupdate mechanism The current way we use the 'delayupdate' mechanism is wrong. We call 'delayupdate' right after the transaction retrieval, then we call 'finalize' right before calling 'tr.close()'. The 'finalize' call will -always- result in a flush to disk, making the data available to all readers. But the 'tr.close()' may be a no-op if the transaction is nested. This would result in data: 1) exposed to reader too early, 2) rolled back by other part of the transaction after such exposure So we need to end up in a situation where we call 'finalize' a single time when the transaction actually closes. For this purpose we need to be able to call 'delayupdate' and '_writepending' multiple times and 'finalize' once. This was not possible with the previous state of the code. This changeset refactors the code to makes this possible. We buffer data in memory as much as possible and fall-back to writing to a ".a" file after the first call to '_writepending'.
Wed, 05 Nov 2014 12:41:12 -0600 merge with stable
Matt Mackall <mpm@selenic.com> [Wed, 05 Nov 2014 12:41:12 -0600] rev 23200
merge with stable
Wed, 05 Nov 2014 17:25:00 +0000 bookmarks: fix formatting of exchange message (issue4439) stable
Pierre-Yves David <pierre-yves.david@fb.com> [Wed, 05 Nov 2014 17:25:00 +0000] rev 23199
bookmarks: fix formatting of exchange message (issue4439) The message formatting was crashing when doing explicit pulling `hg pull -B X`. This changeset fix it and improved the test coverage.
Tue, 04 Nov 2014 12:26:06 -0800 test-status-rev: document one more broken test
Martin von Zweigbergk <martinvonz@google.com> [Tue, 04 Nov 2014 12:26:06 -0800] rev 23198
test-status-rev: document one more broken test The status for missing_content2_content2-untracked doesn't get reported at all. Since the file does exist in the working copy, it should reported as unknown. Document that in the test.
Tue, 04 Nov 2014 16:09:52 -0800 test-status-rev: use common script for generating file history
Martin von Zweigbergk <martinvonz@google.com> [Tue, 04 Nov 2014 16:09:52 -0800] rev 23197
test-status-rev: use common script for generating file history Start using the generate-working-copy-states.py script that's shared with test-revert.t, instead of creating the states manually in the test. This adds several states that are currently missing. We will start checking those states later.
Mon, 20 Oct 2014 23:56:55 -0700 test-status-rev: use same names as from generate-working-copy-states
Martin von Zweigbergk <martinvonz@google.com> [Mon, 20 Oct 2014 23:56:55 -0700] rev 23196
test-status-rev: use same names as from generate-working-copy-states To prepare for using generate-working-copy-states.py for generating the files and their content, let's start by renaming the files according to the naming scheme used by that script.
Mon, 03 Nov 2014 16:27:01 -0800 test-revert: move embedded script to its own file
Martin von Zweigbergk <martinvonz@google.com> [Mon, 03 Nov 2014 16:27:01 -0800] rev 23195
test-revert: move embedded script to its own file Move the gen-revert-cases.py out of test-revert.t into its own file so we can reuse it from other tests (specifically test-status-rev.t).
Sat, 18 Oct 2014 22:00:08 -0700 test-revert: simplify generation of files
Martin von Zweigbergk <martinvonz@google.com> [Sat, 18 Oct 2014 22:00:08 -0700] rev 23194
test-revert: simplify generation of files With the recent change in naming of the generated files, it becomes much easier to generate the files by iterating over all the possible states than over the state transitions.
Wed, 05 Nov 2014 11:16:31 -0600 merge with stable
Matt Mackall <mpm@selenic.com> [Wed, 05 Nov 2014 11:16:31 -0600] rev 23193
merge with stable
Wed, 05 Nov 2014 13:05:32 +0100 discovery: indices between sample and yesno must match (issue4438) stable
Mads Kiilerich <madski@unity3d.com> [Wed, 05 Nov 2014 13:05:32 +0100] rev 23192
discovery: indices between sample and yesno must match (issue4438) 3ef893520a85 changed 'sample' from a list to a set. The iteration order is thus undefined and the yesno indices are not stable. To solve this, repeat the listification and comment from elsewhere in the code. Note: the randomness in the discovery protocol can make this problem hard to reproduce.
Wed, 05 Nov 2014 13:05:29 +0100 discovery: limit 'all local heads known remotely' to real 'all' (issue4438) stable
Mads Kiilerich <madski@unity3d.com> [Wed, 05 Nov 2014 13:05:29 +0100] rev 23191
discovery: limit 'all local heads known remotely' to real 'all' (issue4438) 3ef893520a85 made it possible that the initial head check didn't include all heads. If that is the case, don't use the early exit just because this random sample happened to be 'all known'. Note: the randomness in the discovery protocol can make this problem hard to reproduce.
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: avoid printing messages while rebasing by "_lfstatuswriters"
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23190
largefiles: avoid printing messages while rebasing by "_lfstatuswriters" Putting "lambda *msg, **opts: None" (= avoid printing messages always) into "_lfstatuswriters" while rebasing makes explicit passing "printmessage = False" for "updatelfiles()" useless. This patch also removes setting/unsetting "repo._isrebasing" in "overriderebase", because there is no code path referring it.
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: get function to write status messages via "getstatuswriter()"
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23189
largefiles: get function to write status messages via "getstatuswriter()" This patch makes "updatelfiles()" get appropriate function to write largefiles specific status messages via "getstatuswriter()". This patch introduces None as "print messages if needed", because True (forcibly writing) and False (forcibly ignoring) are already used for "printmessage" of "updatelfiles". Subsequent patch will move "avoid printing messages only while automated committing" decision from caller of "updatelfiles()" into "getstatuswriter()".
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: introduce "_lfstatuswriters" to customize status reporting
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23188
largefiles: introduce "_lfstatuswriters" to customize status reporting "lfutil.getstatuswriter" is the utility to get appropriate function to write largefiles specific status out from "repo._lfstatuswriters". This patch uses "stack" with an element instead of flag like "_isXXXXing" or so, because: - the former works correctly even when customizations are nested, and - ensuring at least one element can ignore empty check
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: update standins only at the 1st commit of "hg rebase --continue"
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23187
largefiles: update standins only at the 1st commit of "hg rebase --continue" Before this patch, "hg rebase --continue" may record incorrect standins, because largefiles extension always avoid updating standins while rebasing, even though largefiles in the working directory may be modified manually at the 1st commit of "hg rebase --continue". But, on the other hand, updating standins should be avoided at subsequent commits for efficiency reason. To update standins only at the 1st commit of "hg rebase --continue", this patch introduces state-full callable object "automatedcommithook", which updates standins by "lfutil.updatestandinsbymatch()" only at the 1st commit of resuming. Even after this patch, "repo._isrebasing = True" is still needed to avoid some status report while updating largefiles in "lfcommands.updatelfiles()". This is reason why this patch omits not "repo._isrebasing = True" in "overriderebase" but examination of "getattr(repo, "_isrebasing", False)" in "updatestandinsbymatch".
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: introduce "_lfcommithooks" to abstract pre-committing procedures
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23186
largefiles: introduce "_lfcommithooks" to abstract pre-committing procedures This changes allows to customize pre-committing procedures according to conditions. This patch uses "stack" with an element instead of flag like "_isXXXXing" or so, because: - the former works correctly even when customizations are nested, and - ensuring at least one element can ignore empty check
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: factor out procedures to update standins for pre-committing
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23185
largefiles: factor out procedures to update standins for pre-committing This patch factors out procedures to update standins for pre-committing. This is one of preparations to avoid execution of such procedures according to invocation context. For example, resuming automated committing (e.g. "hg rebase --continue") should update standins at the 1st commit, because largefiles in the working directory may be modified manually. But on the other hand, it should avoid updating standins at subsequent committings for efficiency reason. For simplicity, this patch just moves procedures mechanically only with replacing below. - "self" => "repo" - "lfutil." => (none) - "orig" invocation => returning "match" Using "fstandin" instead "standin" as the name of local variable for the loop below is the only special care, because the latter shadows the same name function in "lfutil.py". [before] for standin in standins: lfile = lfutil.splitstandin(standin) if lfdirstate[lfile] != 'r': lfutil.updatestandin(self, standin) [after] for fstandin in standins: lfile = splitstandin(fstandin) if lfdirstate[lfile] != 'r': updatestandin(repo, fstandin)
Wed, 05 Nov 2014 23:24:47 +0900 largefiles: factor out procedures to update lfdirstate for post-committing
FUJIWARA Katsunori <foozy@lares.dti.ne.jp> [Wed, 05 Nov 2014 23:24:47 +0900] rev 23184
largefiles: factor out procedures to update lfdirstate for post-committing Before this patch, procedures to update lfdirstate for post-committing are scattered in "lfilesrepo.commit". In the case of "hg commit" with patterns for target files ("Case 2"), lfdirstate is updated BEFORE real committing. This patch factors out procedures to update lfdirstate for post-committing into "lfutil.markcommitted", and makes it callable via "markcommitted" of the context passed to "lfilesrepo.commitctx". "markcommitted" of the context is called, only when it is committed successfully. Passing original "markcommitted" of the context is meaningless in this patch, but required in subsequent one to prepare something before invocation of it.
(0) -10000 -3000 -1000 -300 -100 -60 +60 +100 +300 +1000 +3000 +10000 tip