Skip to content

Commit a31583a

Browse files
committed
Formatting
1 parent 570c623 commit a31583a

10 files changed

Lines changed: 44 additions & 21 deletions

File tree

src/zeep/__init__.py

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,16 @@
1-
from zeep.client import AsyncClient as AsyncClient, CachingClient as CachingClient, Client as Client # noqa
2-
from zeep.plugins import Plugin as Plugin # noqa
3-
from zeep.settings import Settings as Settings # noqa
4-
from zeep.transports import Transport as Transport # noqa
5-
from zeep.xsd.valueobjects import AnyObject as AnyObject # noqa
1+
from zeep.client import AsyncClient, CachingClient, Client
2+
from zeep.plugins import Plugin
3+
from zeep.settings import Settings
4+
from zeep.transports import Transport
5+
from zeep.xsd.valueobjects import AnyObject
66

77
__version__ = "4.1.0"
8+
__all__ = [
9+
"AsyncClient",
10+
"CachingClient",
11+
"Client",
12+
"Plugin",
13+
"Settings",
14+
"Transport",
15+
"AnyObject",
16+
]

src/zeep/loader.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,9 @@ def parse_xml(content: str, transport, base_url=None, settings=None):
6868
)
6969

7070

71-
def load_external(url: typing.Union[typing.IO, str], transport, base_url=None, settings=None):
71+
def load_external(
72+
url: typing.Union[typing.IO, str], transport, base_url=None, settings=None
73+
):
7274
"""Load an external XML document.
7375
7476
:param url:

src/zeep/wsdl/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,6 @@
1313
1414
1515
"""
16-
from zeep.wsdl.wsdl import Document as Document # noqa
16+
from zeep.wsdl.wsdl import Document
17+
18+
__all__ = ["Document"]

src/zeep/wsdl/bindings/__init__.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
1-
from .http import HttpGetBinding as HttpGetBinding, HttpPostBinding as HttpPostBinding # noqa
2-
from .soap import Soap11Binding as Soap11Binding, Soap12Binding as Soap12Binding # noqa
1+
from .http import HttpGetBinding, HttpPostBinding
2+
from .soap import Soap11Binding, Soap12Binding
3+
4+
__all__ = ["HttpGetBinding", "HttpPostBinding", "Soap11Binding", "Soap12Binding"]

src/zeep/wsse/__init__.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1-
from .compose import Compose as Compose # noqa
2-
from .signature import BinarySignature as BinarySignature, MemorySignature as MemorySignature, Signature as Signature # noqa
3-
from .username import UsernameToken as UsernameToken # noqa
1+
from .compose import Compose
2+
from .signature import BinarySignature, MemorySignature, Signature
3+
from .username import UsernameToken
4+
5+
__all__ = [
6+
"Compose",
7+
"BinarySignature",
8+
"MemorySignature",
9+
"Signature",
10+
"UsernameToken",
11+
]

src/zeep/xsd/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@
33
--------
44
55
"""
6-
from zeep.xsd.const import Nil, SkipValue # noqa
6+
from zeep.xsd.const import Nil, SkipValue
77
from zeep.xsd.elements import * # noqa
8-
from zeep.xsd.schema import Schema as Schema # noqa
8+
from zeep.xsd.schema import Schema as Schema
99
from zeep.xsd.types import * # noqa
1010
from zeep.xsd.types.builtins import * # noqa
1111
from zeep.xsd.valueobjects import * # noqa

src/zeep/xsd/types/complex.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
from __future__ import annotations
2+
13
import copy
24
import logging
35
import sys
@@ -41,7 +43,7 @@
4143

4244
__all__ = ["ComplexType"]
4345
# Recursive alias
44-
_ObjectList = typing.List[typing.Union[CompoundValue, None, _ObjectList]]
46+
_ObjectList = typing.List[typing.Union[CompoundValue, None, "_ObjectList"]]
4547

4648

4749
class ComplexType(AnyType):

src/zeep/xsd/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def create_name(self, name):
2727

2828
def max_occurs_iter(max_occurs, items=None):
2929
assert max_occurs is not None
30-
generator = range(0, max_occurs if max_occurs != "unbounded" else 2 ** 31 - 1)
30+
generator = range(0, max_occurs if max_occurs != "unbounded" else 2**31 - 1)
3131

3232
if items is not None:
3333
for i, sub_kwargs in zip(generator, items):

tests/test_client.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@
55

66
from tests.utils import load_xml
77
from zeep import client, xsd
8-
from zeep.wsdl import Document
9-
from zeep.transports import Transport
108
from zeep.exceptions import Error
9+
from zeep.transports import Transport
10+
from zeep.wsdl import Document
1111

1212

1313
def test_bind():

tests/test_wsse_signature.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,7 @@
3333

3434
skip_if_no_xmlsec = pytest.mark.skipif(
3535
sys.platform == "win32", reason="does not run on windows"
36-
) and pytest.mark.skipif(
37-
xmlsec is None, reason="xmlsec library not installed"
38-
)
36+
) and pytest.mark.skipif(xmlsec is None, reason="xmlsec library not installed")
3937

4038

4139
@skip_if_no_xmlsec

0 commit comments

Comments
 (0)