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

Make clear_cache safe if no completion file is set #386

Merged
merged 1 commit into from
Jul 3, 2024

Conversation

ekohl
Copy link
Member

@ekohl ekohl commented Jul 2, 2024

If it returns nil, expand_path fails. It also replaces a file deletion race condition with an atomic remove.

Observed a failure in #385. I suspect it failed because HOME wasn't set, but didn't dig in further.

If it returns nil, expand_path fails. It also replaces a file deletion
race condition with an atomic remove.
Copy link
Member

@ofedoren ofedoren left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @ekohl, even though completion cache file should have a default value, this makes things safer anyway.

@ofedoren ofedoren merged commit d72facc into theforeman:master Jul 3, 2024
6 checks passed
@ekohl ekohl deleted the make-clean-cache-safe branch July 3, 2024 18:53
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.

2 participants