Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[Yaml] fix parse error when unindented collections contain a comment#36683

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

Merged
fabpot merged 1 commit intosymfony:3.4fromwdiesveld:ticket_36558
May 4, 2020

Conversation

@wdiesveld
Copy link
Contributor

QA
Branch?5.0
Bug fix?yes
New feature?no
Deprecations?no
TicketsFix#36558
LicenseMIT

Problem

The methodParser::getNextEmbedBlock did not determine the yaml-block correctly when there was a comment before the first unindented collection item. This was caused by the fact that the check for unindented collection items was done for thefirst line of the block only. So in case this first line is a comment, this check will result infalse, while in fact the parser is in an unindented collection.

Solution

In the solution I implemented the parser will check for comment lines as well. As long as the loop encounters a comment line, it will check (in the next iteration) whether the line is an unindented collection item. So this check will be done until all comments before the first uncommented item are parsed.

@wdiesveldwdiesveld requested a review fromxabbuh as acode ownerMay 4, 2020 10:15
@wdiesveldwdiesveld changed the titleTicket 36558Fix for Ticket 36558May 4, 2020
@xabbuhxabbuh added the Yaml labelMay 4, 2020
@xabbuhxabbuh added this to the3.4 milestoneMay 4, 2020
@xabbuh
Copy link
Member

For 3.4?

@wdiesveld
Copy link
ContributorAuthor

@xabbuh - I could not test it for 3.4 and 4.0, only for 5.0 - I get an out-of-mem error when runningcomposer update for 3.4 & 4.0 (Windows 10). So the PR is for 5.0

@nicolas-grekasnicolas-grekas changed the titleFix for Ticket 36558[Yaml] fix parse error when unindented collections contain a commentMay 4, 2020
@xabbuhxabbuh changed the base branch from5.0 to3.4May 4, 2020 11:18
@xabbuh
Copy link
Member

@wdiesveld No problem, I have changed the base branch and rebased your changes. Thank you for working on this issue.

@fabpot
Copy link
Member

Thank you@wdiesveld.

@fabpotfabpot merged commitbb77914 intosymfony:3.4May 4, 2020
@Nyholm
Copy link
Member

Awesome. Congratulations to your first contribution!

This was referencedMay 31, 2020
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@fabpotfabpotfabpot approved these changes

@xabbuhxabbuhxabbuh approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

3.4

Development

Successfully merging this pull request may close these issues.

5 participants

@wdiesveld@xabbuh@fabpot@Nyholm@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp