-
Notifications
You must be signed in to change notification settings - Fork 369
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
Ensure DownloadPath is always clean #464
Conversation
Welcome @aimbot31! |
Codecov Report
@@ Coverage Diff @@
## master #464 +/- ##
==========================================
- Coverage 56.52% 56.47% -0.05%
==========================================
Files 19 19
Lines 927 926 -1
==========================================
- Hits 524 523 -1
Misses 350 350
Partials 53 53
Continue to review full report at Codecov.
|
/assign @ahmetb |
/cc @ferhatelmas |
Done, do you see something else @ahmetb ? |
Removed DownloadPath function. Used ioutil.TempDir each time a tmpDir was needed. Removed old tests on DownloadPath.
Good with me, I'm looking for additional reviews from co-maintainers. |
/lgtm |
Hello, any news ? 😄 |
klog.V(3).Infof("Creating download staging directory %q", op.downloadStagingDir) | ||
if err := os.MkdirAll(op.downloadStagingDir, 0755); err != nil { | ||
return errors.Wrapf(err, "could not create staging dir %q", op.downloadStagingDir) | ||
klog.V(3).Infof("Creating download staging directory") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we also need to delete this dir after we are done right?
Maybe defer some cleanup?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ahmetb there's already a defer to clean the dir at the line 100.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sorry for missing :D
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: ahmetb, aimbot31 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Removed DownloadPath function.
Used ioutil.TempDir each time a tmpDir was needed.
Removed old tests on DownloadPath.
Fixes #448.