( )⚙ D8879 merge: replace use of actions dict with mergeresult object

This is an archive of the discontinued Mercurial Phabricator instance.

merge: replace use of actions dict with mergeresult object
ClosedPublic

Authored by pulkit on Aug 5 2020, 4:52 AM.

Details

Summary

There are still some places which can be improved by having a dedicated API,
this patch for now make all users of actions dict go through the mergeresult
object API.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

pulkit created this revision.Aug 5 2020, 4:52 AM
pulkit updated this revision to Diff 22301.Aug 6 2020, 7:14 AM
indygreg accepted this revision.

The introduction of sorting here is interesting. I guess we never sorted filenames before performing working directory modifications before? But surely there is sorting happening elsewhere because anything with ui output would need to be sorted to ensure determinism. And surely tests would have caught that.

Also, I remember there being an interplay between parallel workers and filesystem performance. Something about how file I/O is scheduled with respect to discrete directories. @durin42 might know more. (I remember mpm mentioning this when I was poking around with parallel workers and working directory operations several years ago.)

mercurial/merge.py
1413

The private attribute access here isn't great. But whatever.

This revision is now accepted and ready to land.Aug 8 2020, 12:22 PM