Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Error reporting is worse/missing under ghc 9.12.2 (compared to 9.10.3)

Aperta
#855 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
Mezza giornata
Idoneità per principianti
25/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
haskell
Ambito
build-system

Direzione di ricerca

The error is raised at src/Development/Shake/Internal/Rules/File.hs:179, and the issue links commit fc82eee7982cc54db8907892cd688bcd73d11d1e, which may already address this. Start by checking whether that commit is in the current master, then run the Example.hs script under GHC 9.12.2 to see whether the 'rule finished running but did not produce file' message appears. Done means the missing-output error is reported with its message and call site under 9.12.2, as it is under 9.10.3.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Hi - thanks for your work on shake. I noticed that the error reporting degraded somewhat under ghc 9.12.2:

In a Example.hs like:

#!/usr/bin/env cabal
{- cabal:
build-depends:
    base
  , shake
-}

import Development.Shake

main :: IO ()
main = shakeArgs shakeOptions $ do
  want ["foo.txt"]

  "*.txt" %> \out -> do
    pure ()

Running this with ghc 9.10.3:

~
❮ ghcup set ghc 9.10.3
[ Info  ] GHC 9.10.3 successfully set as default version

Gives a helpful error message:

~
↪  ./Example.hs
Error when running Shake build system:
  at want, called at /path/to/Example.hs:14:3 in fake-package-0-inplace-script-Example.hs:Main
* Depends on: foo.txt
  at error, called at src/Development/Shake/Internal/Rules/File.hs:179:58 in shake-0.19.8-488b5a5cc87df829ac1c6a3ebfeceebc03fee9a278623f5d982bfc78c9b4a532:Development.Shake.Internal.Rules.File
* Raised the exception:
Error, rule finished running but did not produce file:
  foo.txt

But with ghc 9.12.2:

ghcup set ghc 9.12.2

It returns:

cabal-script-Example.hs: Uncaught exception ghc-internal:GHC.Internal.Exception.ErrorCall:

ErrorCallWithLocation has been deprecated in favour of ErrorCall (which does not have a location). Backtraces are now handled by the backtrace exception mechanisms exclusively.

HasCallStack backtrace:
  error, called at libraries/ghc-internal/src/GHC/Internal/Exception.hs:184:68 in ghc-internal:GHC.Internal.Exception

Update: Looks like there were already some commits related to this (https://github.com/ndmitchell/shake/commit/fc82eee7982cc54db8907892cd688bcd73d11d1e). Is only a release missing?

Lingua principale
Haskell
Stelle
802
Fork
128
Merge medio
3g 5h
PR unite (30g)
2

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di ndmitchell/shake

Tutte le issue di ndmitchell/shake

Issue simili

Altre issue su Haskell

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.