The error message from Stack is always after editting the code in Atom. I'll try to create a testcase. I doubt whether I get an error when editting the code with Notepad++. Reducing to a simpler case seems quit difficult to do. I'am still not sure if this is a Stack problem. Maybe it is a haskell-ghc-mod problem https://github.com/atom-haskell/haskell-ghc-mod/issues/189 It is a bit annoying that the error message doesn't tell what file/map is read-only and can't be deleted. I've searched in the directory of the program and its subdirs but nothing is read-only. The log files in the map logs do not change when I get the error after stack build.
Kees On Monday, November 7, 2016 at 10:55:26 AM UTC+1, Michael Snoyman wrote: > > That definitely narrows it down, it's a call to `removeDirRecur` in > Stack.Config. I don't know what could be causing the permissions issues. > Are you able to reproduce it with only Stack? Can you generate a minimal > case that demonstrates the issue occurring? > > On Mon, Nov 7, 2016 at 11:51 AM, kees Bleijenberg <[email protected] > <javascript:>> wrote: > >> I've narrowed down the problem. I only get the problem when I add >> elm-export to the cabal and yaml file as described in the Installation part >> of https://github.com/krisajenkins/elm-export >> The problem starts in Atom. Maybe the problem is not in stack but in >> ghc-mod?? >> >> stack -v buid >> Version 1.1.2, Git revision c6dac65e3174dea79df54ce6d56f3e98bc060ecc >> (3647 commits) x86_64 hpack-0.14.0 >> 2016-11-07 10:38:21.067318: [debug] Checking for project config at: >> D:\TBSchilder_1.0.3.0\source\glas\stack.yaml >> @(stack_9kewhubnl5WIl89fhd1ea2:Stack.Config src/Stack\Config.hs:811:9) >> 2016-11-07 10:38:21.067318: [debug] Loading project config file >> stack.yaml @(stack_9kewhubnl5WIl89fhd1ea2:Stack.Config >> src/Stack\Config.hs:829:13) >> 2016-11-07 10:38:21.067318: [debug] Trying to decode >> D:\stackRoot\build-plan-cache\x86_64-windows\lts-7.2.cache >> @(stack_9kewhubnl5WIl89fhd1ea2:Data.Binary.VersionTagged >> src/Data\Binary\VersionTagged.hs:55:5) >> 2016-11-07 10:38:21.077318: [debug] Success decoding >> D:\stackRoot\build-plan-cache\x86_64-windows\lts-7.2.cache >> @(stack_9kewhubnl5WIl89fhd1ea2:Data.Binary.VersionTagged >> src/Data\Binary\VersionTagged.hs:64:13) >> 2016-11-07 10:38:21.087318: [debug] Getting system compiler version >> @(stack_9kewhubnl5WIl89fhd1ea2:Stack.Setup src/Stack\Setup.hs:341:17) >> 2016-11-07 10:38:21.087318: [debug] Asking GHC for its version >> @(stack_9kewhubnl5WIl89fhd1ea2:Stack.Setup.Installed >> src/Stack\Setup\Installed.hs:94:13) >> 2016-11-07 10:38:21.087318: [debug] Run process: ghc --numeric-version >> @(stack_9kewhubnl5WIl89fhd1ea2:System.Process.Read >> src/System\Process\Read.hs:283:3) >> 2016-11-07 10:38:21.107318: [debug] Getting Cabal package version >> @(stack_9kewhubnl5WIl89fhd1ea2:Stack.GhcPkg src/Stack\GhcPkg.hs:165:5) >> 2016-11-07 10:38:21.107318: [debug] Run process: ghc-pkg >> --no-user-package-db field --simple-output Cabal version >> @(stack_9kewhubnl5WIl89fhd1ea2:System.Process.Read >> src/System\Process\Read.hs:283:3) >> 2016-11-07 10:38:21.164320: [debug] Resolving package entries >> @(stack_9kewhubnl5WIl89fhd1ea2:Stack.Setup src/Stack\Setup.hs:221:5) >> 2016-11-07 10:38:21.164320: [debug] Run process: git reset --hard >> 2a026e4c3a93a18006595636e783955223f9b98e -- >> @(stack_9kewhubnl5WIl89fhd1ea2:System.Process.Read >> src/System\Process\Read.hs:283:3) >> removeDirectoryRecursive: permission denied (Access is denied.) >> >> After upgrading stack: >> stack -v build >> Version 1.2.0, Git revision 123819b7d65df2ad7fe63fb5eb39a98536acb5f3 >> (4055 commits) x86_64 hpack-0.14.0 >> 2016-11-07 10:45:16.148733: [debug] Checking for project config at: >> D:\TBSchilder_1.0.3.0\source\glas\stack.yaml >> @(Stack\Config.hs:792:9) >> 2016-11-07 10:45:16.149733: [debug] Loading project config file stack.yaml >> @(Stack\Config.hs:810:13) >> 2016-11-07 10:45:16.152733: [debug] Trying to decode >> D:\stackRoot\build-plan-cache\x86_64-windows\lts-7.2.cache >> @(Data\Store\VersionTagged.hs:68:5) >> 2016-11-07 10:45:16.164733: [debug] Success decoding >> D:\stackRoot\build-plan-cache\x86_64-windows\lts-7.2.cache >> @(Data\Store\VersionTagged.hs:72:13) >> 2016-11-07 10:45:16.168734: [debug] Getting system compiler version >> @(Stack\Setup.hs:354:17) >> 2016-11-07 10:45:16.183735: [debug] Using standard GHC build >> @(Stack\Setup.hs:537:9) >> 2016-11-07 10:45:16.183735: [debug] Getting Cabal package version >> @(Stack\GhcPkg.hs:171:5)2016-11-07 10:45:16.184735: [debug] Getting >> global package database location >> >> 2016-11-07 10:45:16.184735: [debug] Asking GHC for its version >> @(Stack\GhcPkg.hs:54:5)@(Stack\Setup\Installed.hs:101:13) >> 2016-11-07 10:45:16.184735: [debug] Run process: >> C:\Users\kees\AppData\Local\Programs\stack\x86_64-windows\ghc-8.0.1\bin\ghc-pkg.EXE >> >> --no-user-package-db field --simple-output Cabal version >> >> @(System\Process\Read.hs:277:3)2016-11-07 10:45:16.185735: [debug] Run >> process: >> C:\Users\kees\AppData\Local\Programs\stack\x86_64-windows\ghc-8.0.1\bin\ghc-pkg.EXE >> >> --no-user-package-db list --global >> >> 2016-11-07 10:45:16.185735: [debug] Run process: >> C:\Users\kees\AppData\Local\Programs\stack\x86_64-windows\ghc-8.0.1\bin\ghc.EXE >> >> --numeric-version >> @(System\Process\Read.hs:277:3)@(System\Process\Read.hs:277:3) >> >> 2016-11-07 10:45:16.213736: [debug] Process finished in 21 ms: >> C:\Users\kees\AppData\Local\Programs\stack\x86_64-windows\ghc-8.0.1\bin\ghc.EXE >> >> --numeric-version >> @(System\Process\Read.hs:277:3) >> 2016-11-07 10:45:16.251738: [debug] Process finished in 65 ms: >> C:\Users\kees\AppData\Local\Programs\stack\x86_64-windows\ghc-8.0.1\bin\ghc-pkg.EXE >> >> --no-user-package-db field --simple-output Cabal version >> @(System\Process\Read.hs:277:3) >> 2016-11-07 10:45:16.251738: [debug] Process finished in 61 ms: >> C:\Users\kees\AppData\Local\Programs\stack\x86_64-windows\ghc-8.0.1\bin\ghc-pkg.EXE >> >> --no-user-package-db list --global >> @(System\Process\Read.hs:277:3) >> 2016-11-07 10:45:16.251738: [debug] Resolving package entries >> @(Stack\Setup.hs:234:5) >> 2016-11-07 10:45:16.260739: [debug] Run process: D:\Program >> Files\Git\cmd\git.EXE reset --hard 2a026e4c3a93a18006595636e783955223f9b98e >> -- >> @(System\Process\Read.hs:277:3) >> 2016-11-07 10:45:16.290741: [info] Failed to reset to commit >> 2a026e4c3a93a18006595636e783955223f9b98e, deleting and re-cloning. >> @(Stack\Config.hs:580:21) >> removeDirectoryRecursive: permission denied (Access is denied.) >> >> >> On Monday, November 7, 2016 at 7:36:34 AM UTC+1, Michael Snoyman wrote: >>> >>> There's only one call to removeDirectoryRecursive I see in the Stack >>> codebase, and that applies for install MSYS2 on Windows, which is probably >>> _not_ relevant to what you're doing right now. Do you have any indication >>> from the logs of what was happening immediately before or after? Can you >>> run with `--verbose` and get more detailed logs? What about upgrading to >>> the latest version of Stack? >>> >>> On Sat, Nov 5, 2016 at 9:22 PM, kees Bleijenberg <[email protected] >>> > wrote: >>> >>>> I edit the code in Atom, After a few updates I get the error >>>> removeDirectoryRecursive.....in the red box. When I cose Atom and I do >>>> stack build in cmd.exe I get again: >>>> removeDirectoryRecursive: permission denied (Access is denied.) >>>> If I remove the directory .stack-work and I do stack build again, >>>> everything is ok. But not for long. After a few updates of the code the >>>> error is back again. >>>> I'am using stack version 1.1.2 on windows 7. >>>> >>>> Kees >>>> >>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "haskell-stack" group. >>>> To unsubscribe from this group and stop receiving emails from it, send >>>> an email to [email protected]. >>>> To post to this group, send email to [email protected]. >>>> To view this discussion on the web visit >>>> https://groups.google.com/d/msgid/haskell-stack/af6a4ed9-fc63-4c0f-af61-8e1e7849db3e%40googlegroups.com >>>> >>>> <https://groups.google.com/d/msgid/haskell-stack/af6a4ed9-fc63-4c0f-af61-8e1e7849db3e%40googlegroups.com?utm_medium=email&utm_source=footer> >>>> . >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >> You received this message because you are subscribed to the Google Groups >> "haskell-stack" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> To post to this group, send email to [email protected] >> <javascript:>. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/haskell-stack/cc91145a-6059-4d6f-b650-84786e86f665%40googlegroups.com >> >> <https://groups.google.com/d/msgid/haskell-stack/cc91145a-6059-4d6f-b650-84786e86f665%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- You received this message because you are subscribed to the Google Groups "haskell-stack" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/haskell-stack/c24245b6-bd57-4b76-b7cb-42e1cf612688%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
