You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Store "stack-path" files in directories that have been shortened with SHAs #1173
The resolution for #1145 / #1027 is to replace some long paths with 8 character SHAs on windows, due to the MAX_PATH limitation. It would be good to store a file, maybe called SHA/stack-path, with the path that would have been used in place of the SHA. This is useful for a variety circumstances:
It gets a little bit tricky to ensure that every possible execution involving these paths will also create the path file, though. These paths are used in quite a few places, and often they get created be external tools.
It gets a little bit tricky to ensure that every possible execution involving these paths will also create the path file, though. These paths are used in quite a few places, and often they get created be external tools.
I'm thinking that the solution here is to have an in-memory cache of whether a particular path.yaml file has been written - something like Set (Path Abs Dir). Then we can just check this cache each time the paths are used. While this is slightly less efficient than statically knowing when to initialize these path.yaml files, it also seems less error-prone.
Creating these path.yaml files also means creating the folders. This means that functions like installationRootLocal, installationRootDeps, and distRelativeDir will have the side effect of creating the folders, when on windows. This seems relatively benign to me, but I think it makes sense to also create the folders on linux, for the sake of consistency.
Activity
DemiMarie commentedon Oct 20, 2015
Another solution is to do what CoreCLR is doing – have GHC implicitly use extended paths.
mgsloan commentedon Oct 23, 2015
I'm thinking that the solution here is to have an in-memory cache of whether a particular
path.yamlfile has been written - something likeSet (Path Abs Dir). Then we can just check this cache each time the paths are used. While this is slightly less efficient than statically knowing when to initialize thesepath.yamlfiles, it also seems less error-prone.Creating these
path.yamlfiles also means creating the folders. This means that functions likeinstallationRootLocal,installationRootDeps, anddistRelativeDirwill have the side effect of creating the folders, when on windows. This seems relatively benign to me, but I think it makes sense to also create the folders on linux, for the sake of consistency.snoyberg commentedon Mar 20, 2019
Moved to wishlist: https://github.com/commercialhaskell/stack/wiki/Wishlist