You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the cabal file for an extra-dep can't be found, stack suggests the problem is with the packages field, not extra-deps.
Steps to reproduce
For example:
Add a reference to a repo without a cabal file to your extra-deps (see YAML)
Run command stack build.
# A fork of amazonka, which is a mega-repo, so the root directory doesn't have a cabal fileextra-deps:
- git: https://github.com/tvision-insights/amazonka.gitcommit: 9d914189042d6d31ffee912436ddfacde08f1b50
Expected
The user is told which dependency the cabal file couldn't be found for, or at least that an extra-dep was the problem, or that it could be an extra-dep that is the problem.
Actual
Stack implies that my packages field is the problem with this message:
Stack looks for packages in the directories configured in the 'packages' variable defined in your stack.yaml
Official binary, downloaded from stackage.org or fpcomplete's package repository, upgraded via stack upgrade
Potential fixes:
Quick fix: Modify the message to mention extra-deps
Potentially better: pass the package being searched for down so that the error message can be more detailed. I think usually this will be unnecessary, because the path itself is probably much more helpful for non-git repo downloads.
The text was updated successfully, but these errors were encountered:
…roblem too.
* Also: slight refactor to use only `concat` instead of ++ in the error message
* Also: mention that a package.yaml file would also be accepted
* The code that throws this is only searching for a .cabal file, but it runs hpack on the directory immediately before that to generate a cabal file, so it's effectively looking for a package.yaml file as well
Closescommercialhaskell#3806
…roblem too.
* Also: slight refactor to use only `concat` instead of ++ in the error message
* Also: mention that a package.yaml file would also be accepted
* The code that throws this is only searching for a .cabal file, but it runs hpack on the directory immediately before that to generate a cabal file, so it's effectively looking for a package.yaml file as well
Closescommercialhaskell#3806
…roblem too.
* Also: slight refactor to use only `concat` instead of ++ in the error message
* Also: mention that a package.yaml file would also be accepted
* The code that throws this is only searching for a .cabal file, but it runs hpack on the directory immediately before that to generate a cabal file, so it's effectively looking for a package.yaml file as well
Closescommercialhaskell#3806
General summary/comments (optional)
When the cabal file for an extra-dep can't be found, stack suggests the problem is with the
packages
field, notextra-deps
.Steps to reproduce
For example:
stack build
.Expected
The user is told which dependency the cabal file couldn't be found for, or at least that an extra-dep was the problem, or that it could be an extra-dep that is the problem.
Actual
Stack implies that my
packages
field is the problem with this message:(See #2729)
Stack version
Method of installation
stack upgrade
Potential fixes:
The text was updated successfully, but these errors were encountered: