copy log file to the temp dir before removing project directory#182
Merged
copy log file to the temp dir before removing project directory#182
Conversation
wonder-sk
reviewed
Oct 11, 2023
Contributor
wonder-sk
left a comment
There was a problem hiding this comment.
Could you please also add a test to verify this is working? I'm thinking of e.g. 1. start async download, 2. cause failure - create a directory inside the project's dir that has the same name as a file of the project, so that copying that file will fail, 3. check that we have non-empty log file referenced by the job...
wonder-sk
reviewed
Oct 12, 2023
d40a14b to
9086131
Compare
Contributor
Author
|
Included changes from #184 |
wonder-sk
reviewed
Oct 27, 2023
check that traceback present in the log in test
caf59ba to
f665cd7
Compare
wonder-sk
approved these changes
Oct 30, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When project download fails for some reason we remove project directory and raise an exception. This exception than catched in the plugin and error message is shown. However, in some cases (namely, when unexpected error occurs) this message is very basic and it is hard to say what is going on.
The support team proposed that we keep log file as it might contain useful information and provide an option in the plugin to send that log to developers. To make this possible in the client we create a copy of the log file in the system temporary directory before cleaning up failed download. The path to the log file is added to the exception as an attribute and can pluign can check for it and act accordingly.
Fixes #155
Fixes #156