@@ -751,7 +751,7 @@ data Install
751 | InstallHadSolverTrouble Solver
751 | InstallHadSolverTrouble Solver
752 | InstallUnknownPackageOnline Pkg.Name [Pkg.Name]
752 | InstallUnknownPackageOnline Pkg.Name [Pkg.Name]
753 | InstallUnknownPackageOffline Pkg.Name [Pkg.Name]
753 | InstallUnknownPackageOffline Pkg.Name [Pkg.Name]
754− | InstallHasBadDetails Pkg.Name Encode.Value
754+ | InstallBadDetails Details
757installToReport :: Install -> Help.Report
757installToReport :: Install -> Help.Report
@@ -895,20 +895,8 @@ installToReport exit =
895 , D.reflow $ "Maybe you want one of these instead?"
895 , D.reflow $ "Maybe you want one of these instead?"
898− InstallHasBadDetails pkg outline ->
898+ InstallBadDetails details ->
899− Help.report "INSTALL PROBLEM" Nothing
899+ toDetailsReport details
901− "I found a version of " ++ Pkg.toChars pkg ++ " that claims to be compatible with\
902− \ your existing dependencies, but I ran into an error when I tried to build it locally."
905− "Here is an elm.json that should reproduce the error with a bit more information:"
906− , D.indent 4 $ D.dullyellow $ D.vcat $ map D.fromChars $
907− map BS_UTF8.toString $ BSC.lines $ LBS.toStrict $ B.toLazyByteString $
908− Encode.encode outline
910− "Maybe that can help figure out what is going on here."
@@ -1334,7 +1322,7 @@ toDetailsReport details =
1334 "I need the list of published packages to verify your dependencies"
1322 "I need the list of published packages to verify your dependencies"
1336 DetailsBadDeps cacheDir deps ->
1324 DetailsBadDeps cacheDir deps ->
1337− case deps of
1325+ case List.sortOn toBadDepRank deps of
1339 Help.report "PROBLEM BUILDING DEPENDENCIES" Nothing
1327 Help.report "PROBLEM BUILDING DEPENDENCIES" Nothing
1340 "I am not sure what is going wrong though."
1328 "I am not sure what is going wrong though."
@@ -1374,6 +1362,13 @@ toDetailsReport details =
1365+toBadDepRank :: DetailsBadDep -> Int -- lower is better
1366+toBadDepRank badDep =
1368+ BD_BadDownload _ _ _ -> 0
1369+ BD_BadBuild _ _ _ -> 1
1378-- PACKAGE PROBLEM
1373-- PACKAGE PROBLEM