Description
@vtjnash and I recently debugged an issue on Windows that boiled down to two things:
Tar.jl
was failing to extract a file because it exceeded the maximum path length on Windows.- This caused
7zip
(whose output we were piping toTar
) to exit uncleanly, and because we didn't wait for it to fully finish, we ended up throwing an exception upon trying tounlink()
the tarball after a failed extraction.
I'm quite enthused by the recent improvements to error logging, but in this case, we got a bit of a false flag; the fundamental issue was a SystemError
being thrown by Tar
, but since that error then caused a second error within a finally
block, when we print out the error for the user, we only print a summary of the most recent error. I think this is the right thing to do normally, (since I don't want to see a full stack trace in general) but I think it would be really nice if we could somehow persist the full exception object for later inspection.
Most exceptions in the Julia world are treated as something that should either break execution, or be handled and completely ignored. We don't really have that many exceptions that could live in the grey area of "something went wrong, but I will try to continue". In this case, I feel some way of inspecting what went wrong is important. Perhaps a Vector{Exception}
that gets cleared out every time you invoke a new Pkg operation, but which can be inspected to see what happened within the last time you invoked a Pkg operation. Doing so would feel very ad-hoc, but I'm not sure what the fully general case for this is.