Skip to content

Comments

Document MicroKernelTrait::$allowedEnvs property#22030

Open
lacatoire wants to merge 3 commits intosymfony:8.1from
lacatoire:feature/allowed-envs-doc
Open

Document MicroKernelTrait::$allowedEnvs property#22030
lacatoire wants to merge 3 commits intosymfony:8.1from
lacatoire:feature/allowed-envs-doc

Conversation

@lacatoire
Copy link
Contributor

This documents the new $allowedEnvs property added to MicroKernelTrait in Symfony 8.1 (symfony/symfony#63429).

When set to a non-empty array, the kernel throws an InvalidArgumentException at boot if the current environment is not in the list. Default [] preserves existing behavior.

Fixes #22027

@carsonbot carsonbot added this to the 8.1 milestone Feb 20, 2026
@carsonbot carsonbot changed the title Document MicroKernelTrait::$allowedEnvs property Document MicroKernelTrait::$allowedEnvs property Feb 20, 2026
@lacatoire lacatoire force-pushed the feature/allowed-envs-doc branch from cc2dcfe to a9dedd8 Compare February 20, 2026 13:49
@nicolas-grekas
Copy link
Member

See symfony/symfony#63440, I changed this morning to a method.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants