Skip to content

Show errors when a dependency fails to build with new-build #4904

@oliver-batchelor

Description

@oliver-batchelor

Currently if a dependency fails to build you get no indication of what went wrong, it just stops and I'm left wondering why my project didn't try to build. The option to use -v and find the build log is there of course, but it's not obvious which dependency failed and it's not obvious that is the problem to begin with. I've run into this several times, so I'm guessing it's confused others, too.

cabal new-build
In order, the following will be built (use -v for more details):
elm-bridge-0.4.0
elm-annotate-0.1.0.0
Configuring elm-bridge-0.4.0...
Building elm-bridge-0.4.0...

If I run with verbose I see (still no sign of failure):

Building elm-bridge-0.4.0...
/opt/cabal/1.24/bin/cabal act-as-setup --build-type=Simple -- build
--verbose=2 --builddir=dist
Redirecting build log to {handle:
/home/oliver/.cabal/logs/elm-bridge-0.4.0.log}

Then finally I look into the build log for elm-bridge and I see:


> 
> src/Elm/Derive.hs:43:18: error:
>     Not in scope: data constructor ‘A.Options’
>     Module ‘Data.Aeson.TH’ does not export ‘Options’.
> 

Metadata

Metadata

Assignees

No one assigned

    Labels

    cabal-install: v2-build systemAffecting v2-build and related commands that use v2-architecture (aka "nix local builds").type: bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions