You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Symfony version(s) affected: 5.1.5 (probably other versions, too)
Description
If you don't use symfony/yaml component, the command "config:dump-reference" is trying to use yaml as default value for "format" option, resulting in an error.
How to reproduce
create a symfony project without symfony/yaml component (or remove symfony/yaml component from an existing project).
try to dump configuration for any bundle, e.g. console config:dump-reference twig
see error (in YamlReferenceDumper.php line 111) :
Attempted to load class "Inline" from namespace "Symfony\Component\Yaml".
Did you forget a "use" statement for another namespace?
Possible Solution
A check for existance of above class should be added. If not present, default value of "format" option should be "xml" instead of "yaml".
The text was updated successfully, but these errors were encountered:
… (jschaedl)
This PR was submitted for the master branch but it was squashed and merged into the 5.x branch instead.
Discussion
----------
[FrameworkBundle] Add check for installed yaml component
| Q | A
| ------------- | ---
| Branch? | master
| Bug fix? | yes
| New feature? | no <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tickets | Fix#38301 <!-- prefix each issue number with "Fix #", no need to create an issue if none exist, explain below instead -->
| License | MIT
| Doc PR | - <!-- required for new features -->
<!--
Replace this notice by a short README for your feature/bugfix. This will help people
understand your PR and can be used as a start for the documentation.
Additionally (see https://symfony.com/releases):
- Always add tests and ensure they pass.
- Never break backward compatibility (see https://symfony.com/bc).
- Bug fixes must be submitted against the lowest maintained branch where they apply
(lowest branches are regularly merged to upper ones so they get the fixes too.)
- Features and deprecations must be submitted against branch master.
-->
**Todo:**
- [ ] add tests
Commits
-------
f174ad2 [FrameworkBundle] Add check for installed yaml component
Symfony version(s) affected: 5.1.5 (probably other versions, too)
Description
If you don't use symfony/yaml component, the command "config:dump-reference" is trying to use yaml as default value for "format" option, resulting in an error.
How to reproduce
console config:dump-reference twig
Possible Solution
A check for existance of above class should be added. If not present, default value of "format" option should be "xml" instead of "yaml".
The text was updated successfully, but these errors were encountered: