Skip to content

[YAML] Usage of PHP constant in YAML keys fails on 3.3 #22854

Closed
@tgalopin

Description

@tgalopin
Q A
Bug report? yes
Feature request? no
BC Break report? yes
RFC? no
Symfony version 3.3

The following file was valid on 3.2 and its parsing fail on 3.3:
https://github.com/EnMarche/en-marche.fr/blob/fce5e06a50fa87b3416e6bb9dee13f1bafe000f4/app/config/services/workflows.yml#L14
https://circleci.com/gh/EnMarche/en-marche.fr/4428

It seems to be related to the usage of PHP constants as keys:

transitions:
    !php/const:AppBundle\TonMacron\InvitationProcessor::TRANSITION_FILL_INFO:
        from:
            - !php/const:AppBundle\TonMacron\InvitationProcessor::STATE_NEEDS_FRIEND_INFO
        to: !php/const:AppBundle\TonMacron\InvitationProcessor::STATE_NEEDS_FRIEND_PROJECT

Is it an invalid YAML syntax? Should I update it or is it a BC break in 3.3?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions