Closed
Description
Symfony version(s) affected: 5.1.3
Description
I am reading the following YAML file, but I get a parser exception.
How to reproduce
This is the code:
$config = Yaml::parseFile($ps_filepath, Yaml::PARSE_CONSTANT);
I am reading the following YAML file:
macro_scalar : /usr/local/fish
macro_list : [flounder, lobster, haddock]
macro_assoc : {
fish : [flounder, cod, haddock],
shellfish : [scallop, crab, clam],
other : [chicken, pig, cow]
}
override_value: "global"
This is the error:
Unexpected characters near "
override_value: "global"" at line 10.
If I move line override_value: "global"
to the begining of the file, the problem dissapears:
override_value: "global"
macro_scalar : /usr/local/fish
macro_list : [flounder, lobster, haddock]
macro_assoc : {
fish : [flounder, cod, haddock],
shellfish : [scallop, crab, clam],
other : [chicken, pig, cow]
}