Skip to content

Commit dddd69c

Browse files
committed
black lint
1 parent 185cc38 commit dddd69c

4 files changed

Lines changed: 16 additions & 3 deletions

File tree

‎dns/message.py‎

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -813,8 +813,15 @@ def set_id(self, id: int):
813813
assert self.tsig is not None
814814
assert self.tsig.rdtype == dns.rdatatype.TSIG
815815
tsig_rdata = cast(dns.rdtypes.ANY.TSIG.TSIG, self.tsig[0])
816-
self.use_tsig(self.keyring, None, tsig_rdata.fudge, id, tsig_rdata.error, tsig_rdata.other,
817-
tsig_rdata.algorithm)
816+
self.use_tsig(
817+
self.keyring,
818+
None,
819+
tsig_rdata.fudge,
820+
id,
821+
tsig_rdata.error,
822+
tsig_rdata.other,
823+
tsig_rdata.algorithm,
824+
)
818825

819826
def set_random_id(self):
820827
"""Assign a newly-generated random query id to the message."""

‎dns/name.py‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,9 +102,11 @@ class PointerChainTooLong(dns.exception.FormError):
102102
class BadLabelType(dns.exception.FormError):
103103
"""The label type in DNS name wire format is unknown."""
104104

105+
105106
class DecompressionForbidden(dns.exception.FormError):
106107
"""A name has a compression pointer but decompression is forbidden."""
107108

109+
108110
class NeedAbsoluteNameOrOrigin(dns.exception.DNSException):
109111
"""An attempt was made to convert a non-absolute name to
110112
wire when there was also a non-absolute (or missing) origin."""
@@ -1177,6 +1179,7 @@ def from_text(
11771179
# Names in all other types will not be compressed by dnspython, and MUST NOT
11781180
# be compressed when decoding wire format.
11791181

1182+
11801183
def from_wire_parser(parser: dns.wirebase.Parser, decompress: bool = True) -> Name:
11811184
"""Convert possibly compressed wire format into a :py:class:`dns.name.Name`.
11821185

‎dns/rdtypes/nsbase.py‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ def from_wire_parser(cls: type[T], rdclass, rdtype, parser, origin=None) -> T:
6161
target = parser.get_name(origin, True)
6262
return cls(rdclass, rdtype, target)
6363

64+
6465
@dns.immutable.immutable
6566
class UncompressedNS(NSBase):
6667
"""Base class for rdata that is like an NS record, but whose name

‎dns/wire.py‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,9 @@
66

77
class Parser(dns.wirebase.Parser):
88

9-
def get_name(self, origin: dns.name.Name | None = None, decompress: bool = False) -> dns.name.Name:
9+
def get_name(
10+
self, origin: dns.name.Name | None = None, decompress: bool = False
11+
) -> dns.name.Name:
1012
name = dns.name.from_wire_parser(self, decompress)
1113
if origin:
1214
name = name.relativize(origin)

0 commit comments

Comments
 (0)