- Compile and load these 2 modules into the ide server:
module A where
fn :: Int -> String
fn x = show x
module B where
import A (fn)
bFn :: String
bFn = fn 1
- Change module
A.fn to
fn :: String -> String
fn s = s <> "hi!"
-
Recompile A without letting the server know (start it with the --editor-mode flag and recompile module A from the cmdline with purs compile src/A.purs)
-
Make a change to module B and fast-rebuild through ide, it does not show any errors, and it continues to generate code for B that assumes the old signature of A.fn is still valid, but instead the code fails at runtime.
This is a known issue, and I do not have a satisfying solution for the problem at hand. It basically boils down to cache invalidation between the FS and the ide servers internal state. Empirically file watching misses changes, and doesn't interact well with adding and removing files and avoiding it by polling creates too much overhead.
A.fntoRecompile A without letting the server know (start it with the
--editor-modeflag and recompile module A from the cmdline withpurs compile src/A.purs)Make a change to module
Band fast-rebuild through ide, it does not show any errors, and it continues to generate code forBthat assumes the old signature ofA.fnis still valid, but instead the code fails at runtime.This is a known issue, and I do not have a satisfying solution for the problem at hand. It basically boils down to cache invalidation between the FS and the ide servers internal state. Empirically file watching misses changes, and doesn't interact well with adding and removing files and avoiding it by polling creates too much overhead.