Proposal: removeDirectoryRecursive should not follow symlinks

Ganesh Sittampalam ganesh at earth.li
Tue Jan 6 07:03:36 UTC 2015


On 06/01/2015 05:30, Greg Weber wrote:

> When I suggested deprecation, I assumed that following a symlink was a
> desirable behavior for someone. If it is not and it is 100% the case
> that this behavior is a defect, then this is just a bugfix then
> deprecation is not needed.

My general feeling is that it is just a bug.

> However, since this is considered dangerous, I think Eric makes an
> excellent point that it makes it possible for the function to be used
> properly for one compilation of a library that depends on `directory`,
> but for another compilation to pick up an older version of `directory`.
> That means that just fixing the behavior in the newest version of
> `directory` is not very satisfactory.
> 
> So I see 2 approaches to address these issues
> 
> 1) the deprecation warning approach
> 2) produce an updated point releases with the bugfix for every major
> version of directory. It still could be a good idea to do the
> deprecation warning on top of this because there are still older
> versions of the function out there with the bad behavior.

Will (2) this be enough for old GHCs, which will have a buggy version of
directory already installed? I think cabal will prefer the installed one
over a point release.

Ganesh



More information about the Libraries mailing list