Skip to content

cannot satisfy -package-id XXX with library + executable in one cabal file #77

Description

@pacak

When project is represented as a library + one or more executables depending on that library in a cabal file (stack seems to have this as default) and there's a problem in the library part of the code hdevtools will die with a rather confusing error:

cannot satisfy -package-id foo-0.0.0.0-xxxxxxxxxxxxxx
    (use -v for more information)

when invoked manually or when invoked via a plugin like ale or syntastic for vim won't show anything at all. It will behave the same way when invoked for executable parts of the project (this makes sense - executable needs library to work/typecheck) or on the library itself - which means typechecker won't work if library fails to compile.

A workaround is to remove executable parts from cabal file. A proper fix - try to distinguish between library and executables?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions