-
-
Notifications
You must be signed in to change notification settings - Fork 269
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
Precompilation: Prettier printing, opt-out auto #2091
Precompilation: Prettier printing, opt-out auto #2091
Conversation
Coolest shit ever! |
That's really fun. The biggest problem I foresee is that people are then going to ask for What's the difference between the white-bold and the rest? I expected the ones underneath to be dependencies but it seems they are not.
I have seen something like that occasionally and wondered the same thing. It's a bit unexpected because precompilation doesn't load new code in the parent session, right? |
White bold = direct dependencies from the Project.toml |
Perhaps the indent of the gray indirect deps is inaccurately making it look tree-like. I'll remove that.
As far as I know, yeah. Could it just be because I'm dev-ing Pkg, so it's not in the sysimage? |
You can run with |
Using the 128 core machine once more: |
@haampie still a bit of a firehose, but does seem more comprehendible On the lag, I just built this branch into the julia sysimage and it disappeared 👍🏻 |
It's pretty isolated code though so tidiness isn't too important. As long as it works well :P
Perhaps it can throw in the very end if something failed? Just so if someone runs
Maybe check if |
Perhaps instead indent everything? Then it looks more like it is under the |
Yeah, I agree. I did actually end up doing that. It's already committed. |
But if multiple packages fail, and it throws at the end, we'd have to figure out how to show a stack trace for all packages that failed which could be a huge mess, otherwise the CI session wouldn't show the actual error and would be a bit opaque to the user. Instead, this approach reserves throwing proper package load errors to linear load time, which would be a lot more manageable. I can't think of a CI use case that would include This approach to not throw does change the current behavior though, so perhaps that's an unacceptable breaking change for a 1.x release? |
Couldn't we just throw an error in the end showing what packages failed? I don't understand the part about stack traces. |
We could do that, but then it would be opaque on CI why the package failed. The stack trace wouldn't show the root reason why. Happy to go with your judgement though 👍 |
I think this is finally ready to go |
Did you see JuliaLang/julia#37906 by the way? It removes the need to use |
Oh cool. Happy to hold off until that's merged & nightlied |
I merged the |
I've added interrupt handling for Fixes #2090 |
I merged #2102 in here as there were mutually exclusive bugs preventing CI success |
@ianshmean Can you add "closes #2102" somewhere in the first post of this PR? Edit: fix a mistake |
@DilumAluthge I think you meant #2102, which I added up top |
Yep you are correct. |
Looks like Travis is passing now. @KristofferC is this good to merge once AppVeyor passes? |
I'm not sure why AppVeyor is reporting a failure. If I look at the AppVeyor test log:
So it looks like the Pkg tests passed, but then something went wrong while AppVeyor was trying to upload to Codecov. |
@KristofferC or @fredrikekre Can you restart the AppVeyor job? |
An attempt to make the firehose more manageable https://www.dropbox.com/s/r3x7p3dk46n0o5b/Julia%20Precomp%20-%20Prettier%20printing.mov?dl=0
Some things to note:
The code could definitely be tidier. This is more of a UX demo.
No throwing. This doesn't throw errors, not even for direct deps (unlike master), but it shows when errors occur. It's proven really challenging to make the errors and stack traces throw cleanly from within the parallel process, and I thought that perhaps the pkg repl isn't the best place to show the full stack traces anyway. So the failing deps are just highlighted, and the user can go and load the code to see the errors in full.
Erroring packages are suspended during auto-precompilation. (This isn't new to this PR, but the video illustrates this nicely). I threw an error into
ImageCore
. Note how the errors that happen in the firstprecompile
mean that those failing packages are skipped in subsequent auto precomp sessions. Then to force full precompilation,precompile
is called.Need a basic mode for IJulia, CI etc. We'd need to disable this for dumb terminals and just do a linear print like it used to do.
Timing tweaking. The successful packages only stay for a moment after succeeding. Increasing that might make it less busy, but would limit how much could be on screen at one time
Unrelated. Note the long pause at 1:53 immediately after
pkg> add
looks a bit like invalidation-related lag? Anyone else see that?Edit: Given auto is now enabled in this PR, Ctrl-C interrupts are handled, and some other fixes are included
Closes #2093
Closes #2102
Fixes #2090