{"action":"created","comment":{"url":"https://api.github.com/repos/symfony/symfony/pulls/comments/232456782","pull_request_review_id":173665871,"id":232456782,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMjQ1Njc4Mg==","diff_hunk":"@@ -1133,7 +1151,13 @@ private function viewToNorm($value)\n                 $value = $transformers[$i]->reverseTransform($value);\n             }\n         } catch (TransformationFailedException $exception) {\n-            throw new TransformationFailedException('Unable to reverse value for property path \"'.$this->getPropertyPath().'\": '.$exception->getMessage(), $exception->getCode(), $exception);\n+            throw new TransformationFailedException(","path":"src/Symfony/Component/Form/Form.php","position":50,"original_position":50,"commit_id":"4ede27196e1a4c09c9f19b456bb7548edc3a48df","original_commit_id":"4ede27196e1a4c09c9f19b456bb7548edc3a48df","user":{"login":"xabbuh","id":1957048,"node_id":"MDQ6VXNlcjE5NTcwNDg=","avatar_url":"https://avatars0.githubusercontent.com/u/1957048?v=4","gravatar_id":"","url":"https://api.github.com/users/xabbuh","html_url":"https://github.com/xabbuh","followers_url":"https://api.github.com/users/xabbuh/followers","following_url":"https://api.github.com/users/xabbuh/following{/other_user}","gists_url":"https://api.github.com/users/xabbuh/gists{/gist_id}","starred_url":"https://api.github.com/users/xabbuh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xabbuh/subscriptions","organizations_url":"https://api.github.com/users/xabbuh/orgs","repos_url":"https://api.github.com/users/xabbuh/repos","events_url":"https://api.github.com/users/xabbuh/events{/privacy}","received_events_url":"https://api.github.com/users/xabbuh/received_events","type":"User","site_admin":false},"body":"and here","created_at":"2018-11-10T16:07:40Z","updated_at":"2018-11-10T16:09:35Z","html_url":"https://github.com/symfony/symfony/pull/20978#discussion_r232456782","pull_request_url":"https://api.github.com/repos/symfony/symfony/pulls/20978","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments/232456782"},"html":{"href":"https://github.com/symfony/symfony/pull/20978#discussion_r232456782"},"pull_request":{"href":"https://api.github.com/repos/symfony/symfony/pulls/20978"}}},"pull_request":{"url":"https://api.github.com/repos/symfony/symfony/pulls/20978","id":98474901,"node_id":"MDExOlB1bGxSZXF1ZXN0OTg0NzQ5MDE=","html_url":"https://github.com/symfony/symfony/pull/20978","diff_url":"https://github.com/symfony/symfony/pull/20978.diff","patch_url":"https://github.com/symfony/symfony/pull/20978.patch","issue_url":"https://api.github.com/repos/symfony/symfony/issues/20978","number":20978,"state":"open","locked":false,"title":"[Form] TransformationFailedException: Support specifying message to display","user":{"login":"ogizanagi","id":2211145,"node_id":"MDQ6VXNlcjIyMTExNDU=","avatar_url":"https://avatars0.githubusercontent.com/u/2211145?v=4","gravatar_id":"","url":"https://api.github.com/users/ogizanagi","html_url":"https://github.com/ogizanagi","followers_url":"https://api.github.com/users/ogizanagi/followers","following_url":"https://api.github.com/users/ogizanagi/following{/other_user}","gists_url":"https://api.github.com/users/ogizanagi/gists{/gist_id}","starred_url":"https://api.github.com/users/ogizanagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ogizanagi/subscriptions","organizations_url":"https://api.github.com/users/ogizanagi/orgs","repos_url":"https://api.github.com/users/ogizanagi/repos","events_url":"https://api.github.com/users/ogizanagi/events{/privacy}","received_events_url":"https://api.github.com/users/ogizanagi/received_events","type":"User","site_admin":false},"body":"| Q             | A\r\n| ------------- | ---\r\n| Branch?       | master\r\n| Bug fix?      | no\r\n| New feature?  | yes\r\n| BC breaks?    | no\r\n| Deprecations? | no\r\n| Tests pass?   | yes\r\n| Fixed tickets | #22501\r\n| License       | MIT\r\n| Doc PR        | N/A\r\n\r\nCurrently, a failed transformation can't display a very accurate message, as it only uses the value of the `invalid_message` option. I suggest to add more flexibility, somehow the same way we did for `CustomUserMessageAuthenticationException`.\r\n\r\nA test case in `FormTypeTest` shows a use-case based on @webmozart's [blog post about value/immutable objects in Symfony forms](https://webmozart.io/blog/2015/09/09/value-objects-in-symfony-forms/).\r\n\r\n~I named the exception properties and methods the same way as for `CustomUserMessageAuthenticationException`, but do you think the followings would be better:~\r\n\r\n- ~`setSafeMessage` ➜ `setInvalidMessage`~\r\n- ~`getMessageKey` ➜ `getInvalidMessageKey`~\r\n- ~`getMessageData` ➜ `getInvalidMessageParameters`~\r\n\r\n~in order to echoes `invalid_message` and `invalid_message_parameters` options?~\r\n\r\n=> Replaced to use `invalidMessage` & `invalidMessageParameters`","created_at":"2016-12-18T13:44:40Z","updated_at":"2018-11-10T16:09:35Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8e4516b20494037d5442bab54ecb56de37f3c527","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":100378,"node_id":"MDU6TGFiZWwxMDAzNzg=","url":"https://api.github.com/repos/symfony/symfony/labels/Feature","name":"Feature","color":"02e10c","default":false},{"id":99594,"node_id":"MDU6TGFiZWw5OTU5NA==","url":"https://api.github.com/repos/symfony/symfony/labels/Form","name":"Form","color":"DDDDDD","default":false},{"id":237003792,"node_id":"MDU6TGFiZWwyMzcwMDM3OTI=","url":"https://api.github.com/repos/symfony/symfony/labels/Status:%20Needs%20Review","name":"Status: Needs Review","color":"ededed","default":false}],"milestone":{"url":"https://api.github.com/repos/symfony/symfony/milestones/18","html_url":"https://github.com/symfony/symfony/milestone/18","labels_url":"https://api.github.com/repos/symfony/symfony/milestones/18/labels","id":3234645,"node_id":"MDk6TWlsZXN0b25lMzIzNDY0NQ==","number":18,"title":"next","description":"https://symfony.com/roadmap?version=4.2#checker","creator":{"login":"nicolas-grekas","id":243674,"node_id":"MDQ6VXNlcjI0MzY3NA==","avatar_url":"https://avatars3.githubusercontent.com/u/243674?v=4","gravatar_id":"","url":"https://api.github.com/users/nicolas-grekas","html_url":"https://github.com/nicolas-grekas","followers_url":"https://api.github.com/users/nicolas-grekas/followers","following_url":"https://api.github.com/users/nicolas-grekas/following{/other_user}","gists_url":"https://api.github.com/users/nicolas-grekas/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolas-grekas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolas-grekas/subscriptions","organizations_url":"https://api.github.com/users/nicolas-grekas/orgs","repos_url":"https://api.github.com/users/nicolas-grekas/repos","events_url":"https://api.github.com/users/nicolas-grekas/events{/privacy}","received_events_url":"https://api.github.com/users/nicolas-grekas/received_events","type":"User","site_admin":false},"open_issues":158,"closed_issues":7,"state":"open","created_at":"2018-04-02T12:03:21Z","updated_at":"2018-11-09T14:51:09Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/symfony/symfony/pulls/20978/commits","review_comments_url":"https://api.github.com/repos/symfony/symfony/pulls/20978/comments","review_comment_url":"https://api.github.com/repos/symfony/symfony/pulls/comments{/number}","comments_url":"https://api.github.com/repos/symfony/symfony/issues/20978/comments","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/4ede27196e1a4c09c9f19b456bb7548edc3a48df","head":{"label":"ogizanagi:feature/form/trans_failed_ex_safe_message","ref":"feature/form/trans_failed_ex_safe_message","sha":"4ede27196e1a4c09c9f19b456bb7548edc3a48df","user":{"login":"ogizanagi","id":2211145,"node_id":"MDQ6VXNlcjIyMTExNDU=","avatar_url":"https://avatars0.githubusercontent.com/u/2211145?v=4","gravatar_id":"","url":"https://api.github.com/users/ogizanagi","html_url":"https://github.com/ogizanagi","followers_url":"https://api.github.com/users/ogizanagi/followers","following_url":"https://api.github.com/users/ogizanagi/following{/other_user}","gists_url":"https://api.github.com/users/ogizanagi/gists{/gist_id}","starred_url":"https://api.github.com/users/ogizanagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ogizanagi/subscriptions","organizations_url":"https://api.github.com/users/ogizanagi/orgs","repos_url":"https://api.github.com/users/ogizanagi/repos","events_url":"https://api.github.com/users/ogizanagi/events{/privacy}","received_events_url":"https://api.github.com/users/ogizanagi/received_events","type":"User","site_admin":false},"repo":{"id":13498527,"node_id":"MDEwOlJlcG9zaXRvcnkxMzQ5ODUyNw==","name":"symfony","full_name":"ogizanagi/symfony","private":false,"owner":{"login":"ogizanagi","id":2211145,"node_id":"MDQ6VXNlcjIyMTExNDU=","avatar_url":"https://avatars0.githubusercontent.com/u/2211145?v=4","gravatar_id":"","url":"https://api.github.com/users/ogizanagi","html_url":"https://github.com/ogizanagi","followers_url":"https://api.github.com/users/ogizanagi/followers","following_url":"https://api.github.com/users/ogizanagi/following{/other_user}","gists_url":"https://api.github.com/users/ogizanagi/gists{/gist_id}","starred_url":"https://api.github.com/users/ogizanagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ogizanagi/subscriptions","organizations_url":"https://api.github.com/users/ogizanagi/orgs","repos_url":"https://api.github.com/users/ogizanagi/repos","events_url":"https://api.github.com/users/ogizanagi/events{/privacy}","received_events_url":"https://api.github.com/users/ogizanagi/received_events","type":"User","site_admin":false},"html_url":"https://github.com/ogizanagi/symfony","description":"The Symfony PHP framework","fork":true,"url":"https://api.github.com/repos/ogizanagi/symfony","forks_url":"https://api.github.com/repos/ogizanagi/symfony/forks","keys_url":"https://api.github.com/repos/ogizanagi/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ogizanagi/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ogizanagi/symfony/teams","hooks_url":"https://api.github.com/repos/ogizanagi/symfony/hooks","issue_events_url":"https://api.github.com/repos/ogizanagi/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/ogizanagi/symfony/events","assignees_url":"https://api.github.com/repos/ogizanagi/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/ogizanagi/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/ogizanagi/symfony/tags","blobs_url":"https://api.github.com/repos/ogizanagi/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ogizanagi/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ogizanagi/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/ogizanagi/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ogizanagi/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/ogizanagi/symfony/languages","stargazers_url":"https://api.github.com/repos/ogizanagi/symfony/stargazers","contributors_url":"https://api.github.com/repos/ogizanagi/symfony/contributors","subscribers_url":"https://api.github.com/repos/ogizanagi/symfony/subscribers","subscription_url":"https://api.github.com/repos/ogizanagi/symfony/subscription","commits_url":"https://api.github.com/repos/ogizanagi/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/ogizanagi/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/ogizanagi/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/ogizanagi/symfony/issues/comments{/number}","contents_url":"https://api.github.com/repos/ogizanagi/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/ogizanagi/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ogizanagi/symfony/merges","archive_url":"https://api.github.com/repos/ogizanagi/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ogizanagi/symfony/downloads","issues_url":"https://api.github.com/repos/ogizanagi/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/ogizanagi/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/ogizanagi/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/ogizanagi/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ogizanagi/symfony/labels{/name}","releases_url":"https://api.github.com/repos/ogizanagi/symfony/releases{/id}","deployments_url":"https://api.github.com/repos/ogizanagi/symfony/deployments","created_at":"2013-10-11T12:37:26Z","updated_at":"2017-10-30T19:03:35Z","pushed_at":"2018-11-10T15:57:37Z","git_url":"git://github.com/ogizanagi/symfony.git","ssh_url":"git@github.com:ogizanagi/symfony.git","clone_url":"https://github.com/ogizanagi/symfony.git","svn_url":"https://github.com/ogizanagi/symfony","homepage":"symfony.com","size":122533,"stargazers_count":0,"watchers_count":0,"language":"PHP","has_issues":false,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":1,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"symfony:master","ref":"master","sha":"664a032940a02ef9969345797cc3683ea56cf562","user":{"login":"symfony","id":143937,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MzkzNw==","avatar_url":"https://avatars3.githubusercontent.com/u/143937?v=4","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,"node_id":"MDEwOlJlcG9zaXRvcnk0NTgwNTg=","name":"symfony","full_name":"symfony/symfony","private":false,"owner":{"login":"symfony","id":143937,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE0MzkzNw==","avatar_url":"https://avatars3.githubusercontent.com/u/143937?v=4","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},"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}","deployments_url":"https://api.github.com/repos/symfony/symfony/deployments","created_at":"2010-01-04T14:21:21Z","updated_at":"2018-11-10T15:18:09Z","pushed_at":"2018-11-10T15:42:23Z","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":"https://symfony.com","size":127892,"stargazers_count":18999,"watchers_count":18999,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":6502,"mirror_url":null,"archived":false,"open_issues_count":832,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":6502,"open_issues":832,"watchers":18999,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/20978"},"html":{"href":"https://github.com/symfony/symfony/pull/20978"},"issue":{"href":"https://api.github.com/repos/symfony/symfony/issues/20978"},"comments":{"href":"https://api.github.com/repos/symfony/symfony/issues/20978/comments"},"review_comments":{"href":"https://api.github.com/repos/symfony/symfony/pulls/20978/comments"},"review_comment":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/symfony/symfony/pulls/20978/commits"},"statuses":{"href":"https://api.github.com/repos/symfony/symfony/statuses/4ede27196e1a4c09c9f19b456bb7548edc3a48df"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"xabbuh"}}