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

Data.Binary.Get.runGet at position 57: demandInput: not enough bytes #33

Closed
rvion opened this issue Jul 20, 2015 · 4 comments
Closed

Data.Binary.Get.runGet at position 57: demandInput: not enough bytes #33

rvion opened this issue Jul 20, 2015 · 4 comments

Comments

@rvion
Copy link

rvion commented Jul 20, 2015

While trying to understand, #31 (comment), I tried to stack build before stack ideand got this error message:

stack-ide: Data.Binary.Get.runGet at position 57: demandInput: not enough bytes
➜  test22 stack build
test22-0.1.0.0: configure
Configuring test22-0.1.0.0...
test22-0.1.0.0: build
Building test22-0.1.0.0...
Preprocessing library test22-0.1.0.0...
[1 of 2] Compiling Test             ( src/Test.hs, .stack-work/dist/x86_64-osx/Cabal-1.18.1.5/build/Test.o )
[2 of 2] Compiling Lib              ( src/Lib.hs, .stack-work/dist/x86_64-osx/Cabal-1.18.1.5/build/Lib.o )
In-place registering test22-0.1.0.0...
Preprocessing executable 'test22-exe' for test22-0.1.0.0...
[1 of 1] Compiling Main             ( app/Main.hs, .stack-work/dist/x86_64-osx/Cabal-1.18.1.5/build/test22-exe/test22-exe-tmp/Main.o )
Linking .stack-work/dist/x86_64-osx/Cabal-1.18.1.5/build/test22-exe/test22-exe ...
test22-0.1.0.0: install
Installing library in
/Users/RemiVion/dev/test22/.stack-work/install/x86_64-osx/lts-2.18/7.8.4/lib/x86_64-osx-ghc-7.8.4/test22-0.1.0.0
Installing executable(s) in
/Users/RemiVion/dev/test22/.stack-work/install/x86_64-osx/lts-2.18/7.8.4/bin
Registering test22-0.1.0.0...
➜  test22  stack ide
{"tag":"ResponseWelcome","contents":[0,1,0]}
stack-ide: Data.Binary.Get.runGet at position 57: demandInput: not enough bytes
@rvion
Copy link
Author

rvion commented Jul 20, 2015

on some other project:

➜  linklater git:(master) ✗ stack build
....
➜  linklater git:(master) ✗ stack ide
{"tag":"ResponseWelcome","contents":[0,1,0]}
{"tag":"ResponseUpdateSession","contents":{"progressOrigMsg":null,"progressStep":1,"progressNumSteps":2,"progressParsedMsg":"C\u0000o\u0000m\u0000p\u0000i\u0000l\u0000i\u0000n\u0000g\u0000 \u0000P\u0000a\u0000t"}}
{"tag":"ResponseUpdateSession","contents":{"progressOrigMsg":null,"progressStep":2,"progressNumSteps":2,"progressParsedMsg":"C\u0000o\u0000m\u0000p\u0000i\u0000l\u0000i\u0000n\u0000g\u0000 \u0000N\u0000e\u0000t\u0000w"}}
stack-ide: Data.Binary.Get.runGet at position 50: demandInput: not enough bytes

@lukexi
Copy link
Contributor

lukexi commented Jul 20, 2015

Hi Rémi,
Oh yeah, I ran into that too! It happens when your ide-backend-server doesn't match the version that stack-ide was built against. Make sure that your stack binary directory (I think usually ~/.local/bin) is taking precedence over your cabal directory in your PATH, or just delete the old ide-backend* executables out of ~/.cabal/bin and you should be in business

@rvion
Copy link
Author

rvion commented Jul 20, 2015

My path was correctly setup, but indeed, I was using different snapshots (nightly for ide, lts2 for project)
Thanks ! :)

@mgsloan
Copy link
Contributor

mgsloan commented Jul 20, 2015

Cool, sounds like this is resolved? Feel free to reopen if it isn't.

I've created an ide-backend issue to improve the messages for this circumstance: fpco/ide-backend#292

@mgsloan mgsloan closed this as completed Jul 20, 2015
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

3 participants