diff -r 967ac37f3d45 -r 160efb559f67 mercurial/context.py --- a/mercurial/context.py Sun Jul 09 15:11:19 2017 +0200 +++ b/mercurial/context.py Fri Jul 07 11:51:10 2017 -0700 @@ -38,6 +38,7 @@ repoview, revlog, scmutil, + sparse, subrepo, util, ) @@ -1803,6 +1804,11 @@ match.bad = bad return match + def markcommitted(self, node): + super(workingctx, self).markcommitted(node) + + sparse.aftercommit(self._repo, node) + class committablefilectx(basefilectx): """A committablefilectx provides common functionality for a file context that wants the ability to commit, e.g. workingfilectx or memfilectx."""