cctally 1.83.0 → 1.84.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +34 -0
- package/README.md +2 -4
- package/bin/_cctally_account.py +144 -11
- package/bin/_cctally_alerts.py +3 -1
- package/bin/_cctally_cache.py +1396 -33
- package/bin/_cctally_dashboard.py +46 -2
- package/bin/_cctally_dashboard_conversation.py +16 -7
- package/bin/_cctally_dashboard_envelope.py +12 -0
- package/bin/_cctally_dashboard_share.py +58 -5
- package/bin/_cctally_dashboard_sources.py +641 -38
- package/bin/_cctally_db.py +173 -7
- package/bin/_cctally_doctor.py +112 -27
- package/bin/_cctally_journal.py +761 -74
- package/bin/_cctally_milestone_history.py +73 -16
- package/bin/_cctally_quota.py +313 -15
- package/bin/_cctally_source_analytics.py +4 -1
- package/bin/_cctally_tui.py +7 -3
- package/bin/_lib_doctor.py +67 -2
- package/bin/_lib_journal.py +48 -0
- package/bin/_lib_jsonl.py +119 -0
- package/bin/_lib_quota.py +222 -13
- package/bin/_lib_rederive.py +12 -0
- package/bin/_lib_source_analytics.py +13 -0
- package/bin/_lib_source_identity.py +24 -0
- package/dashboard/static/assets/index-DlVVJeS4.js +92 -0
- package/dashboard/static/assets/index-OYBkyglj.css +1 -0
- package/dashboard/static/dashboard.html +2 -2
- package/package.json +1 -1
- package/dashboard/static/assets/index-3bgCMVHb.js +0 -92
- package/dashboard/static/assets/index-D27EIHEI.css +0 -1
|
@@ -25,6 +25,30 @@ def source_root_key(canonical_root: str) -> str:
|
|
|
25
25
|
return digest.hexdigest()[:32]
|
|
26
26
|
|
|
27
27
|
|
|
28
|
+
def codex_file_key(root_key: str, canonical_physical_path: str) -> str:
|
|
29
|
+
"""Return the durable identity of one Codex rollout file (#416 spec §3.2).
|
|
30
|
+
|
|
31
|
+
Keyed on ``(source_root_key, canonical physical path)`` — deliberately NOT
|
|
32
|
+
on the configured walk spelling, because Codex discovery deduplicates on the
|
|
33
|
+
canonical physical path but persists the FIRST configured candidate
|
|
34
|
+
spelling, so reordering ``$CODEX_HOME`` roots or respelling a symlink makes
|
|
35
|
+
the same physical file miss a path-keyed map.
|
|
36
|
+
|
|
37
|
+
Scoping by ``root_key`` is what makes a root requalification safe for free:
|
|
38
|
+
the same physical file reached under a different provider root is a
|
|
39
|
+
different identity, so it carries no prior attribution decision and takes a
|
|
40
|
+
fresh one. Non-reversible and fixed-width like ``source_root_key``, so the
|
|
41
|
+
durable key never embeds an operator path.
|
|
42
|
+
"""
|
|
43
|
+
root = _required_string(root_key, "root_key")
|
|
44
|
+
path = _required_string(canonical_physical_path, "canonical_physical_path")
|
|
45
|
+
digest = hashlib.sha256(
|
|
46
|
+
b"cctally-codex-file-v1\0" + root.encode("utf-8")
|
|
47
|
+
+ b"\0" + path.encode("utf-8")
|
|
48
|
+
)
|
|
49
|
+
return digest.hexdigest()[:32]
|
|
50
|
+
|
|
51
|
+
|
|
28
52
|
def canonical_identity(
|
|
29
53
|
source: str,
|
|
30
54
|
resource_kind: str,
|