Skip to content

fix: use missing_ok=True in integration JSON removal (import of github/spec-kit#3846) - #134

Open
one-kash wants to merge 1 commit into
mainfrom
import/pr-3846
Open

fix: use missing_ok=True in integration JSON removal (import of github/spec-kit#3846)#134
one-kash wants to merge 1 commit into
mainfrom
import/pr-3846

Conversation

@one-kash

Copy link
Copy Markdown

Imported from upstream PR github#3846
Original author: @Quratulain-bilal
Original head branch: fix/integrations-json-toctou


Summary

Replace check-then-act pattern with unlink(missing_ok=True) to eliminate TOCTOU race.

Changes

  • integrations/_helpers.py: Use missing_ok=True in _remove_integration_json()

Replace check-then-act pattern (exists()+unlink()) with unlink(missing_ok=True)
to eliminate TOCTOU race condition.
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