Stream: beginners

Topic: Outstanding references to the derived module


view this post on Zulip Jared Cone (Oct 22 2024 at 05:15):

Got an issue where running roc check on a file is resulting in:

roc check EmptyModule.roc
An internal compiler expectation was broken.
This is definitely a compiler bug.
Please file an issue here: <https://github.com/roc-lang/roc/issues/new/choose>
Outstanding references to the derived module
Location: crates/compiler/load_internal/src/file.rs:3299:29

This is happening for various roc files I have in a directory, including a test roc file that just has module [] in it.

If I move the file to a different directory (no other roc files in it), roc check succeeds.

view this post on Zulip Jared Cone (Oct 22 2024 at 05:22):

I can work around it right now. I have a main.roc that roc check succeeds for. If I have it import the module that is crashing, roc check knows to run on that file too, and roc check succeeds. So I'm hitting this when running roc check on specific files, and it happens even if the file is empty or only has module [] in it, so it isn't an issue with the contents of the file.

view this post on Zulip Anton (Oct 22 2024 at 09:04):

This looks like #7175


Last updated: Jul 06 2025 at 12:14 UTC