{"action":"created","issue":{"url":"https://api.github.com/repos/api-platform/core/issues/2278","repository_url":"https://api.github.com/repos/api-platform/core","labels_url":"https://api.github.com/repos/api-platform/core/issues/2278/labels{/name}","comments_url":"https://api.github.com/repos/api-platform/core/issues/2278/comments","events_url":"https://api.github.com/repos/api-platform/core/issues/2278/events","html_url":"https://github.com/api-platform/core/pull/2278","id":373848976,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI1NjgxMDgw","number":2278,"title":"Validation to only validate properties submitted if not a posting a new entity","user":{"login":"silverbackdan","id":25174262,"node_id":"MDQ6VXNlcjI1MTc0MjYy","avatar_url":"https://avatars0.githubusercontent.com/u/25174262?v=4","gravatar_id":"","url":"https://api.github.com/users/silverbackdan","html_url":"https://github.com/silverbackdan","followers_url":"https://api.github.com/users/silverbackdan/followers","following_url":"https://api.github.com/users/silverbackdan/following{/other_user}","gists_url":"https://api.github.com/users/silverbackdan/gists{/gist_id}","starred_url":"https://api.github.com/users/silverbackdan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/silverbackdan/subscriptions","organizations_url":"https://api.github.com/users/silverbackdan/orgs","repos_url":"https://api.github.com/users/silverbackdan/repos","events_url":"https://api.github.com/users/silverbackdan/events{/privacy}","received_events_url":"https://api.github.com/users/silverbackdan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-10-25T09:15:38Z","updated_at":"2018-10-25T16:39:16Z","closed_at":null,"author_association":"NONE","pull_request":{"url":"https://api.github.com/repos/api-platform/core/pulls/2278","html_url":"https://github.com/api-platform/core/pull/2278","diff_url":"https://github.com/api-platform/core/pull/2278.diff","patch_url":"https://github.com/api-platform/core/pull/2278.patch"},"body":"During a put/patch request - it doesn't seem applicable to validate fields that have not been submitted for change. In my case it was definitely not desired. When filling in a form, I'm looking to update each field as a user progresses through the form. Currently, this will send back violations for every field that failed validation and therefore not update the entity. Thoughts?\r\n\r\n~~The Nelmio Behat test is now failing with a 500 error but I haven't traced the cause for this yet and am not sure whether it is related to this PR.~~\r\n_Edit: Must have just been on my local machine and an unrelated issue. Tests pass fine on the automated tools_\r\n\r\nI added a PHPUnit test for this functionality.\r\n\r\n| Q             | A\r\n| ------------- | ---\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 | n/a\r\n| License       | MIT\r\n| Doc PR        | n/a\r\n"},"comment":{"url":"https://api.github.com/repos/api-platform/core/issues/comments/433121903","html_url":"https://github.com/api-platform/core/pull/2278#issuecomment-433121903","issue_url":"https://api.github.com/repos/api-platform/core/issues/2278","id":433121903,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMzEyMTkwMw==","user":{"login":"silverbackdan","id":25174262,"node_id":"MDQ6VXNlcjI1MTc0MjYy","avatar_url":"https://avatars0.githubusercontent.com/u/25174262?v=4","gravatar_id":"","url":"https://api.github.com/users/silverbackdan","html_url":"https://github.com/silverbackdan","followers_url":"https://api.github.com/users/silverbackdan/followers","following_url":"https://api.github.com/users/silverbackdan/following{/other_user}","gists_url":"https://api.github.com/users/silverbackdan/gists{/gist_id}","starred_url":"https://api.github.com/users/silverbackdan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/silverbackdan/subscriptions","organizations_url":"https://api.github.com/users/silverbackdan/orgs","repos_url":"https://api.github.com/users/silverbackdan/repos","events_url":"https://api.github.com/users/silverbackdan/events{/privacy}","received_events_url":"https://api.github.com/users/silverbackdan/received_events","type":"User","site_admin":false},"created_at":"2018-10-25T16:39:16Z","updated_at":"2018-10-25T16:39:16Z","author_association":"NONE","body":"I forgot to say in my first comment thank you very much for taking time to give feedback! I'm happy to make that change, but before dedicating more time to adding that I'll wait to hear from the core team. :) I'm not sure if this would improve performance at all by not validating the entire object (I haven't run any benchmarks) or if it'd be classed as a breaking change without an opt-in option. It'd be good to know a use-case when all fields would want to be validated even if they weren't all submitted but I haven't thought of one myself yet. Thanks again @antograssiot"}}
{"actor":{"display_login":"silverbackdan"}}