-
-
Couldn't load subscription status.
- Fork 420
[WIP] Map known root paths in cache files #6021
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
I don't know when and why we changed the output of |
|
I currently hold the current |
|
Incremental tests fail, but I have no clue why. The incrementation zinc-compilation is working properly, but in case of a second compile run Mill should not run the compile task at all, due to caching. This is what's broken now, probably due to some hash changes, which I need to figure out. Most likely we somewhere mix hashes of the mapped and unmapped json data. |
|
Found the issue. Fixed it by implementing |
|
The RCP-server currently fails, due to the mapping not being optional. I started to prepare a fix introducing new types |
|
Closing in favor of #6031 |
Another attempt to make Mill cache storage relocate-able.
The idea is to replace absolute paths with paths relative to pre-defined known root paths.
The current roots are:
$WORKSPACE- the project directory (where the top-levelbuild.millcan be found.$MILL_OUT- the Mill output directory used for caches and build-results$HOME- the user home directoryMore paths come to mind:
$CACHE_COURSIER- the coursier cache directory$CACHE_IVY- the ivy cache directory$CACHE_MAVEN- the Maven cache directoryThose are currently not directly accessible in the code base. Also, their typical storage locations are already relative to
$HOME(e.g.$CACHE_COURSIERvs$HOME/.cache/coursier), hence I left them out for now.One design choice I made for now, is to go with a fixed set of known roots. This means, all of those must be configured before
PathRefs can be used and de-/serialized. The alternative would be to dynamically register roots, allowingPathRefto be used without this restriction.Some refactoring was necessary to streamline the configuration flow of the
$MILL_OUTpath. Before, theoutpath was constructed in many different locations, sometimes with slightly different logic. This is of course a minefield, since we have many entry points (Mill CLI, Mill Daemon, Mill BSP, Test Suites, Integration tests, ...) where those where set up. So this PR relies heavily on our good programmatic test coverage.Attempt to fix #3660
Superseded by #6031, which maps the dynamically, which seems to be the better approach.