Skip to content

EnvironmentConfigLoader protocol missing from consumer-profiles.md protocol list #130

Description

@codeforester

Problem

docs/consumer-profiles.md lists the exported typed protocols that consumers can implement to customise the framework. However, it omits EnvironmentConfigLoader, which IS exported from base_cli (confirmed in __init__.py and profile.py).

EnvironmentConfigLoader is the protocol for the load_config_for_environment field on CliProfile — the hook that allows environment-aware configuration loading (--environment staging maps to a different config file or set of values). A consumer who wants to implement environment-aware config loading needs to know this protocol exists and what its signature is.

Fix

Add EnvironmentConfigLoader to the protocol listing in docs/consumer-profiles.md, with:

  • Its signature: (project: ProjectInfo | None, config_path: Path | None, environment: str) -> dict | ConfigSnapshot
  • When to implement it (env-aware config files, per-environment secrets, environment validation)
  • A minimal example

Verify the full list against base_cli.__all__ to ensure no other protocols are missing.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status
Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions