[darcs-devel] [patch1954] resolve issue2639: darcs diff crashes with --last=1 an...

Ben Franksen bugs at darcs.net
Mon Feb 10 07:28:15 UTC 2020


Ben Franksen <ben.franksen at online.de> added the comment:

Ganesh: does this explanation satisfy you? I have a few follow-up
patches and would like to move on...

Quoting myself:
> So your initial assumption that this is all about path filtering was
> correct. The underlying problem is that we treat recorded and unrecorded
> changes differently with respect to path filtering. The former are taken
> as is, but the latter are filtered. Unapplying filtered unrecorded
> changes from the full working tree retains filtered-out files as they
> are (i.e. changed, relative to pristine), which means we may get an
> error when we unapply recorded changes (since these are not filtered).
> 
> The reason my patch fixes the problem is that it does not call
> readUnrecorded, but rather re-constructs a "filtered working tree" from
> the (filtered) unrecorded changes.
> 
> A less invasive fix would be to pass Nothing (instead of mpaths) to
> unrecordedChanges, which means we don't filter the unrecorded changes.
> Instead we only filter the Trees that we pass to the external diff
> command. This would perhaps be less efficient in cases where there are
> large amounts of unrecorded changes but only a small subset affect the
> files we are interested in.

__________________________________
Darcs bug tracker <bugs at darcs.net>
<http://bugs.darcs.net/patch1954>
__________________________________
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pEpkey.asc
Type: application/pgp-keys
Size: 4211 bytes
Desc: not available
URL: <http://lists.osuosl.org/pipermail/darcs-devel/attachments/20200210/c4580690/attachment.key>


More information about the darcs-devel mailing list