{"action":"created","issue":{"url":"https://api.github.com/repos/marshmallow-code/marshmallow/issues/899","repository_url":"https://api.github.com/repos/marshmallow-code/marshmallow","labels_url":"https://api.github.com/repos/marshmallow-code/marshmallow/issues/899/labels{/name}","comments_url":"https://api.github.com/repos/marshmallow-code/marshmallow/issues/899/comments","events_url":"https://api.github.com/repos/marshmallow-code/marshmallow/issues/899/events","html_url":"https://github.com/marshmallow-code/marshmallow/issues/899","id":346564048,"node_id":"MDU6SXNzdWUzNDY1NjQwNDg=","number":899,"title":"fields.Date accepts input in non ISO8601 format. This leads to unaccepted behaviour.","user":{"login":"dushr","id":616699,"node_id":"MDQ6VXNlcjYxNjY5OQ==","avatar_url":"https://avatars3.githubusercontent.com/u/616699?v=4","gravatar_id":"","url":"https://api.github.com/users/dushr","html_url":"https://github.com/dushr","followers_url":"https://api.github.com/users/dushr/followers","following_url":"https://api.github.com/users/dushr/following{/other_user}","gists_url":"https://api.github.com/users/dushr/gists{/gist_id}","starred_url":"https://api.github.com/users/dushr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dushr/subscriptions","organizations_url":"https://api.github.com/users/dushr/orgs","repos_url":"https://api.github.com/users/dushr/repos","events_url":"https://api.github.com/users/dushr/events{/privacy}","received_events_url":"https://api.github.com/users/dushr/received_events","type":"User","site_admin":false},"labels":[{"id":1011519607,"node_id":"MDU6TGFiZWwxMDExNTE5NjA3","url":"https://api.github.com/repos/marshmallow-code/marshmallow/labels/datetime","name":"datetime","color":"432393","default":false},{"id":96590020,"node_id":"MDU6TGFiZWw5NjU5MDAyMA==","url":"https://api.github.com/repos/marshmallow-code/marshmallow/labels/help%20wanted","name":"help wanted","color":"0e8a16","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/marshmallow-code/marshmallow/milestones/10","html_url":"https://github.com/marshmallow-code/marshmallow/milestone/10","labels_url":"https://api.github.com/repos/marshmallow-code/marshmallow/milestones/10/labels","id":1419130,"node_id":"MDk6TWlsZXN0b25lMTQxOTEzMA==","number":10,"title":"3.0","description":"","creator":{"login":"sloria","id":2379650,"node_id":"MDQ6VXNlcjIzNzk2NTA=","avatar_url":"https://avatars2.githubusercontent.com/u/2379650?v=4","gravatar_id":"","url":"https://api.github.com/users/sloria","html_url":"https://github.com/sloria","followers_url":"https://api.github.com/users/sloria/followers","following_url":"https://api.github.com/users/sloria/following{/other_user}","gists_url":"https://api.github.com/users/sloria/gists{/gist_id}","starred_url":"https://api.github.com/users/sloria/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sloria/subscriptions","organizations_url":"https://api.github.com/users/sloria/orgs","repos_url":"https://api.github.com/users/sloria/repos","events_url":"https://api.github.com/users/sloria/events{/privacy}","received_events_url":"https://api.github.com/users/sloria/received_events","type":"User","site_admin":false},"open_issues":20,"closed_issues":46,"state":"open","created_at":"2015-11-19T03:17:00Z","updated_at":"2018-09-11T12:51:57Z","due_on":null,"closed_at":null},"comments":8,"created_at":"2018-08-01T11:42:20Z","updated_at":"2018-09-14T10:57:36Z","closed_at":null,"author_association":"NONE","body":"The doc of `fields.Date` suggests that it accepts only ISO8601 date format.\r\n\r\n```python\r\nclass Date(Field):\r\n    \"\"\"ISO8601-formatted date string.\r\n    :param kwargs: The same keyword arguments that :class:`Field` receives.\r\n    \"\"\"\r\n```\r\n\r\nIt works with ISO8601 format fine:\r\n```python\r\nIn [2]: fields.Date().deserialize('2018-10-08')\r\nOut[2]: datetime.date(2018, 10, 8)\r\n```\r\n\r\nHowever unfortunately it also works with non ISO8601 formats:\r\n```python\r\nIn [3]: fields.Date().deserialize('08-10-2018')\r\nOut[3]: datetime.date(2018, 8, 10)\r\n```\r\nAnd in this case it seems like it parses the format as `%m-%d-%Y`\r\nI feel, it should raise a ValidationError with `invalid_date` format incase the input is not in the iso8601 format.\r\n\r\nDigging further into the issue I found that DateField uses `utils.from_iso_date`; which inturn uses dateutil (if available) parser to parse the date.\r\nI think that util should be modified to use [dateutil.parser.isoparse](https://dateutil.readthedocs.io/en/stable/parser.html#dateutil.parser.isoparse)\r\n"},"comment":{"url":"https://api.github.com/repos/marshmallow-code/marshmallow/issues/comments/421321528","html_url":"https://github.com/marshmallow-code/marshmallow/issues/899#issuecomment-421321528","issue_url":"https://api.github.com/repos/marshmallow-code/marshmallow/issues/899","id":421321528,"node_id":"MDEyOklzc3VlQ29tbWVudDQyMTMyMTUyOA==","user":{"login":"dushr","id":616699,"node_id":"MDQ6VXNlcjYxNjY5OQ==","avatar_url":"https://avatars3.githubusercontent.com/u/616699?v=4","gravatar_id":"","url":"https://api.github.com/users/dushr","html_url":"https://github.com/dushr","followers_url":"https://api.github.com/users/dushr/followers","following_url":"https://api.github.com/users/dushr/following{/other_user}","gists_url":"https://api.github.com/users/dushr/gists{/gist_id}","starred_url":"https://api.github.com/users/dushr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dushr/subscriptions","organizations_url":"https://api.github.com/users/dushr/orgs","repos_url":"https://api.github.com/users/dushr/repos","events_url":"https://api.github.com/users/dushr/events{/privacy}","received_events_url":"https://api.github.com/users/dushr/received_events","type":"User","site_admin":false},"created_at":"2018-09-14T10:57:36Z","updated_at":"2018-09-14T10:57:36Z","author_association":"NONE","body":"👍 Will try to get this done by this weeekend"}}
{"actor":{"display_login":"dushr"}}