Skip to content

Commit

Permalink
Run black.
Browse files Browse the repository at this point in the history
  • Loading branch information
rohe committed Jul 16, 2020
1 parent 6c09a10 commit 78689b3
Showing 1 changed file with 19 additions and 26 deletions.
45 changes: 19 additions & 26 deletions src/cryptojwt/key_jar.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,14 @@ class KeyJar(object):
""" A keyjar contains a number of KeyBundles sorted by owner/issuer """

def __init__(
self,
ca_certs=None,
verify_ssl=True,
keybundle_cls=KeyBundle,
remove_after=3600,
httpc=None,
httpc_params=None,
storage=None,
self,
ca_certs=None,
verify_ssl=True,
keybundle_cls=KeyBundle,
remove_after=3600,
httpc=None,
httpc_params=None,
storage=None,
):
"""
KeyJar init function
Expand Down Expand Up @@ -386,7 +386,7 @@ def export_jwks(self, private=False, issuer_id="", usage=None):
k.serialize(private)
for k in kb.keys()
if k.inactive_since == 0
and (usage is None or (hasattr(k, "use") and k.use == usage))
and (usage is None or (hasattr(k, "use") and k.use == usage))
]
)
return {"keys": keys}
Expand Down Expand Up @@ -472,14 +472,14 @@ def remove_outdated(self, when=0):

@deprecated_alias(issuer="issuer_id", owner="issuer_id")
def _add_key(
self,
keys,
issuer_id,
use,
key_type="",
kid="",
no_kid_issuer=None,
allow_missing_kid=False,
self,
keys,
issuer_id,
use,
key_type="",
kid="",
no_kid_issuer=None,
allow_missing_kid=False,
):

_issuer = self._get_issuer(issuer_id)
Expand Down Expand Up @@ -705,9 +705,7 @@ def rotate_keys(self, key_conf, kid_template="", issuer_id=""):
# =============================================================================


def build_keyjar(
key_conf, kid_template="", keyjar=None, issuer_id="", storage=None
):
def build_keyjar(key_conf, kid_template="", keyjar=None, issuer_id="", storage=None):
"""
Builds a :py:class:`oidcmsg.key_jar.KeyJar` instance or adds keys to
an existing KeyJar based on a key specification.
Expand Down Expand Up @@ -764,12 +762,7 @@ def build_keyjar(

@deprecated_alias(issuer="issuer_id", owner="issuer_id")
def init_key_jar(
public_path="",
private_path="",
key_defs="",
issuer_id="",
read_only=True,
storage=None,
public_path="", private_path="", key_defs="", issuer_id="", read_only=True, storage=None,
):
"""
A number of cases here:
Expand Down

0 comments on commit 78689b3

Please sign in to comment.