Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Errors in windows with hie-bios check file #33

Closed
jneira opened this issue Sep 9, 2019 · 1 comment
Closed

Errors in windows with hie-bios check file #33

jneira opened this issue Sep 9, 2019 · 1 comment

Comments

@jneira
Copy link
Member

jneira commented Sep 9, 2019

Hi, i am trying the package in isolation in windows and i am not able to get a correct result in some cases:

  • I am running hie-bios check${file} where ${file} is an existing file within the directory using a dos console
  • In the hie-bios project:
D:\ws\haskell\hie-bios>hie-bios check src\HIE\Bios\Check.hs
cradble
  Cradle {cradleRootDir = "D:\\ws\\haskell\\hie-bios", cradleOptsProg = CradleAc
tion: cabal}
@ECHO OFF
IF "%i" == "--interactive" (
  ECHO %CD%
  ECHO %*
) ELSE (
  ghc %*
)

(ExitSuccess,"","")
CallStack (from HasCallStack):
  error, called at src\HIE\Bios\Cradle.hs:154:18 in hie-bios-0.1.0-a8e013fc044c2bff792c3b29dcd1fb02cfedc8f6:HIE.Bios.Cradle
D:\ws\haskell\stack-test>hie-bios check src\Lib.hs
cradble
  Cradle {cradleRootDir = "D:\\ws\\haskell\\stack-test", cradleOptsProg = Cradle
Action: stack}
#!/usr/bin/env bash
if [ "$1" == "--interactive" ]; then
  pwd
  echo "$@"
else
  ghc "$@"
fi

(ExitFailure 1,"\"stty\" no se reconoce como un comando interno o externo,\nprog
rama o archivo por lotes ejecutable.\n","")
CallStack (from HasCallStack):
  error, called at src\HIE\Bios\Cradle.hs:203:18 in hie-bios-0.1.0-a8e013fc044c2bff792c3b29dcd1fb02cfedc8f6:HIE.Bios.Cradle
  • In a simple cabal based project it seems to work:
D:\ws\haskell\cabal-test>hie-bios check lib\CabalTestLib.hs
cradble
  Cradle {cradleRootDir = "D:\\ws\\haskell\\cabal-test", cradleOptsProg = Cradle
Action: default}
res (ExitSuccess,"",[],"lib\\CabalTestLib.hs")
[]
0
([],0)
([],0)
setTargets
  (lib\CabalTestLib.hs , lib\CabalTestLib.hs)
  [*lib\CabalTestLib.hs]
([],0)
modGraph
  [ModSummary {
      ms_hs_date = date
      ms_mod = CabalTestLib,
      ms_textual_imps = [(Nothing, Prelude), (Nothing, Data.ByteString),
                         (Nothing, Network.HTTP.Types.URI)]
      ms_srcimps = []
   }]
modGraph
  [ModLocation {ml_hs_file = Just "lib\\CabalTestLib.hs", ml_hi_file = "C:\\Users\\user\\AppData\\Local\\haskell-ide-engine\\da39a3ee5e6b4b0d3255bfef95601890afd8
0709\\CabalTestLib.hi", ml_obj_file = "lib\\CabalTestLib.o"}]
hidir
  Just [C, :, \, U, s, e, r, s, \, u, s, e, r, \, A, p, p, D, a, t, a,
        \, L, o, c, a, l, \, h, a, s, k, e, l, l, -, i, d, e, -, e, n, g,
        i, n, e, \, d, a, 3, 9, a, 3, e, e, 5, e, 6, b, 4, b, 0, d, 3, 2,
        5, 5, b, f, e, f, 9, 5, 6, 0, 1, 8, 9, 0, a, f, d, 8, 0, 7, 0, 9]
lib\CabalTestLib.hs:7:1:Warning: Top-level binding with no type signature: f ::
Num p => [a] -> p
lib\CabalTestLib.hs:7:1:Warning: Pattern match(es) are non-exhaustive In an equa
tion for ‘f’: Patterns not matched: []
[]
lib\CabalTestLib.hs:7:4:Warning: Defined but not used: ‘x’
��
lib\CabalTestLib.hs:7:6:Warning: Defined but not used: ‘xs’
��
@jneira
Copy link
Member Author

jneira commented Sep 19, 2019

After #50 (and maybe some other changes in between), hie-bios check src\HIE\Bios\Cradle.hs works using stack and throws another error using cabal, so closing this.

@jneira jneira closed this as completed Sep 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant