aeat.core.telemetry._consent module¶
Remote-telemetry consent gate.
Mirrors cloud_evidence_read_permitted()’s exact
shape (gestor-mode absolute bar, then the deployment opt-in flag, then the
tier, then the per-invocation acknowledgement, all ANDed) so the codebase’s
off-host consent gates stay uniform
(sensitive-financial-data-secure-storage-only,
2026-07-04-remote-telemetry-adr). Settings is imported lazily inside the
function body to avoid the circular import that would result from
core.config importing telemetry for
TelemetryTier at module scope.
See also
emit_telemetry_event()Applies this gate before dispatching any remote-eligible payload.
TelemetryTierClosed tier enum consulted by the gate.
- telemetry_emit_permitted(settings, *, acknowledged)[source]¶
Whether a remote telemetry emission is permitted for THIS invocation.
All local telemetry (LLM run-timing, MCP session trajectory) stays unconditional and unaffected by this gate; it governs only the remote exception. A remote emission is permitted only when every one of the following holds:
Gestor/professional mode is OFF (
settings.aeat_telemetry_gestor_modeisFalse). This is an absolute, categorical bar: a gestor deployment never transmits telemetry regardless of the other three conditions.The deployment has opted in (
settings.aeat_telemetry_opt_inisTrue).The configured tier is not
OFF.The operator acknowledged this specific invocation (
acknowledgedisTrue). The acknowledgement is never sticky; it must be re-affirmed at every call site, mirroringcloud_evidence_read_permitted().