oc_chat
Loading...
Searching...
No Matches
env_inventory.py
Go to the documentation of this file.
1
#!/usr/bin/env python3
2
# -*- coding: utf-8 -*-
3
# oc_chat/testing/env_inventory.py
4
5
"""
6
Environment-inventory authority for the §20 stand-in (Plan 184).
7
8
Purpose
9
-------
10
Export the tracked environment prefix list as ONE named constant from
11
ONE module, per spec-10 section 20.2: on landing, this export
12
supersedes the inline list in the spec and becomes the single source
13
of truth as the namespace evolves. The restore check in the runner
14
module consumes this object directly.
15
16
Responsibilities
17
----------------
18
- ``TRACKED_ENV_PREFIXES`` — the pinned prefixes, section 20.2 (the
19
live agent-prefix producers sit in the registry discovery module).
20
21
Diagnostics
22
-----------
23
Domain: OC_TESTING
24
Levels:
25
L2 — lifecycle events
26
L3 — semantic details
27
L4 — deep tracing
28
29
Contracts
30
---------
31
- The prefix rule is UNCONDITIONAL (§20.2, v0.4.1 recut): every
32
``OC_CHAT_*`` / ``OC_AGENT_*`` variable participates in the
33
restore/leak check, including prefixed security-authority variables.
34
The non-prefixed families (transport-trust, package-index, provider
35
credentials) are the M8 env-guard's jurisdiction and are OUT of this
36
scope — one authority per variable family.
37
- The constant is a tuple: immutable by construction.
38
39
Dependencies
40
------------
41
- oc_diagnostics (structured debug logging via _dbg)
42
"""
43
from
__future__
import
annotations
44
45
from
oc_diagnostics
import
_dbg
46
47
#: §20.2: the tracked env prefix inventory. ONE constant, ONE module.
48
TRACKED_ENV_PREFIXES: tuple[str, str] = (
"OC_CHAT_"
,
"OC_AGENT_"
)
49
50
_dbg(
"OC_TESTING"
,
"module"
,
"loaded"
, 4)
51
52
__all__ = [
"TRACKED_ENV_PREFIXES"
]
oc_chat
testing
env_inventory.py
Generated by
1.15.0