file briefly existing continues to produce reported problem in vs code #3027
Labels
status: needs triage
type: bug
Something isn't right: doesn't work as intended, documentation is missing/outdated, etc..
Your environment
Which OS do you use: Debian 11
Which LSP client (editor/plugin) do you use: vs-code haskell haskell-syntax highlight
Describe your project (alternative: link to the project): minimal cabal project with hpack one main, one library with 2 modules
Steps to reproduce
project compiles cleanly (cabal build) no error reported
copy one of the modules in the library to new.hs in the library and edit it to cause an error
hpack; cabal build -> error is reported. problems show it.
rename the file to new2.hs and fix the error
hpack; cabal build -> no error is reported but the 'problem' shows 1 error in file New1.hs
clicking on the error in the 'problem' - file New1.hs cannot be opened because it does not exist.
the count of problems remain 1
note: the fiel new1.hs or ew2.hs are not mentioned in the cabal file (because lower case and thus not seen by hpack)
Expected behaviour
after renaming New1.hs to New2.hs and fixing the error, the count of problems should go back to 0
Actual behaviour
problem count remains 1
I have the impression that a hie file was produced automatically and is cached and not replace somewhere (I have observed other strange behaviour, e.g. files in a non-source directory ('do not use' dir) are included in the error count and errors reported) in reporting problems with cradle or inexisting files which disappear sometimes later as by magic. is there a reliable method to force a reconstruction of the hie file?
the issue is a minor annoyance but it is nice when just checking the problem count confirms that no errors are in the code.
Include debug information
The text was updated successfully, but these errors were encountered: