{"action":"created","issue":{"url":"https://api.github.com/repos/getdnsapi/getdns-python-bindings/issues/28","labels_url":"https://api.github.com/repos/getdnsapi/getdns-python-bindings/issues/28/labels{/name}","comments_url":"https://api.github.com/repos/getdnsapi/getdns-python-bindings/issues/28/comments","events_url":"https://api.github.com/repos/getdnsapi/getdns-python-bindings/issues/28/events","html_url":"https://github.com/getdnsapi/getdns-python-bindings/issues/28","id":89049244,"number":28,"title":"request of TLSA record fails on a new context for some nameservers unless A record requested first","user":{"login":"simsong","id":1594284,"avatar_url":"https://avatars.githubusercontent.com/u/1594284?v=3","gravatar_id":"","url":"https://api.github.com/users/simsong","html_url":"https://github.com/simsong","followers_url":"https://api.github.com/users/simsong/followers","following_url":"https://api.github.com/users/simsong/following{/other_user}","gists_url":"https://api.github.com/users/simsong/gists{/gist_id}","starred_url":"https://api.github.com/users/simsong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simsong/subscriptions","organizations_url":"https://api.github.com/users/simsong/orgs","repos_url":"https://api.github.com/users/simsong/repos","events_url":"https://api.github.com/users/simsong/events{/privacy}","received_events_url":"https://api.github.com/users/simsong/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-06-17T15:28:15Z","updated_at":"2015-06-17T19:05:58Z","closed_at":null,"body":"For reasons that I do not understand, attempting to fetch a TLSA record on the host `_443._tcp.001.tlsa.good.test.had-pilot.biz` fails unless an A record is requested first.\r\n\r\nThat is, this code fails with a timeout and returns a NoneType:\r\n\r\n```\r\nimport getdns\r\nextensions = {\"dnssec_return_validation_chain\" : getdns.EXTENSION_TRUE}\r\nctx = getdns.Context()\r\n\r\nhostname = \"_443._tcp.001.tlsa.good.test.had-pilot.biz\"\r\nresults = ctx.general(name=hostname,request_type=getdns.RRTYPE_TLSA,extensions=extensions)\r\nprint(results)\r\n```\r\n\r\nBut this code works fine:\r\n```\r\nimport getdns\r\nextensions = {\"dnssec_return_validation_chain\" : getdns.EXTENSION_TRUE}\r\nctx = getdns.Context()\r\n\r\nhostname = \"_443._tcp.001.tlsa.good.test.had-pilot.biz\"\r\nresults = ctx.general(name=hostname,request_type=getdns.RRTYPE_A,extensions=extensions)\r\nresults = ctx.general(name=hostname,request_type=getdns.RRTYPE_TLSA,extensions=extensions)\r\nprint(results)\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/getdnsapi/getdns-python-bindings/issues/comments/112915753","html_url":"https://github.com/getdnsapi/getdns-python-bindings/issues/28#issuecomment-112915753","issue_url":"https://api.github.com/repos/getdnsapi/getdns-python-bindings/issues/28","id":112915753,"user":{"login":"simsong","id":1594284,"avatar_url":"https://avatars.githubusercontent.com/u/1594284?v=3","gravatar_id":"","url":"https://api.github.com/users/simsong","html_url":"https://github.com/simsong","followers_url":"https://api.github.com/users/simsong/followers","following_url":"https://api.github.com/users/simsong/following{/other_user}","gists_url":"https://api.github.com/users/simsong/gists{/gist_id}","starred_url":"https://api.github.com/users/simsong/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/simsong/subscriptions","organizations_url":"https://api.github.com/users/simsong/orgs","repos_url":"https://api.github.com/users/simsong/repos","events_url":"https://api.github.com/users/simsong/events{/privacy}","received_events_url":"https://api.github.com/users/simsong/received_events","type":"User","site_admin":false},"created_at":"2015-06-17T19:05:58Z","updated_at":"2015-06-17T19:05:58Z","body":"Yes, but there is a TLSA record. It reliably comes when an A Request is done on the same context first, and not if the TLSA query is done first. Is that proper?\n\nSent from my iPhone\n\n> On Jun 17, 2015, at 12:55 PM, Melinda Shore <notifications@github.com> wrote:\n> \n> This is expected behavior when no records are returned. If the query is correctly formed the api returns successfully. If all you're interested in is the addresses, you can look at Result().just_address_answers - if no A or AAAA record is returned it will have length 0.\n> \n> —\n> Reply to this email directly or view it on GitHub.\n> \n"}}