Skip to content

Stack ghci should load intermediate dependencies #584

@hesselink

Description

@hesselink

I often have scenarios where I'm changing two packages (A and C) and I'd like to load them into ghci together. However, there is a third package (B) in between, so that B depends on C, and A depends on B and C. Now, when I do stack ghci A C I will get weird errors:

    Couldn't match type ‘T’
                  with ‘T’
    NB: ‘T’
          is defined in ‘Types.T’
              in package ‘C-0.14.3’
        ‘T’ is defined at
          /my/sources/C/src/Types/T.hs:(36,1)-(49,28)

This is because package B is loaded from the installed library, depending on the installed C, whereas A is using C interpreted. So we have two definitions of type T which are not compatible.

My ideal solution would be if stack ghci A C would also interpret (and not use as a package) all the intermediate dependencies between A and C that are available in the project.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions