Skip to content

[YAML] the YAML documentation should list the YAML special chars #4197

Closed
@stof

Description

@stof

YAML has a bunch of special chars requiring to use quoted values instead of unquoted values when they appear in it.
However, the doc at http://symfony.com/doc/current/components/yaml/yaml_format.html does not describe them currently (and the YAML spec is rather complex to understand because of the way it is written)

the logic used by the dumper to know whether the escaping is necessary is available in the code:

The fact that people don't know about special chars is causing issues when one of them is parsed as a string value only because of a bug in the parser, as this breaks your file once the parser gets fixed (or when parsing it with a different parser than the Symfony one). See symfony/symfony#11835 for an example

Metadata

Metadata

Assignees

No one assigned

    Labels

    actionableClear and specific issues ready for anyone to take them.hasPRA Pull Request has already been submitted for this issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions