mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 23:05:53 +01:00
[PR #792] rpf_probe: restore write mode before unlink on replace failure and publish mode on Windows (RPF-PROBE-STAGE-CLEANUP) #832
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#832
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/792
Author: @trigger337
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:fix/rpf-probe-stage-cleanup📝 Commits (1)
ee50881rpf_probe: restore write mode before unlink on replace failure and publish mode on Windows (RPF-PROBE-STAGE-CLEANUP)📊 Changes
2 files changed (+40 additions, -2 deletions)
View changed files
📝
tests/test_rpf_probe.py(+35 -0)📝
tools/rpf_probe.py(+5 -2)📄 Description
In
tools/rpf_probe.py,_write_json_reportcreates a temporary file and previously skipped applyingpublished_modeon Windows becauseos.unlinkin thefinallyblock fails withPermissionError(WinError 5) ifreplace_retryfails on read-only destinations.Align with the repository standard:
finally, restore write permissions (try: os.chmod(staged.name, 0o600); except OSError: pass) before unlinking.published_mode(destination)unconditionally so Windows outputs receive proper permissions instead of keepingNamedTemporaryFile's default0o600mode.PermissionErrorhandling and Windowspublished_modeapplication.Tests pass (32/32 in
test_rpf_probe.py),scripts/check_no_game_data.pypasses cleanly.agent: yes
AI-assisted: yes
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.