Stream: beginners

Topic: clear roc cache?


view this post on Zulip lue (Dec 15 2024 at 11:34):

I assume roc has a cache for modules. Is there a way to clean it for better reproducibility? A few times I've gotten a compiler runtime error that doesn't go away on reruns but moving its declarations into a different file compiles fine.

view this post on Zulip Richard Feldman (Dec 15 2024 at 14:21):

there actually is not a cache for modules at the moment, just for downloaded packages

view this post on Zulip Richard Feldman (Dec 15 2024 at 14:21):

all builds are from scratch

view this post on Zulip Richard Feldman (Dec 15 2024 at 14:21):

so it sounds like a bug with modules in general

view this post on Zulip Richard Feldman (Dec 15 2024 at 14:22):

do you have a branch that reproduces it somewhere?

view this post on Zulip lue (Dec 16 2024 at 16:41):

Haha, I guess I'm checking roc files incorrectly?

# A.roc
module [a]
a = 3

roc check A.roc prints out

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:3310:29

Again, works fine if I put the declaration into an app file where I was now able to find a possible root cause of the original compiler runtime error https://github.com/roc-lang/roc/issues/7381

Does this mean plain modules cannot be checked or do you think this is a (platform-specific) issue?

view this post on Zulip Brendan Hansknecht (Dec 16 2024 at 17:31):

Just a plain old bug I think

view this post on Zulip Brendan Hansknecht (Dec 16 2024 at 17:31):

Should work....used to work

view this post on Zulip Brendan Hansknecht (Dec 16 2024 at 17:31):

I think broke with module params


Last updated: Jul 06 2025 at 12:14 UTC