Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Yaml] Deprecate tags using colon#22913
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
xabbuh commentedMay 25, 2017
👍 (we will probably still need some special handling for the |
GuilhemN commentedMay 25, 2017
The handling won't be dedicated, the value will just need to be quoted: !php/const "Foo::BAR": quz |
GuilhemN commentedMay 29, 2017
PR broken for now, will fix it later. |
UPGRADE-3.4.md Outdated
| ```yml | ||
| !php/const PHP_INT_MAX | ||
| ``` | ||
| >>>>>>>[Yaml] Deprecate tags using colon |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
this line must be removed. You messed some conflict resolution
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
indeed
GuilhemN commentedJun 29, 2017
Rebased on 3.4, it should be ok now. |
fabpot commentedJul 6, 2017
@xabbuh Can you check this one please? |
84bd287 to8ee9609CompareGuilhemN commentedJul 24, 2017
The build failure is because this is not yet in master. |
chalasr commentedJul 31, 2017
Needs rebase |
GuilhemN commentedAug 1, 2017
@chalasr rebased. |
xabbuh left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
just a few minor comments
| 3.4.0 | ||
| ----- | ||
| * Deprecated the tag`!php/object:` tag which will be replaced by the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
the "tag" in front of!php/object: should be removed
| * Deprecated the tag`!php/object:` tag which will be replaced by the | ||
| `!php/object` tag (without the colon) in 4.0. | ||
| * Deprecated the tag`!php/const:` tag which will be replaced by the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
the "tag" in front of!php/const: should be removed
| if (self::$exceptionOnInvalidType) { | ||
| thrownewParseException(sprintf('The string "%s" could not be parsed as a constant. Have you forgotten to pass the "Yaml::PARSE_CONSTANT" flag to the parser?',$scalar)); | ||
| } | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
no need for this blank line
GuilhemN commentedAug 4, 2017
@xabbuh fixed |
xabbuh commentedAug 4, 2017
Thank you@GuilhemN. |
This PR was squashed before being merged into the 3.4 branch (closes#22913).Discussion----------[Yaml] Deprecate tags using colon| Q | A| ------------- | ---| Branch? | 3.4| Bug fix? | no| New feature? | no <!-- don't forget updating src/**/CHANGELOG.md files -->| BC breaks? | no| Deprecations? | yes| Tests pass? | yes| Fixed tickets || License | MIT| Doc PR |Using a colon in a tag doesn't look like yaml and causes trouble (see#22878), so I propose to just deprecate these tags in favor of more consistent tags.```yml- !php/const:PHP_INT_MAX- !php/object:O:30:"Symfony\Component\Yaml\Tests\A":1:{s:1:"a";s:3:"foo";}```would become```yml- !php/const PHP_INT_MAX- !php/object O:30:"Symfony\Component\Yaml\Tests\A":1:{s:1:"a";s:3:"foo";}```Commits-------9815af3 [Yaml] Deprecate tags using colon
This PR was merged into the 6.2 branch.Discussion----------[Yaml] Remove legacy parsing rule| Q | A| ------------- | ---| Branch? | 6.2| Bug fix? | no| New feature? | no| Deprecations? | no| Tickets | -| License | MIT| Doc PR | -As far as I understood correctly, this part of the regexp has been introduced in#22878 to support a syntax that has been deprecated in#22913 and removed in 4.0.Commits-------5d7f9f2 [Yaml] Remove legacy parsing rule
Uh oh!
There was an error while loading.Please reload this page.
Using a colon in a tag doesn't look like yaml and causes trouble (see#22878), so I propose to just deprecate these tags in favor of more consistent tags.
would become