refactor: split profile_sync into profiling

profile_sync.py keeps the command line: the parser, the flag checks,
profile selection against the branch, main, and the two steps that
read top-level modules (project_base, the site's source paths). The
library goes to one module per concern under scripts/profiling.

Tests that patched a name now patch the module their caller reads
it from. test_layers declares profiling with no sibling imports.
This commit is contained in:
Abdessamad Derraz committed 2026-11-18 12:49:20 +01:00
1 parent eea24c68ca
commit 735f86283b
24 files changed
+6016 -5737

No files matched your search

+1 -1
View File
@@ -1736,7 +1736,7 @@ def summarize_profile_sync(report: object) -> list[Finding]:
# no resolvable pin) is unknown. One that is the profile's nature
# (an upstream declared gone, a host no forge API serves, no
# source_ref) is never checkable and does not hold the exit code.
from profile_sync import ProfileReport
from profiling.reports import ProfileReport
reason = str(row["skipped"])
status = UNKNOWN if reason.startswith(ProfileReport.UNCHECKABLE) else SKIPPED