-
-
Notifications
You must be signed in to change notification settings - Fork 15
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
Exceptions in workload shouldn't prevent compilation #42
Comments
xref #21. There hasn't been a chorus of such requests, so I have to ask: how often does this happen? Can you just put I recognize that not being able to use a package due to a failing precompile workload sucks. But changing this to a warning opens us up to real problems:
Presto, now everyone using the package isn't getting effective precompilation. In contrast, if it's an error, CI fails and the release never gets made until the buggy workload is fixed. |
I only searched over open issues, and was surprised to see this wasn't reported before :) Now I see that it was indeed.
IMO, even two issues for such a package (not user-facing, nontrivial to understand PrecompileTools is the issue) are an indication that people do encounter this.
Of course, not too often in general. But I've definitely seen this a couple of times when either trying some pre-release Julia version, or upgrading packages individually (to preserve current versions as much as possible). It's very frustrating to deal with such an issue, where one cannot even install a package. When encountering this, I just gave up and didn't upgrade julia/packages. Re potential issues for development workflow: an obvious solution is to keep it an error in CI and/or in |
I completely agree. The question is whether fixing it could make things worse in other ways.
Error only on CI has a fatal flaw: that's only assessed by What we'd need is some variable whose setting gets incorporated into the precompile "stale cache file" check. That means one of these: https://github.com/JuliaLang/julia/blob/a06a80162bb9bdf6f7e91dc18e7ccf5c12673ca4/src/staticdata_utils.c#L610-L614. At least on my machine, the only one changed by I really only see two options:
I lean towards the
No, developers really do need to turn off local precompilation in many cases. I had half a dozen people ask for that within a week of merging pkgimages (and I'm sure all of them knew about Revise), whereas this issue took more than a year to reach two requests. |
Thanks, I understand it's nontrivial to fix while keeping other parts of user experience. Assuming PrecompileTools gets more and more traction, soon we'll start seeing unmaintained packages that use it. And they will naturally start losing compatibility with more recent Julia/packages versions (even those matching semver constraints). Without precompilation workloads, I typically can still install and load those packages, and then either rely on still-working functionality or monkey-patch some method in the tree. |
Currently, whenever the compile_workload throws an exception, the package becomes effectively uninstallable.
That's especially bad for packages with comprehensive precompilation workloads: they become impossible to install and use in any capacity even when a tiny part of their functionality is broken by Julia / dependencies update.
Compile workload errors should just be turned into a small warning, like "precompilation workload failed, not all functionality may be available".
The text was updated successfully, but these errors were encountered: