Skip to content
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

use tempfile+rename for output #186

Merged
merged 3 commits into from Feb 5, 2021
Merged

use tempfile+rename for output #186

merged 3 commits into from Feb 5, 2021

Conversation

sbailey
Copy link
Collaborator

@sbailey sbailey commented Feb 5, 2021

Rongpu found the hard way that redrock wasn't using temporary intermediate files for its output, leading to partially written files with the "final" name in the case of a job timeout. This PR updates redrock to follow the pattern used in desispec: write a temp file and then rename it only after successfully writing the final file.

@sbailey
Copy link
Collaborator Author

sbailey commented Feb 5, 2021

oh yeah, Travis delays. tests pass locally; I'm going to merge without waiting for Travis (which also reminds me to do the switch for travis -> github actions...)

@sbailey sbailey merged commit 15e9132 into master Feb 5, 2021
@sbailey sbailey deleted the tempfile branch February 5, 2021 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant