feat: delete build caches after removing dependencies#5399
Conversation
|
Isn't running |
|
Yeah, I was thinking about that, drafted PR for now. Initially I wanted to implemebt it like in the LS, where we clean build directory for LSP mode, current target and current package. It's the information that we don't have in cleanup code. I will try to implement it anyway. |
596f744 to
a28cc66
Compare
|
@yoshi-monster Now it removes build directory only for the toplevel package, current target, and both dev and prod modes. What do you think? |
1209a34 to
48d3166
Compare
|
Hello!! Sorry, it looks like my github is still broken and won't send me emails. Yeah, looks good to me! I don't know enough of the compiler if we could delete the cached type information but keep the generated code, but I don't think it matters that much. Thank you! 💜 |
lpil
left a comment
There was a problem hiding this comment.
Hello! Shouldn't we be removing the metadata for the removed package, not the root package?
|
Makes sense to me, will do it tomorrow! |
48d3166 to
a11c5a3
Compare
a11c5a3 to
121386a
Compare
|
@lpil I tested and found that removing cache for root package is needed here. For instance, it already removes cache for dependencies here: From my tests issue is resolved only with cleaning cache of root package. |
b325e95 to
1243c8f
Compare
lpil
left a comment
There was a problem hiding this comment.
Lovely! Thank you for the investigation and the explanation. I understand why it wasn't working before now.
I've left a few tiny notes inline
5764e25 to
7a94b8e
Compare
7a94b8e to
50b4ce7
Compare
50b4ce7 to
072ea0e
Compare
gleam removecould invalidate the build cache #5363gleam remove