Skip to content

If ghc --version fails for an installed GHC, recover more intelligently #2430

Closed
@Blaisorblade

Description

@Blaisorblade

In #2415 (comment) @jhance reported that stack has

no way to recover from the --version failing and treating that as "ghc is not installed"'

while this is probably a seldom occurrence, it could certainly happen in strange scenarios. I'm not sure we should detect all of them (what if ghc --version works but half of the libraries were deleted?) but at the very least a setup option for "setup GHC again" sounds useful. Also, if ghc --version fails, error messages could mention this option, or even do it automatically.

Could we at least accept a PR for this?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions