From fd830f71579f8337d0f9a0c3c40e7b5683957cc4 Mon Sep 17 00:00:00 2001 From: Brian Wellington Date: Wed, 13 Oct 2021 16:31:03 -0700 Subject: [PATCH] Improve dns.message.make_query() docs. Update the docs to match the code. Specifically, the docs implied that EDNS was only enabled if use_edns was set, while the code would enable EDNS if any parameter that required EDNS was set and use_edns was not set. --- dns/message.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dns/message.py b/dns/message.py index 6fa90ca5..baa1116d 100644 --- a/dns/message.py +++ b/dns/message.py @@ -1400,7 +1400,9 @@ def make_query(qname, rdtype, rdclass=dns.rdataclass.IN, use_edns=None, is class IN. *use_edns*, an ``int``, ``bool`` or ``None``. The EDNS level to use; the - default is None (no EDNS). + default is ``None``. If ``None``, EDNS will be enabled only if other + parameters (*ednsflags*, *payload*, *request_payload*, or *options*) are + set. See the description of dns.message.Message.use_edns() for the possible values for use_edns and their meanings. -- 2.47.3