( )โš™ D11012 dirstate: add a function to update tracking status while "moving" parents

This is an archive of the discontinued Mercurial Phabricator instance.

dirstate: add a function to update tracking status while "moving" parents
ClosedPublic

Authored by marmoute on Jul 7 2021, 5:20 PM.

Details

Summary

The scmutil.dirstateparent is moving the dirstate parent without touching the
working copy. It is used by history-rewriting operations like amending of
folding.

The function was directly doing the "low level" computation and dirstate
change. All that logic belong to the dirstate and should be moved there.

For this purpose we introduce a new function that does just that and use it.

Diff Detail

Repository
rHG Mercurial
Branch
default
Lint
No Linters Available
Unit
No Unit Test Coverage

Event Timeline

marmoute created this revision.Jul 7 2021, 5:20 PM
baymax updated this revision to Diff 28964.

โœ… refresh by Heptapod after a successful CI run (๐Ÿ™ ๐Ÿ’š)

baymax updated this revision to Diff 28997.

โœ… refresh by Heptapod after a successful CI run (๐Ÿ™ ๐Ÿ’š)

Alphare accepted this revision.Jul 9 2021, 12:01 PM
This revision is now accepted and ready to land.Jul 9 2021, 12:01 PM
baymax updated this revision to Diff 29144.Jul 10 2021, 3:09 PM

โœ… refresh by Heptapod after a successful CI run (๐Ÿ™ ๐Ÿ’š)

baymax retitled this revision from dirstate: add a function to update tracking status while "moving" parent to dirstate: add a function to update tracking status while "moving" parents.Jul 10 2021, 4:50 PM
baymax edited the summary of this revision. (Show Details)
baymax updated this revision to Diff 29148.

โœ… refresh by Heptapod after a successful CI run (๐Ÿ™ ๐Ÿ’š)

baymax updated this revision to Diff 29157.Jul 11 2021, 7:01 AM

โœ… refresh by Heptapod after a successful CI run (๐Ÿ™ ๐Ÿ’š)

baymax updated this revision to Diff 29244.Jul 15 2021, 11:16 AM

โœ… refresh by Heptapod after a successful CI run (๐Ÿ™ ๐Ÿ’š)

pulkit added a subscriber: pulkit.Jul 19 2021, 8:32 AM
pulkit added inline comments.
mercurial/dirstate.py
78

This will need a b'' prefix, can you follow-up for that?

marmoute added inline comments.Jul 19 2021, 8:56 AM
mercurial/dirstate.py
78

The b'' prefix is incompatible with func.__name__ is ti strictly necessary ?