Skip to content
This repository has been archived by the owner on Apr 25, 2020. It is now read-only.

Error: module Main defined in multiple files #609

Open
DanielG opened this issue Sep 17, 2015 · 10 comments
Open

Error: module Main defined in multiple files #609

DanielG opened this issue Sep 17, 2015 · 10 comments

Comments

@DanielG
Copy link
Owner

DanielG commented Sep 17, 2015

Probably has something to do with map-file.

% ghc-mod root
/home/dxld/share/dev/hs/ghc-mod
% boot
...
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod.hs
% ghc-mod root
/home/dxld/share/dev/hs/ghc-mod
O: ()
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
O: ("Language/Haskell/GhcMod/CabalHelper.hs:240:1:Parse error: naked expression at top level
O: Perhaps you intended to use TemplateHaskell")
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
O: ("Language/Haskell/GhcMod/CabalHelper.hs:240:1:Parse error: naked expression at top level
O: Perhaps you intended to use TemplateHaskell")
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
O: ("Language/Haskell/GhcMod/CabalHelper.hs:242:1:Parse error: naked expression at top level
O: Perhaps you intended to use TemplateHaskell")
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
O: ("Language/Haskell/GhcMod/CabalHelper.hs:240:1:Warning: Defined but not used: ‘hello’" "Language/Haskell/GhcMod/CabalHelper.hs:240:1:Warning: Top-level binding with no type signature: hello :: Integer" "Language/Haskell/GhcMod/CabalHelper.hs:240:9:Warning: Defaulting the following constraint(s) to type ‘Integer’
O:   (Num a0) arising from the literal ‘123’
O: In the expression: 123
O: In an equation for ‘hello’: hello = 123" "Language/Haskell/GhcMod/CabalHelper.hs:242:1:Warning: Defined but not used: ‘asdasdasd’" "Language/Haskell/GhcMod/CabalHelper.hs:242:1:Warning: Top-level binding with no type signature: asdasdasd :: Integer" "Language/Haskell/GhcMod/CabalHelper.hs:242:13:Warning: Defaulting the following constraint(s) to type ‘Integer’
O:   (Num a0) arising from the literal ‘123’
O: In the expression: 123
O: In an equation for ‘asdasdasd’: asdasdasd = 123")
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
O: ()
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs
CONTENTS + EOT
O: OK
% info /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/CabalHelper.hs map
O: "map :: (a -> b) -> [a] -> [b]   -- Defined in ‘GHC.Base’"
O: OK
% ghc-mod doc GHC.Base

% ghc-mod root
/home/dxld/share/dev/hs/ghc-mod
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs
CONTENTS + EOT
O: OK
% check /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs
O: ()
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs
CONTENTS + EOT
O: OK
% type /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs 21 26
O: ((21 21 21 27 "IO String -> GmT (GmOutT m) String") (21 21 21 78 "GmT (GmOutT m) String") (20 12 23 19 "GmT (GmOutT m) String") (18 5 23 19 "GmT (GmOutT m) String") (13 14 23 19 "GmT (GmOutT m) String") (13 1 29 39 "String -> GhcModT m String"))
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs
CONTENTS + EOT
O: OK
% type /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs 27 6
O: ((27 5 28 48 "[Char] -> [GhcPkgDb] -> [[Char]]") (13 1 29 39 "String -> GhcModT m String"))
O: OK
% map-file /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs
CONTENTS + EOT
O: OK
% type /home/dxld/dev/hs/ghc-mod/Language/Haskell/GhcMod/PkgDoc.hs 27 34
O: ((27 29 27 36 "[Char]") (27 28 27 58 "[[Char]]") (27 28 28 48 "[[Char]]") (27 5 28 48 "[Char] -> [GhcPkgDb] -> [[Char]]") (13 1 29 39 "String -> GhcModT m String"))
O: OK
% ghc-mod root
/home/dxld/share/dev/hs/ghc-mod
% map-file /home/dxld/share/dev/hs/ghc-mod/Language/Haskell/GhcMod/Output.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/Language/Haskell/GhcMod/Output.hs
E: ghc-mod-5.4.0.0: configure
E: Configuring ghc-mod-5.4.0.0...
O: ()
O: OK
% ghc-mod root
/home/dxld/share/dev/hs/ghc-mod
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
E: ghc-mod-5.4.0.0: configure
E: Configuring ghc-mod-5.4.0.0...
E: [1 of 5] Compiling CabalHelper.Types ( CabalHelper/Types.hs, /home/dxld/.ghc-mod/cabal-helper/CabalHelper/Types.o )
E: [2 of 5] Compiling CabalHelper.Common ( CabalHelper/Common.hs, /home/dxld/.ghc-mod/cabal-helper/CabalHelper/Common.o )
E: [3 of 5] Compiling CabalHelper.Sandbox ( CabalHelper/Sandbox.hs, /home/dxld/.ghc-mod/cabal-helper/CabalHelper/Sandbox.o )
E: [4 of 5] Compiling CabalHelper.Licenses ( CabalHelper/Licenses.hs, /home/dxld/.ghc-mod/cabal-helper/CabalHelper/Licenses.o )
E: [5 of 5] Compiling Main             ( CabalHelper/Main.hs, /home/dxld/.ghc-mod/cabal-helper/Main.o )
E: Linking /home/dxld/.ghc-mod/cabal-helper/cabal-helper-0.6.0.0-Cabal-1.22.4.0 ...
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:34:5:Not in scope: ‘liftIO’" "test/manual/not-interpreted-error/GhcTestcase.hs:34:25:Not in scope: ‘showOneLine’" "test/manual/not-interpreted-error/GhcTestcase.hs:34:37:Not in scope: ‘dflags’
O: Perhaps you meant one of these:
O:   ‘dflags0’ (line 20), ‘dflags1’ (line 21), ‘dflags2’ (line 27)" "test/manual/not-interpreted-error/GhcTestcase.hs:34:46:Not in scope: ‘pprTypeForUser’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:35:25:Not in scope: ‘showOneLine’" "test/manual/not-interpreted-error/GhcTestcase.hs:35:37:Not in scope: ‘dflags’
O: Perhaps you meant one of these:
O:   ‘dflags0’ (line 21), ‘dflags1’ (line 22), ‘dflags2’ (line 28)" "test/manual/not-interpreted-error/GhcTestcase.hs:35:46:Not in scope: ‘pprTypeForUser’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% info /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs showOneLine
E: EXCEPTION: info:     Not in scope: ‘showOneLine’
O: "Cannot show info"
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:35:37:Not in scope: ‘dflags’
O: Perhaps you meant one of these:
O:   ‘dflags0’ (line 21), ‘dflags1’ (line 22), ‘dflags2’ (line 28)" "test/manual/not-interpreted-error/GhcTestcase.hs:35:46:Not in scope: ‘pprTypeForUser’" "test/manual/not-interpreted-error/GhcTestcase.hs:43:28:Not in scope: type constructor or class ‘SDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:44:39:Not in scope: data constructor ‘OneLineMode’" "test/manual/not-interpreted-error/GhcTestcase.hs:46:21:Not in scope: type constructor or class ‘PprStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:20:Not in scope: ‘mkUserStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:32:Not in scope: ‘neverQualify’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:45:Not in scope: data constructor ‘AllTheWay’" "test/manual/not-interpreted-error/GhcTestcase.hs:49:27:Not in scope: ‘Pretty.showDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:51:13:Not in scope: ‘withPprStyleDoc’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:35:47:Not in scope: ‘pprTypeForUser’" "test/manual/not-interpreted-error/GhcTestcase.hs:43:28:Not in scope: type constructor or class ‘SDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:44:39:Not in scope: data constructor ‘OneLineMode’" "test/manual/not-interpreted-error/GhcTestcase.hs:46:21:Not in scope: type constructor or class ‘PprStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:20:Not in scope: ‘mkUserStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:32:Not in scope: ‘neverQualify’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:45:Not in scope: data constructor ‘AllTheWay’" "test/manual/not-interpreted-error/GhcTestcase.hs:49:27:Not in scope: ‘Pretty.showDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:51:13:Not in scope: ‘withPprStyleDoc’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:44:28:Not in scope: type constructor or class ‘SDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:45:39:Not in scope: data constructor ‘OneLineMode’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:21:Not in scope: type constructor or class ‘PprStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:48:20:Not in scope: ‘mkUserStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:48:32:Not in scope: ‘neverQualify’" "test/manual/not-interpreted-error/GhcTestcase.hs:48:45:Not in scope: data constructor ‘AllTheWay’" "test/manual/not-interpreted-error/GhcTestcase.hs:50:27:Not in scope: ‘Pretty.showDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:52:13:Not in scope: ‘withPprStyleDoc’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:44:28:Not in scope: type constructor or class ‘SDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:45:39:Not in scope: data constructor ‘OneLineMode’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:21:Not in scope: type constructor or class ‘PprStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:48:20:Not in scope: ‘mkUserStyle’" "test/manual/not-interpreted-error/GhcTestcase.hs:48:32:Not in scope: ‘neverQualify’" "test/manual/not-interpreted-error/GhcTestcase.hs:48:45:Not in scope: data constructor ‘AllTheWay’" "test/manual/not-interpreted-error/GhcTestcase.hs:50:27:Not in scope: ‘Pretty.showDoc’" "test/manual/not-interpreted-error/GhcTestcase.hs:52:13:Not in scope: ‘withPprStyleDoc’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:46:39:Not in scope: data constructor ‘OneLineMode’" "test/manual/not-interpreted-error/GhcTestcase.hs:51:27:Not in scope: ‘Pretty.showDoc’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:52:1:Warning: Top-level binding with no type signature:
O:   showDocWith :: DynFlags -> Mode -> Doc -> String" "test/manual/not-interpreted-error/GhcTestcase.hs:54:1:Warning: Top-level binding with no type signature:
O:   withStyle :: DynFlags -> PprStyle -> SDoc -> Doc")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:47:21:Not in scope: ‘showDocWith’" "test/manual/not-interpreted-error/GhcTestcase.hs:47:53:Not in scope: ‘withStyle’")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:52:1:Warning: Top-level binding with no type signature:
O:   showDocWith :: DynFlags -> Mode -> Doc -> String" "test/manual/not-interpreted-error/GhcTestcase.hs:54:1:Warning: Top-level binding with no type signature:
O:   withStyle :: DynFlags -> PprStyle -> SDoc -> Doc")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("test/manual/not-interpreted-error/GhcTestcase.hs:53:1:Warning: Top-level binding with no type signature:
O:   showDocWith :: DynFlags -> Mode -> Doc -> String" "test/manual/not-interpreted-error/GhcTestcase.hs:55:1:Warning: Top-level binding with no type signature:
O:   withStyle :: DynFlags -> PprStyle -> SDoc -> Doc")
O: OK
% ghc-mod root
/home/dxld/share/dev/hs/ghc-mod
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase17345751981973594324.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1497983152038664370.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase17345751981973594324.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1129566413184803526.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase4127760911424268980.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1129566413184803526.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase1911759956749241873.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1129566413184803526.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase13780686242999170.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1129566413184803526.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase982906996135497281.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1129566413184803526.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/GhcTestcase.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase5117023052084420925.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main1129566413184803526.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase5117023052084420925.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main19374770841827336327.hs")
O: OK
% map-file /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
CONTENTS + EOT
O: OK
% check /home/dxld/share/dev/hs/ghc-mod/test/manual/not-interpreted-error/Main.hs
O: ("Dummy:0:0:Error:module ‘main@main:Main’ is defined in multiple files: /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/GhcTestcase5117023052084420925.hs
O:                                                       /tmp/ghc-mod-home-dxld-share-dev-hs-ghc-mod23595/Main5726603361159126505.hs")
O: OK
@DanielG
Copy link
Owner Author

DanielG commented Sep 17, 2015

I think this might happen when I have at least two buffers open, both declaring module Main and both are being mapped down to the library component because they are not part of any of the module closures.

@DanielG
Copy link
Owner Author

DanielG commented Sep 18, 2015

@kazu-yamamoto could you please implement unmapping files in the elisp frontend? I think the problem here is that we only ever map-file but never remove the mapping. I think we should be doing something like:

map-file bla.hs
check bla.hs
unmap-file bla.hs

@PierreR
Copy link
Contributor

PierreR commented Dec 3, 2015

👍
I have the same error message whenever I start to write multiple test files on a project. There are indeed multiple buffers with a Main module loaded at that point.

I am using the latest from master bff86be with the elisp file (ghc-20151013.1219) coming from melpa.

@DanielG
Copy link
Owner Author

DanielG commented Dec 4, 2015

@PierreR Give this branch a spin: #693 I've been carrying that patch locally for a while now, cleaned it up a bit.

@PierreR
Copy link
Contributor

PierreR commented Apr 21, 2016

@DanielG I am back to a normal release "ghc-mod version 5.5.0.0 compiled by GHC 7.10.3".

I have just got the problem again. Have your changes still local ?

@DanielG
Copy link
Owner Author

DanielG commented Apr 21, 2016

@PierreR Can you open a new issue and describe exactly what you're doing to cause the error? A copy of *GHC Debug* would be enormously helpful too.

@DanielG
Copy link
Owner Author

DanielG commented May 26, 2017

First attempt at fixing this: 02f664a. Will keep this in the dev-elisp branch until I'm convinced it doesn't race or break anything. Testers welcome.

@asheshambasta
Copy link

I don't know if this helps but I'm seeing the same issues in GHC Error;

**GHC error**

EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Permissions’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Permissions1137623865997389814.hs
                                                                         src/Data/Types/Permissions.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Permissions’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Permissions1137623865997389814.hs
                                                                         src/Data/Types/Permissions.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Permissions’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Permissions1137623865997389814.hs
                                                                         src/Data/Types/Permissions.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs
EXCEPTION: browse:
           module ‘Data.Types.Permissions’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Permissions1137623865997389814.hs
                                                                         src/Data/Types/Permissions.hs
EXCEPTION: browse:
           module ‘Data.Types.Area’ is defined in multiple files: /var/folders/kx/y9231gps2fldv7xgpk3xpjw00000gn/T/ghc-mod38048/Area18171295601131570933.hs
                                                                  src/Data/Types/Area.hs

**GHC Debug**

Path: check if you are using intended programs.
	  ghc.el path: /Users/asheshambasta/.emacs.d/elpa/ghc-5.8.0.0/ghc.el
	 ghc-mod path: /Users/asheshambasta/.local/bin/ghc-mod
	     ghc path: /usr/local/bin/ghc

Version: all GHC versions must be the same.
	  ghc.el version 5.8.0.0
	 ghc-mod version 5.8.0.0 compiled by GHC 8.0.2
	The Glorious Glasgow Haskell Compilation System, version 8.2.2

Environment variables:
	PATH=/Users/asheshambasta/.cabal/bin:/Users/asheshambasta/.local/bin:/usr/local/bin:/Users/asheshambasta/.cabal/bin:/Users/asheshambasta/.local/bin:/usr/local/bin:/Users/asheshambasta/.cabal/bin:/Users/asheshambasta/.local/bin:/usr/local/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin:/opt/ImageMagick/bin:/Applications/Wireshark.app/Contents/MacOS:/Users/asheshambasta/.rvm/bin

The result of "ghc-mod debug":
Version:              ghc-mod-5.8.0.0
Library GHC Version:  8.0.2
System GHC Version:   8.0.2
Root directory:       /Users/asheshambasta/code/haskell/spock/Spock-rest
Current directory:    /Users/asheshambasta/code/haskell/spock/Spock-rest
GHC Package flags:
    -fbuilding-cabal-package -O -outputdir
    .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -odir
    .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -hidir
    .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -stubdir
    .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -i
    -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -isrc
    -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
    -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
    -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -optP-include
    -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h
    -this-unit-id Spock-rest-0.1.0.0-4PSHfUCADkvXIgr45Y8SN
    -hide-all-packages -no-user-package-db -package-db
    /Users/asheshambasta/.stack/snapshots/x86_64-osx/lts-8.13/8.0.2/pkgdb
    -package-db
    /Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/install/x86_64-osx/lts-8.13/8.0.2/pkgdb
    -package-id MonadRandom-0.5.1-IY6HiWu00vQLARukQW3KMH -package-id
    Spock-0.12.0.0-HrjBtiKRVpc5zeFyZXjlPH -package-id
    Spock-core-0.12.0.0-6R7wuW37GruCyDAQ6RxLb9 -package-id
    aeson-0.11.3.0-6KZhhAoYhStJEHF28MdoG1 -package-id
    amqp-0.14.1-FvRQeOtOCHwBY1AZv5k1sd -package-id base-4.9.1.0
    -package-id base64-bytestring-1.0.0.1-4O9TExPPz6eI82Yj7L4SIj
    -package-id bytestring-0.10.8.1 -package-id
    cryptonite-0.21-G3auqyG86Do30r1nrVHiPT -package-id
    esqueleto-2.5.1-Bv42CVdpnj47LROGXP04li -package-id
    http-api-data-0.3.7-Fjq248miKA8D5hFdZGD7aB -package-id
    http-types-0.9.1-AUkzzKpOoLmKIvDSpmjcFz -package-id
    hvect-0.4.0.0-Bz3s0s4mhGy1edxe23N084 -package-id
    memory-0.14.5-3ZpYY8ZZOR4DS7cmS82LIK -package-id
    monad-log-0.1.1.0-EXsOlfBmFYaDoNe3UXOGKx -package-id
    monad-logger-0.3.23-JTS4X30MorOF9sRBPO0yDx -package-id
    mtl-2.2.1-BLKBelFsPB3BoFeSWSOYj6 -package-id
    parallel-3.2.1.1-KQJHWCcq2Ka569Stb10nhx -package-id
    persistent-2.6.1-BzNAnINH0anHwGhCB3Dp3U -package-id
    persistent-mysql-2.6.0.1-H8HST8XZEN9FzUn6odZDw9 -package-id
    persistent-sqlite-2.6.2-9axGkUlysug6nCTbfNSYox -package-id
    persistent-template-2.5.2-DJD2ymvDKVlKrE4ioBwCDx -package-id
    random-1.1-9tceXaeYIMZ4JrKq20Egog -package-id
    safe-0.3.14-GsbXn9D9F3BDazVNcErzdQ -package-id
    stm-2.4.4.1-JQn4hNPyYjP5m9AcbI88Ve -package-id
    text-1.2.2.1-Ji7hMs2U4BkBwavd4taEVR -package-id time-1.6.0.1
    -package-id transformers-0.5.2.0 -package-id
    unordered-containers-0.2.8.0-1XEErQCPPPc2SEtcHHNx9o -package-id
    utf8-string-1.0.1.1-1DpjxLeTvGg7ttZZojxJR5 -package-id
    uuid-1.3.13-CZRAA7iBrqCJQ7lNFsqpMd -package-id
    vector-0.11.0.0-LMwQhhnXj8U3T5Bm1JFxG -package-id
    wai-extra-3.0.19.1-ETFxpI40PwTAQ0NwGpl7g5 -XHaskell2010
GHC System libraries: /Users/asheshambasta/.stack/programs/x86_64-osx/ghc-8.0.2/lib/ghc-8.0.2
Stack ghc executable:    Just "/Users/asheshambasta/.stack/programs/x86_64-osx/ghc-8.0.2/bin/ghc"
Stack ghc-pkg executable:Just "/Users/asheshambasta/.stack/programs/x86_64-osx/ghc-8.0.2/bin/ghc-pkg"
cabal-install Version: 2.0.0.1
Cabal Library Versions:
    Cabal-1.24.2.0
Cabal file:            Just "/Users/asheshambasta/code/haskell/spock/Spock-rest/Spock-rest.cabal"
Project:               StackProject (StackEnv {seDistDir = ".stack-work/dist/x86_64-osx/Cabal-1.24.2.0", seBinPath = ["/Users/asheshambasta/.stack/snapshots/x86_64-osx/lts-8.13/8.0.2/bin","/Users/asheshambasta/.stack/compiler-tools/x86_64-osx/ghc-8.0.2/bin","/Users/asheshambasta/.stack/programs/x86_64-osx/ghc-8.0.2/bin","/Users/asheshambasta/.cabal/bin","/Users/asheshambasta/.local/bin","/usr/local/bin","/Users/asheshambasta/.cabal/bin","/Users/asheshambasta/.local/bin","/usr/local/bin","/Users/asheshambasta/.cabal/bin","/Users/asheshambasta/.local/bin","/usr/local/bin","/usr/local/bin","/usr/bin","/bin","/usr/sbin","/sbin","/opt/X11/bin","/opt/ImageMagick/bin","/Applications/Wireshark.app/Contents/MacOS","/Users/asheshambasta/.rvm/bin"], seSnapshotPkgDb = "/Users/asheshambasta/.stack/snapshots/x86_64-osx/lts-8.13/8.0.2/pkgdb", seLocalPkgDb = "/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/install/x86_64-osx/lts-8.13/8.0.2/pkgdb"})
Cabal entrypoints:
    Setup.hs
        Main (/Users/asheshambasta/code/haskell/spock/Spock-rest/Setup.hs)
    library
        App.DB.Helpers (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/DB/Helpers.hs)
        App.Errors (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Errors.hs)
        App.Errors.AreaNodes (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Errors/AreaNodes.hs)
        App.Errors.Users (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Errors/Users.hs)
        App.Logging (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Logging.hs)
        App.Routes.AreaNodes.Auths (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/AreaNodes/Auths.hs)
        App.Routes.AreaNodes.Updates (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/AreaNodes/Updates.hs)
        App.Routes.Helpers (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Helpers.hs)
        App.Routes.Hooks.AreaNodes (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Hooks/AreaNodes.hs)
        App.Routes.Hooks.Users (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Hooks/Users.hs)
        App.Routes.Users (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Users.hs)
        App.Routes.Users.Areas (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Users/Areas.hs)
        App.Types (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Types.hs)
        App.Types.MQ (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Types/MQ.hs)
        App.Types.Spock (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Types/Spock.hs)
        Data.Types.Area (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Area.hs)
        Data.Types.AreaNode (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/AreaNode.hs)
        Data.Types.CustomFields (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/CustomFields.hs)
        Data.Types.Grants (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Grants.hs)
        Data.Types.Node (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Node.hs)
        Data.Types.Permissions (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Permissions.hs)
        Data.Types.Security.Tokens (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Security/Tokens.hs)
        Data.Types.Security.User.Auth (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Security/User/Auth.hs)
        Data.Types.Updates (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Updates.hs)
        Data.Types.User (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/User.hs)
        Lib (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib.hs)
        Lib.Ids (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/Ids.hs)
        Lib.JSON (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/JSON.hs)
        Lib.Text (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/Text.hs)
        Lib.Time (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/Time.hs)
        Paths_Spock_rest (/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/Paths_Spock_rest.hs)
    exe:Spock-rest-exe
        Main (/Users/asheshambasta/code/haskell/spock/Spock-rest/app/Main.hs)
        Paths_Spock_rest (/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/Paths_Spock_rest.hs)
    test:Spock-rest-test
        Main (/Users/asheshambasta/code/haskell/spock/Spock-rest/test/Spec.hs)
        Paths_Spock_rest (/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/Paths_Spock_rest.hs)
Cabal components:
    Setup.hs
        Main (/Users/asheshambasta/code/haskell/spock/Spock-rest/Setup.hs)
    library
        App.DB.Helpers (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/DB/Helpers.hs)
            App.Types.Spock
        App.Errors (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Errors.hs)
        App.Errors.AreaNodes (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Errors/AreaNodes.hs)
        App.Errors.Users (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Errors/Users.hs)
        App.Logging (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Logging.hs)
            App.Types.Spock
            Lib.Text
        App.Routes.AreaNodes.Auths (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/AreaNodes/Auths.hs)
            App.DB.Helpers
            App.Logging
            App.Routes.Helpers
            App.Routes.Hooks.AreaNodes
            App.Types.Spock
            Data.Types.AreaNode
            Data.Types.CustomFields
            Data.Types.Security.Tokens
        App.Routes.AreaNodes.Updates (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/AreaNodes/Updates.hs)
            App.DB.Helpers
            App.Routes.Helpers
            App.Routes.Hooks.AreaNodes
            App.Types.Spock
            Data.Types.AreaNode
        App.Routes.Helpers (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Helpers.hs)
            App.Types.Spock
        App.Routes.Hooks.AreaNodes (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Hooks/AreaNodes.hs)
            App.DB.Helpers
            App.Errors.AreaNodes
            App.Logging
            App.Routes.Helpers
            App.Types.Spock
            Data.Types.AreaNode
            Data.Types.Security.Tokens
        App.Routes.Hooks.Users (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Hooks/Users.hs)
            App.DB.Helpers
            App.Errors
            App.Errors.Users
            App.Logging
            App.Routes.Helpers
            App.Types.Spock
            Data.Types.Grants
            Data.Types.Permissions
            Data.Types.Security.Tokens
            Data.Types.User
        App.Routes.Users (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Users.hs)
            App.DB.Helpers
            App.Errors.Users
            App.Logging
            App.Routes.Helpers
            App.Routes.Hooks.Users
            App.Routes.Users.Areas
            App.Types.Spock
            Data.Types.Area
            Data.Types.Permissions
            Data.Types.Security.Tokens
            Data.Types.Security.User.Auth
            Data.Types.User
            Lib.Text
        App.Routes.Users.Areas (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Routes/Users/Areas.hs)
            App.DB.Helpers
            App.Errors
            App.Routes.Helpers
            App.Routes.Hooks.Users
            App.Types.Spock
            Data.Types.Area
            Data.Types.AreaNode
            Data.Types.Grants
            Data.Types.Permissions
            Data.Types.Security.User.Auth
            Data.Types.Updates
            Data.Types.User
        App.Types (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Types.hs)
            App.Types.MQ
        App.Types.MQ (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Types/MQ.hs)
        App.Types.Spock (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/App/Types/Spock.hs)
            Data.Types.AreaNode
            Data.Types.Permissions
            Data.Types.Security.Tokens
            Data.Types.User
        Data.Types.Area (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Area.hs)
            Data.Types.CustomFields
            Data.Types.Updates
            Lib.Ids
        Data.Types.AreaNode (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/AreaNode.hs)
            Data.Types.Area
            Data.Types.CustomFields
            Data.Types.Node
            Data.Types.Updates
            Data.Types.User
            Lib.Ids
        Data.Types.CustomFields (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/CustomFields.hs)
            Lib.Text
        Data.Types.Grants (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Grants.hs)
            Lib.Text
        Data.Types.Node (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Node.hs)
            Data.Types.CustomFields
        Data.Types.Permissions (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Permissions.hs)
            Data.Types.Area
            Data.Types.Grants
            Data.Types.User
            Lib.JSON
        Data.Types.Security.Tokens (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Security/Tokens.hs)
            Data.Types.Area
            Data.Types.AreaNode
            Data.Types.User
            Lib.Time
        Data.Types.Security.User.Auth (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Security/User/Auth.hs)
            Data.Types.Security.Tokens
            Data.Types.User
            Lib.JSON
            Lib.Text
        Data.Types.Updates (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/Updates.hs)
        Data.Types.User (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Data/Types/User.hs)
        Lib (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib.hs)
        Lib.Ids (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/Ids.hs)
        Lib.JSON (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/JSON.hs)
        Lib.Text (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/Text.hs)
        Lib.Time (/Users/asheshambasta/code/haskell/spock/Spock-rest/src/Lib/Time.hs)
        Paths_Spock_rest (/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/Paths_Spock_rest.hs)
    exe:Spock-rest-exe
        Main (/Users/asheshambasta/code/haskell/spock/Spock-rest/app/Main.hs)
        Paths_Spock_rest (/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/Paths_Spock_rest.hs)
    test:Spock-rest-test
        Main (/Users/asheshambasta/code/haskell/spock/Spock-rest/test/Spec.hs)
        Paths_Spock_rest (/Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/Paths_Spock_rest.hs)
GHC Cabal options:
    Setup.hs
    library
        -fbuilding-cabal-package -O -outputdir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -odir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -hidir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -stubdir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -i
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -isrc
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -optP-include
        -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h
        -this-unit-id Spock-rest-0.1.0.0-4PSHfUCADkvXIgr45Y8SN
        -hide-all-packages -no-user-package-db -package-db
        /Users/asheshambasta/.stack/snapshots/x86_64-osx/lts-8.13/8.0.2/pkgdb
        -package-db
        /Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/install/x86_64-osx/lts-8.13/8.0.2/pkgdb
        -package-id MonadRandom-0.5.1-IY6HiWu00vQLARukQW3KMH -package-id
        Spock-0.12.0.0-HrjBtiKRVpc5zeFyZXjlPH -package-id
        Spock-core-0.12.0.0-6R7wuW37GruCyDAQ6RxLb9 -package-id
        aeson-0.11.3.0-6KZhhAoYhStJEHF28MdoG1 -package-id
        amqp-0.14.1-FvRQeOtOCHwBY1AZv5k1sd -package-id base-4.9.1.0
        -package-id base64-bytestring-1.0.0.1-4O9TExPPz6eI82Yj7L4SIj
        -package-id bytestring-0.10.8.1 -package-id
        cryptonite-0.21-G3auqyG86Do30r1nrVHiPT -package-id
        esqueleto-2.5.1-Bv42CVdpnj47LROGXP04li -package-id
        http-api-data-0.3.7-Fjq248miKA8D5hFdZGD7aB -package-id
        http-types-0.9.1-AUkzzKpOoLmKIvDSpmjcFz -package-id
        hvect-0.4.0.0-Bz3s0s4mhGy1edxe23N084 -package-id
        memory-0.14.5-3ZpYY8ZZOR4DS7cmS82LIK -package-id
        monad-log-0.1.1.0-EXsOlfBmFYaDoNe3UXOGKx -package-id
        monad-logger-0.3.23-JTS4X30MorOF9sRBPO0yDx -package-id
        mtl-2.2.1-BLKBelFsPB3BoFeSWSOYj6 -package-id
        parallel-3.2.1.1-KQJHWCcq2Ka569Stb10nhx -package-id
        persistent-2.6.1-BzNAnINH0anHwGhCB3Dp3U -package-id
        persistent-mysql-2.6.0.1-H8HST8XZEN9FzUn6odZDw9 -package-id
        persistent-sqlite-2.6.2-9axGkUlysug6nCTbfNSYox -package-id
        persistent-template-2.5.2-DJD2ymvDKVlKrE4ioBwCDx -package-id
        random-1.1-9tceXaeYIMZ4JrKq20Egog -package-id
        safe-0.3.14-GsbXn9D9F3BDazVNcErzdQ -package-id
        stm-2.4.4.1-JQn4hNPyYjP5m9AcbI88Ve -package-id
        text-1.2.2.1-Ji7hMs2U4BkBwavd4taEVR -package-id time-1.6.0.1
        -package-id transformers-0.5.2.0 -package-id
        unordered-containers-0.2.8.0-1XEErQCPPPc2SEtcHHNx9o -package-id
        utf8-string-1.0.1.1-1DpjxLeTvGg7ttZZojxJR5 -package-id
        uuid-1.3.13-CZRAA7iBrqCJQ7lNFsqpMd -package-id
        vector-0.11.0.0-LMwQhhnXj8U3T5Bm1JFxG -package-id
        wai-extra-3.0.19.1-ETFxpI40PwTAQ0NwGpl7g5 -XHaskell2010
    exe:Spock-rest-exe
        -fbuilding-cabal-package -O -outputdir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -odir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -hidir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -stubdir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -i
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-exe/Spock-rest-exe-tmp
        -iapp -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -isrc
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-exe/Spock-rest-exe-tmp
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -optP-include
        -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h
        -this-unit-id Spock-rest-0.1.0.0-4PSHfUCADkvXIgr45Y8SN
        -hide-all-packages -no-user-package-db -package-db
        /Users/asheshambasta/.stack/snapshots/x86_64-osx/lts-8.13/8.0.2/pkgdb
        -package-db
        /Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/install/x86_64-osx/lts-8.13/8.0.2/pkgdb
        -package-id MonadRandom-0.5.1-IY6HiWu00vQLARukQW3KMH -package-id
        Spock-0.12.0.0-HrjBtiKRVpc5zeFyZXjlPH -package-id
        Spock-core-0.12.0.0-6R7wuW37GruCyDAQ6RxLb9 -package-id
        aeson-0.11.3.0-6KZhhAoYhStJEHF28MdoG1 -package-id
        amqp-0.14.1-FvRQeOtOCHwBY1AZv5k1sd -package-id base-4.9.1.0
        -package-id base64-bytestring-1.0.0.1-4O9TExPPz6eI82Yj7L4SIj
        -package-id bytestring-0.10.8.1 -package-id
        cryptonite-0.21-G3auqyG86Do30r1nrVHiPT -package-id
        esqueleto-2.5.1-Bv42CVdpnj47LROGXP04li -package-id
        http-api-data-0.3.7-Fjq248miKA8D5hFdZGD7aB -package-id
        http-types-0.9.1-AUkzzKpOoLmKIvDSpmjcFz -package-id
        hvect-0.4.0.0-Bz3s0s4mhGy1edxe23N084 -package-id
        memory-0.14.5-3ZpYY8ZZOR4DS7cmS82LIK -package-id
        monad-log-0.1.1.0-EXsOlfBmFYaDoNe3UXOGKx -package-id
        monad-logger-0.3.23-JTS4X30MorOF9sRBPO0yDx -package-id
        mtl-2.2.1-BLKBelFsPB3BoFeSWSOYj6 -package-id
        parallel-3.2.1.1-KQJHWCcq2Ka569Stb10nhx -package-id
        persistent-2.6.1-BzNAnINH0anHwGhCB3Dp3U -package-id
        persistent-mysql-2.6.0.1-H8HST8XZEN9FzUn6odZDw9 -package-id
        persistent-sqlite-2.6.2-9axGkUlysug6nCTbfNSYox -package-id
        persistent-template-2.5.2-DJD2ymvDKVlKrE4ioBwCDx -package-id
        random-1.1-9tceXaeYIMZ4JrKq20Egog -package-id
        safe-0.3.14-GsbXn9D9F3BDazVNcErzdQ -package-id
        stm-2.4.4.1-JQn4hNPyYjP5m9AcbI88Ve -package-id
        text-1.2.2.1-Ji7hMs2U4BkBwavd4taEVR -package-id time-1.6.0.1
        -package-id transformers-0.5.2.0 -package-id
        unordered-containers-0.2.8.0-1XEErQCPPPc2SEtcHHNx9o -package-id
        utf8-string-1.0.1.1-1DpjxLeTvGg7ttZZojxJR5 -package-id
        uuid-1.3.13-CZRAA7iBrqCJQ7lNFsqpMd -package-id
        vector-0.11.0.0-LMwQhhnXj8U3T5Bm1JFxG -package-id
        wai-extra-3.0.19.1-ETFxpI40PwTAQ0NwGpl7g5 -XHaskell2010 -threaded
        -rtsopts -with-rtsopts=-N
    test:Spock-rest-test
        -fbuilding-cabal-package -O -outputdir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -odir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -hidir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -stubdir
        .stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -i
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-test/Spock-rest-test-tmp
        -itest -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -isrc
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-test/Spock-rest-test-tmp
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -optP-include
        -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h
        -this-unit-id Spock-rest-0.1.0.0-4PSHfUCADkvXIgr45Y8SN
        -hide-all-packages -no-user-package-db -package-db
        /Users/asheshambasta/.stack/snapshots/x86_64-osx/lts-8.13/8.0.2/pkgdb
        -package-db
        /Users/asheshambasta/code/haskell/spock/Spock-rest/.stack-work/install/x86_64-osx/lts-8.13/8.0.2/pkgdb
        -package-id MonadRandom-0.5.1-IY6HiWu00vQLARukQW3KMH -package-id
        Spock-0.12.0.0-HrjBtiKRVpc5zeFyZXjlPH -package-id
        Spock-core-0.12.0.0-6R7wuW37GruCyDAQ6RxLb9 -package-id
        aeson-0.11.3.0-6KZhhAoYhStJEHF28MdoG1 -package-id
        amqp-0.14.1-FvRQeOtOCHwBY1AZv5k1sd -package-id base-4.9.1.0
        -package-id base64-bytestring-1.0.0.1-4O9TExPPz6eI82Yj7L4SIj
        -package-id bytestring-0.10.8.1 -package-id
        cryptonite-0.21-G3auqyG86Do30r1nrVHiPT -package-id
        esqueleto-2.5.1-Bv42CVdpnj47LROGXP04li -package-id
        http-api-data-0.3.7-Fjq248miKA8D5hFdZGD7aB -package-id
        http-types-0.9.1-AUkzzKpOoLmKIvDSpmjcFz -package-id
        hvect-0.4.0.0-Bz3s0s4mhGy1edxe23N084 -package-id
        memory-0.14.5-3ZpYY8ZZOR4DS7cmS82LIK -package-id
        monad-log-0.1.1.0-EXsOlfBmFYaDoNe3UXOGKx -package-id
        monad-logger-0.3.23-JTS4X30MorOF9sRBPO0yDx -package-id
        mtl-2.2.1-BLKBelFsPB3BoFeSWSOYj6 -package-id
        parallel-3.2.1.1-KQJHWCcq2Ka569Stb10nhx -package-id
        persistent-2.6.1-BzNAnINH0anHwGhCB3Dp3U -package-id
        persistent-mysql-2.6.0.1-H8HST8XZEN9FzUn6odZDw9 -package-id
        persistent-sqlite-2.6.2-9axGkUlysug6nCTbfNSYox -package-id
        persistent-template-2.5.2-DJD2ymvDKVlKrE4ioBwCDx -package-id
        random-1.1-9tceXaeYIMZ4JrKq20Egog -package-id
        safe-0.3.14-GsbXn9D9F3BDazVNcErzdQ -package-id
        stm-2.4.4.1-JQn4hNPyYjP5m9AcbI88Ve -package-id
        text-1.2.2.1-Ji7hMs2U4BkBwavd4taEVR -package-id time-1.6.0.1
        -package-id transformers-0.5.2.0 -package-id
        unordered-containers-0.2.8.0-1XEErQCPPPc2SEtcHHNx9o -package-id
        utf8-string-1.0.1.1-1DpjxLeTvGg7ttZZojxJR5 -package-id
        uuid-1.3.13-CZRAA7iBrqCJQ7lNFsqpMd -package-id
        vector-0.11.0.0-LMwQhhnXj8U3T5Bm1JFxG -package-id
        wai-extra-3.0.19.1-ETFxpI40PwTAQ0NwGpl7g5 -XHaskell2010 -threaded
        -rtsopts -with-rtsopts=-N
GHC search path options:
    Setup.hs
    library
        -i -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -isrc
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build -optP-include
        -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h
    exe:Spock-rest-exe
        -i
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-exe/Spock-rest-exe-tmp
        -iapp -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-exe/Spock-rest-exe-tmp
        -optP-include
        -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h
    test:Spock-rest-test
        -i
        -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-test/Spock-rest-test-tmp
        -itest -i.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen
        -I.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/Spock-rest-test/Spock-rest-test-tmp
        -optP-include
        -optP.stack-work/dist/x86_64-osx/Cabal-1.24.2.0/build/autogen/cabal_macros.h

What can be done to at least temporarily fix this? My editor (emacs) hangs after each word typed because of this (I'm assuming) since I see the error logs being output each time I type.

@DanielG
Copy link
Owner Author

DanielG commented Jun 18, 2018

@asheshambasta sorry I'm only responding now. Like I mentioned above, you can try using the Emacs code in the dev-elisp branch: #672. But that probably comes with downsides and broken things since I've been shuffling the code around a fair bit in that branch. If you need help setting that up just say so.

@alanz
Copy link
Collaborator

alanz commented Jun 20, 2018

See alanz@66fc098

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants