mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-27 00:30:52 +01:00
[PR #1229] rtti_scan: ask report_paths for the report-path guard (RTTI-SCAN-SHARED-REPORT-PATH) #1262
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#1262
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/1229
Author: @breachato
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:rtti-scan-shared-report-path📝 Commits (1)
8bde265rtti_scan: ask report_paths for the report-path guard📊 Changes
1 file changed (+2 additions, -6 deletions)
View changed files
📝
tools/rtti_scan.py(+2 -6)📄 Description
Claimed in the coordination issue as: RTTI-SCAN-SHARED-REPORT-PATH (https://github.com/ubiquitarianism/leonida/issues/14#issuecomment-7143810576)
Depends on: none
Fixes: none
What and why
tools/rtti_scan.pyderived the report-path answer inline inmain(:518-524): realpath + normcase comparedby hand, then
os.path.samefileinside a bareexcept OSError: pass, to refuse an--outthat would overwritethe image being scanned. That is the answer
tools/report_paths.same_report_pathexists to give, andCONTRIBUTING.md asks a report writer to call it rather than derive it again.
The inline copy also missed that helper's folding-volume probe, so on a Linux mount that ignores case (vfat,
exFAT, CIFS)
--out IMAGE.rtti.jsonbeside an existingimage.rtti.jsonwas not refused and the report replacedthe previous one.
The five lines become one call. The tool already puts its own folder on
sys.pathforfile_mode, so the importis one line, and nothing else references the inline name. Different topic from RTTI-SCAN-STAGE-CLEANUP (#798,
staged-file permissions). No behaviour change on Windows, macOS or a case-sensitive Linux filesystem.
Tested
tests/test_rtti_scan.py: 29 passed, 1 skipped, 47 subtests passed.python -I tools/rtti_scan.py --help: prints its usage (the import works under-I).python -m compileall -q tools/rtti_scan.py: clean.machine is NTFS, where
normcasealready folds case.tests/test_report_paths.pycovers the helper's ownfolding-volume answer.
GPUs tested: n/a
AI-assisted: yes
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed. (n/a: no translator change)🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.