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

Stack new, build & test fails #1399

Closed
sideeffffect opened this issue Nov 22, 2015 · 3 comments
Closed

Stack new, build & test fails #1399

sideeffffect opened this issue Nov 22, 2015 · 3 comments
Assignees
Milestone

Comments

@sideeffffect
Copy link

re-reporting from #958 (comment)

 stack --version
Version 0.1.8.0, Git revision e33dd995e292efcf8ee42e1e4c649b96232abf2e (2603 commits) x86_64

things go OK with the steps you described:

 stack new haskellStackHelloworld
Downloading template "new-template" to create project "haskellStackHelloworld" in haskellStackHelloworld/ ...
The following parameters were needed by the template but not provided: category
You can provide them in /home/ondra/.stack/config.yaml, like this:
templates:
  params:
    category: value
Or you can pass each one as parameters like this:
stack new haskellStackHelloworld new-template -p "category:value"
Writing default config file to: /home/ondra/Projects/haskellStackHelloworld/stack.yaml
Basing on cabal files:
- /home/ondra/Projects/haskellStackHelloworld/haskellStackHelloworld.cabal

Checking against build plan lts-3.14
Selected resolver: lts-3.14
Wrote project config to: /home/ondra/Projects/haskellStackHelloworld/stack.yaml
 cd haskellStackHelloworld/
 stack test
haskellStackHelloworld-0.1.0.0: configure (lib + exe + test)
Configuring haskellStackHelloworld-0.1.0.0...
haskellStackHelloworld-0.1.0.0: build (lib + exe + test)
Preprocessing library haskellStackHelloworld-0.1.0.0...
[1 of 1] Compiling Lib              ( src/Lib.hs, .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/Lib.o )
In-place registering haskellStackHelloworld-0.1.0.0...
Preprocessing executable 'haskellStackHelloworld-exe' for
haskellStackHelloworld-0.1.0.0...
[1 of 1] Compiling Main             ( app/Main.hs, .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/haskellStackHelloworld-exe/haskellStackHelloworld-exe-tmp/Main.o )
Linking .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/haskellStackHelloworld-exe/haskellStackHelloworld-exe ...
Preprocessing test suite 'haskellStackHelloworld-test' for
haskellStackHelloworld-0.1.0.0...
[1 of 1] Compiling Main             ( test/Spec.hs, .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/haskellStackHelloworld-test/haskellStackHelloworld-test-tmp/Main.o )
Linking .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/haskellStackHelloworld-test/haskellStackHelloworld-test ...
haskellStackHelloworld-0.1.0.0: copy/register
Installing library in
/home/ondra/Projects/haskellStackHelloworld/.stack-work/install/x86_64-linux/lts-3.14/7.10.2/lib/x86_64-linux-ghc-7.10.2/haskellStackHelloworld-0.1.0.0-D1dFZvuroeEGs4tiDu5sD5
Installing executable(s) in
/home/ondra/Projects/haskellStackHelloworld/.stack-work/install/x86_64-linux/lts-3.14/7.10.2/bin
Registering haskellStackHelloworld-0.1.0.0...
haskellStackHelloworld-0.1.0.0: test (suite: haskellStackHelloworld-test)
Progress: 1/2Test suite not yet implemented
Completed all 2 actions.

but this fails:

 stack new haskellStackHelloworld
Downloading template "new-template" to create project "haskellStackHelloworld" in haskellStackHelloworld/ ...
The following parameters were needed by the template but not provided: category
You can provide them in /home/ondra/.stack/config.yaml, like this:
templates:
  params:
    category: value
Or you can pass each one as parameters like this:
stack new haskellStackHelloworld new-template -p "category:value"
Writing default config file to: /home/ondra/Projects/haskellStackHelloworld/stack.yaml
Basing on cabal files:
- /home/ondra/Projects/haskellStackHelloworld/haskellStackHelloworld.cabal

Checking against build plan lts-3.14
Selected resolver: lts-3.14
Wrote project config to: /home/ondra/Projects/haskellStackHelloworld/stack.yaml
 cd haskellStackHelloworld/
 stack build
haskellStackHelloworld-0.1.0.0: configure
Configuring haskellStackHelloworld-0.1.0.0...
haskellStackHelloworld-0.1.0.0: build
Preprocessing library haskellStackHelloworld-0.1.0.0...
[1 of 1] Compiling Lib              ( src/Lib.hs, .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/Lib.o )
In-place registering haskellStackHelloworld-0.1.0.0...
Preprocessing executable 'haskellStackHelloworld-exe' for
haskellStackHelloworld-0.1.0.0...
[1 of 1] Compiling Main             ( app/Main.hs, .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/haskellStackHelloworld-exe/haskellStackHelloworld-exe-tmp/Main.o )
Linking .stack-work/dist/x86_64-linux/Cabal-1.22.4.0/build/haskellStackHelloworld-exe/haskellStackHelloworld-exe ...
haskellStackHelloworld-0.1.0.0: copy/register
Installing library in
/home/ondra/Projects/haskellStackHelloworld/.stack-work/install/x86_64-linux/lts-3.14/7.10.2/lib/x86_64-linux-ghc-7.10.2/haskellStackHelloworld-0.1.0.0-D1dFZvuroeEGs4tiDu5sD5
Installing executable(s) in
/home/ondra/Projects/haskellStackHelloworld/.stack-work/install/x86_64-linux/lts-3.14/7.10.2/bin
Registering haskellStackHelloworld-0.1.0.0...
 stack test
Test suite haskellStackHelloworld-test executable not found for haskellStackHelloworld
Test suite failure for package haskellStackHelloworld-0.1.0.0
    haskellStackHelloworld-test:  executable not found
Logs printed to console
@sideeffffect sideeffffect changed the title Stack new, build & test fails Stack new, build & test fails Nov 22, 2015
@borsboom
Copy link
Contributor

I was able to reproduce this locally as well. Thanks for the bug report.

@mgsloan
Copy link
Contributor

mgsloan commented Nov 23, 2015

Thanks for the report! Looking into it

@mgsloan mgsloan self-assigned this Nov 23, 2015
mgsloan added a commit that referenced this issue Nov 24, 2015
+ changes the ensureConfig logic to ignore the list of components, as it
does not affect the config of the package.

+ avoid reconfigures when the new deps are a subset of the old deps
@mgsloan
Copy link
Contributor

mgsloan commented Nov 24, 2015

I've put a fix for this on master. I consider this bug to be pretty substantial, so I'm in favor of doing a bugfix release.

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

No branches or pull requests

3 participants