{"action":"created","issue":{"url":"https://api.github.com/repos/python/typeshed/issues/589","repository_url":"https://api.github.com/repos/python/typeshed","labels_url":"https://api.github.com/repos/python/typeshed/issues/589/labels{/name}","comments_url":"https://api.github.com/repos/python/typeshed/issues/589/comments","events_url":"https://api.github.com/repos/python/typeshed/issues/589/events","html_url":"https://github.com/python/typeshed/issues/589","id":181654898,"number":589,"title":"Type for argument of datetime.tzinfo.dst","user":{"login":"dmoisset","id":200733,"avatar_url":"https://avatars.githubusercontent.com/u/200733?v=3","gravatar_id":"","url":"https://api.github.com/users/dmoisset","html_url":"https://github.com/dmoisset","followers_url":"https://api.github.com/users/dmoisset/followers","following_url":"https://api.github.com/users/dmoisset/following{/other_user}","gists_url":"https://api.github.com/users/dmoisset/gists{/gist_id}","starred_url":"https://api.github.com/users/dmoisset/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmoisset/subscriptions","organizations_url":"https://api.github.com/users/dmoisset/orgs","repos_url":"https://api.github.com/users/dmoisset/repos","events_url":"https://api.github.com/users/dmoisset/events{/privacy}","received_events_url":"https://api.github.com/users/dmoisset/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2016-10-07T12:20:23Z","updated_at":"2016-10-07T16:52:07Z","closed_at":"2016-10-07T16:52:07Z","body":"The stubs for the `datetime` module specify:\r\n\r\n```python\r\nclass tzinfo:\r\n    ...\r\n    def dst(self, dt: Optional[datetime]) -> Optional[timedelta]: ...\r\n```\r\n\r\nBut I've seen a lot of code written that assumes that `dt` is never None. That includes some of the official examples (like the `LocalTimezone` class in https://docs.python.org/3.6/library/datetime.html), although some other of the standard examples seem to check if the argument is `None` (see the `USTimeZone`, same documentation page).\r\n\r\nI'm happy to submit the (trivial) patch but I couldn't find a clear spec detailing if `None` is actually a valid argument for this method."},"comment":{"url":"https://api.github.com/repos/python/typeshed/issues/comments/252303880","html_url":"https://github.com/python/typeshed/issues/589#issuecomment-252303880","issue_url":"https://api.github.com/repos/python/typeshed/issues/589","id":252303880,"user":{"login":"dmoisset","id":200733,"avatar_url":"https://avatars.githubusercontent.com/u/200733?v=3","gravatar_id":"","url":"https://api.github.com/users/dmoisset","html_url":"https://github.com/dmoisset","followers_url":"https://api.github.com/users/dmoisset/followers","following_url":"https://api.github.com/users/dmoisset/following{/other_user}","gists_url":"https://api.github.com/users/dmoisset/gists{/gist_id}","starred_url":"https://api.github.com/users/dmoisset/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dmoisset/subscriptions","organizations_url":"https://api.github.com/users/dmoisset/orgs","repos_url":"https://api.github.com/users/dmoisset/repos","events_url":"https://api.github.com/users/dmoisset/events{/privacy}","received_events_url":"https://api.github.com/users/dmoisset/received_events","type":"User","site_admin":false},"created_at":"2016-10-07T16:52:07Z","updated_at":"2016-10-07T16:52:07Z","body":"OK, in that case I'll close this. I opened http://bugs.python.org/issue28386\r\n"}}
{"actor":{"display_login":"dmoisset"}}