{"action":"created","comment":{"url":"https://api.github.com/repos/symfony/symfony/pulls/comments/22808451","id":22808451,"diff_hunk":"@@ -234,9 +234,11 @@ public function parse($value, $exceptionOnInvalidType = false, $objectSupport =\n                     throw new ParseException('Multiple documents are not supported.');\n                 }\n \n-                // 1-liner optionally followed by newline\n-                $lineCount = count($this->lines);\n-                if (1 === $lineCount || (2 === $lineCount && empty($this->lines[1]))) {\n+                // store the last PCRE regex error code\n+                $pregLastError = preg_last_error();\n+\n+                // 1-liner optionally followed by newline(s)\n+                if (preg_match('#^.+\\s*#i', $value)) {","path":"src/Symfony/Component/Yaml/Parser.php","position":11,"original_position":11,"commit_id":"43e62613df110393ddbbfef6ecd061d1dd3da397","original_commit_id":"43e62613df110393ddbbfef6ecd061d1dd3da397","user":{"login":"alexpott","id":769634,"avatar_url":"https://avatars.githubusercontent.com/u/769634?v=3","gravatar_id":"","url":"https://api.github.com/users/alexpott","html_url":"https://github.com/alexpott","followers_url":"https://api.github.com/users/alexpott/followers","following_url":"https://api.github.com/users/alexpott/following{/other_user}","gists_url":"https://api.github.com/users/alexpott/gists{/gist_id}","starred_url":"https://api.github.com/users/alexpott/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexpott/subscriptions","organizations_url":"https://api.github.com/users/alexpott/orgs","repos_url":"https://api.github.com/users/alexpott/repos","events_url":"https://api.github.com/users/alexpott/events{/privacy}","received_events_url":"https://api.github.com/users/alexpott/received_events","type":"User","site_admin":false},"body":"Nope I get failures:\r\n1) Symfony\\Component\\Yaml\\Tests\\ParserTest::testEndOfTheDocumentMarker\r\nFailed asserting that two strings are equal.\r\n--- Expected\r\n+++ Actual\r\n@@ @@\r\n-'foo'\r\n+'--- %YAML:1.0\r\n+foo\r\n+...'\r\n\r\n2) Symfony\\Component\\Yaml\\Tests\\ParserTest::testUnindentedCollectionException\r\nFailed asserting that exception of type \"\\Symfony\\Component\\Yaml\\Exception\\ParseException\" is thrown.","created_at":"2015-01-12T18:08:47Z","updated_at":"2015-01-12T18:08:47Z","html_url":"https://github.com/symfony/symfony/pull/13375#discussion_r22808451","pull_request_url":"https://api.github.com/repos/symfony/symfony/pulls/13375","_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments/22808451"},"html":{"href":"https://github.com/symfony/symfony/pull/13375#discussion_r22808451"},"pull_request":{"href":"https://api.github.com/repos/symfony/symfony/pulls/13375"}}},"pull_request":{"url":"https://api.github.com/repos/symfony/symfony/pulls/13375","id":27187297,"html_url":"https://github.com/symfony/symfony/pull/13375","diff_url":"https://github.com/symfony/symfony/pull/13375.diff","patch_url":"https://github.com/symfony/symfony/pull/13375.patch","issue_url":"https://api.github.com/repos/symfony/symfony/issues/13375","number":13375,"state":"open","locked":false,"title":"[YAML] Fix one-liners to work with multiple new lines","user":{"login":"alexpott","id":769634,"avatar_url":"https://avatars.githubusercontent.com/u/769634?v=3","gravatar_id":"","url":"https://api.github.com/users/alexpott","html_url":"https://github.com/alexpott","followers_url":"https://api.github.com/users/alexpott/followers","following_url":"https://api.github.com/users/alexpott/following{/other_user}","gists_url":"https://api.github.com/users/alexpott/gists{/gist_id}","starred_url":"https://api.github.com/users/alexpott/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexpott/subscriptions","organizations_url":"https://api.github.com/users/alexpott/orgs","repos_url":"https://api.github.com/users/alexpott/repos","events_url":"https://api.github.com/users/alexpott/events{/privacy}","received_events_url":"https://api.github.com/users/alexpott/received_events","type":"User","site_admin":false},"body":"| Q             | A\r\n| ------------- | ---\r\n| Bug fix?      | yes\r\n| New feature?  | no\r\n| BC breaks?    | no\r\n| Deprecations? | no\r\n| Tests pass?   | yes\r\n| Fixed tickets | none\r\n| License       | MIT\r\n| Doc PR        | n/a","created_at":"2015-01-12T11:17:10Z","updated_at":"2015-01-12T18:08:47Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6b76527cc03c9b78a934b8c41e651b745dd00059","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/symfony/symfony/pulls/13375/commits","review_comments_url":"https://api.github.com/repos/symfony/symfony/pulls/13375/comments","review_comment_url":"https://api.github.com/repos/symfony/symfony/pulls/comments/{number}","comments_url":"https://api.github.com/repos/symfony/symfony/issues/13375/comments","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/43e62613df110393ddbbfef6ecd061d1dd3da397","head":{"label":"alexpott:yaml-1-liner-empty-new-lines","ref":"yaml-1-liner-empty-new-lines","sha":"43e62613df110393ddbbfef6ecd061d1dd3da397","user":{"login":"alexpott","id":769634,"avatar_url":"https://avatars.githubusercontent.com/u/769634?v=3","gravatar_id":"","url":"https://api.github.com/users/alexpott","html_url":"https://github.com/alexpott","followers_url":"https://api.github.com/users/alexpott/followers","following_url":"https://api.github.com/users/alexpott/following{/other_user}","gists_url":"https://api.github.com/users/alexpott/gists{/gist_id}","starred_url":"https://api.github.com/users/alexpott/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexpott/subscriptions","organizations_url":"https://api.github.com/users/alexpott/orgs","repos_url":"https://api.github.com/users/alexpott/repos","events_url":"https://api.github.com/users/alexpott/events{/privacy}","received_events_url":"https://api.github.com/users/alexpott/received_events","type":"User","site_admin":false},"repo":{"id":4222190,"name":"symfony","full_name":"alexpott/symfony","owner":{"login":"alexpott","id":769634,"avatar_url":"https://avatars.githubusercontent.com/u/769634?v=3","gravatar_id":"","url":"https://api.github.com/users/alexpott","html_url":"https://github.com/alexpott","followers_url":"https://api.github.com/users/alexpott/followers","following_url":"https://api.github.com/users/alexpott/following{/other_user}","gists_url":"https://api.github.com/users/alexpott/gists{/gist_id}","starred_url":"https://api.github.com/users/alexpott/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexpott/subscriptions","organizations_url":"https://api.github.com/users/alexpott/orgs","repos_url":"https://api.github.com/users/alexpott/repos","events_url":"https://api.github.com/users/alexpott/events{/privacy}","received_events_url":"https://api.github.com/users/alexpott/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/alexpott/symfony","description":"The Symfony2 PHP framework","fork":true,"url":"https://api.github.com/repos/alexpott/symfony","forks_url":"https://api.github.com/repos/alexpott/symfony/forks","keys_url":"https://api.github.com/repos/alexpott/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/alexpott/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/alexpott/symfony/teams","hooks_url":"https://api.github.com/repos/alexpott/symfony/hooks","issue_events_url":"https://api.github.com/repos/alexpott/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/alexpott/symfony/events","assignees_url":"https://api.github.com/repos/alexpott/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/alexpott/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/alexpott/symfony/tags","blobs_url":"https://api.github.com/repos/alexpott/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/alexpott/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/alexpott/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/alexpott/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/alexpott/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/alexpott/symfony/languages","stargazers_url":"https://api.github.com/repos/alexpott/symfony/stargazers","contributors_url":"https://api.github.com/repos/alexpott/symfony/contributors","subscribers_url":"https://api.github.com/repos/alexpott/symfony/subscribers","subscription_url":"https://api.github.com/repos/alexpott/symfony/subscription","commits_url":"https://api.github.com/repos/alexpott/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/alexpott/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/alexpott/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/alexpott/symfony/issues/comments/{number}","contents_url":"https://api.github.com/repos/alexpott/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/alexpott/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/alexpott/symfony/merges","archive_url":"https://api.github.com/repos/alexpott/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/alexpott/symfony/downloads","issues_url":"https://api.github.com/repos/alexpott/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/alexpott/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/alexpott/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/alexpott/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/alexpott/symfony/labels{/name}","releases_url":"https://api.github.com/repos/alexpott/symfony/releases{/id}","created_at":"2012-05-04T06:24:55Z","updated_at":"2014-09-21T19:23:41Z","pushed_at":"2015-01-12T11:15:44Z","git_url":"git://github.com/alexpott/symfony.git","ssh_url":"git@github.com:alexpott/symfony.git","clone_url":"https://github.com/alexpott/symfony.git","svn_url":"https://github.com/alexpott/symfony","homepage":"symfony.com","size":51026,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":false,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"symfony:2.7","ref":"2.7","sha":"7192b2f2f6e699962ec3114b5c7d75c7f02950b4","user":{"login":"symfony","id":143937,"avatar_url":"https://avatars.githubusercontent.com/u/143937?v=3","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"repo":{"id":458058,"name":"symfony","full_name":"symfony/symfony","owner":{"login":"symfony","id":143937,"avatar_url":"https://avatars.githubusercontent.com/u/143937?v=3","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/symfony/symfony","description":"The Symfony PHP framework","fork":false,"url":"https://api.github.com/repos/symfony/symfony","forks_url":"https://api.github.com/repos/symfony/symfony/forks","keys_url":"https://api.github.com/repos/symfony/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/symfony/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/symfony/symfony/teams","hooks_url":"https://api.github.com/repos/symfony/symfony/hooks","issue_events_url":"https://api.github.com/repos/symfony/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/symfony/symfony/events","assignees_url":"https://api.github.com/repos/symfony/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/symfony/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/symfony/symfony/tags","blobs_url":"https://api.github.com/repos/symfony/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/symfony/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/symfony/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/symfony/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/symfony/symfony/languages","stargazers_url":"https://api.github.com/repos/symfony/symfony/stargazers","contributors_url":"https://api.github.com/repos/symfony/symfony/contributors","subscribers_url":"https://api.github.com/repos/symfony/symfony/subscribers","subscription_url":"https://api.github.com/repos/symfony/symfony/subscription","commits_url":"https://api.github.com/repos/symfony/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/symfony/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/symfony/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/symfony/symfony/issues/comments/{number}","contents_url":"https://api.github.com/repos/symfony/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/symfony/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/symfony/symfony/merges","archive_url":"https://api.github.com/repos/symfony/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/symfony/symfony/downloads","issues_url":"https://api.github.com/repos/symfony/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/symfony/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/symfony/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/symfony/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/symfony/symfony/labels{/name}","releases_url":"https://api.github.com/repos/symfony/symfony/releases{/id}","created_at":"2010-01-04T14:21:21Z","updated_at":"2015-01-12T16:42:24Z","pushed_at":"2015-01-12T16:43:53Z","git_url":"git://github.com/symfony/symfony.git","ssh_url":"git@github.com:symfony/symfony.git","clone_url":"https://github.com/symfony/symfony.git","svn_url":"https://github.com/symfony/symfony","homepage":"symfony.com","size":188042,"stargazers_count":9490,"watchers_count":9490,"language":"PHP","has_issues":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":3706,"mirror_url":null,"open_issues_count":794,"forks":3706,"open_issues":794,"watchers":9490,"default_branch":"2.7"}},"_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/13375"},"html":{"href":"https://github.com/symfony/symfony/pull/13375"},"issue":{"href":"https://api.github.com/repos/symfony/symfony/issues/13375"},"comments":{"href":"https://api.github.com/repos/symfony/symfony/issues/13375/comments"},"review_comments":{"href":"https://api.github.com/repos/symfony/symfony/pulls/13375/comments"},"review_comment":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/symfony/symfony/pulls/13375/commits"},"statuses":{"href":"https://api.github.com/repos/symfony/symfony/statuses/43e62613df110393ddbbfef6ecd061d1dd3da397"}}}}