3 œäL]Bã@s˜ddlmZmZmZGdd„deƒZGdd„deƒZGdd„deeƒZGdd „d eeƒZGd d „d e eƒZ Gd d „d e eƒZ Gdd„deƒZ dd„Z dS)é)Úabsolute_importÚdivisionÚprint_functionc@seZdZdZdS)Ú CryptoErrorz4 Base exception for all nacl related errors N)Ú__name__Ú __module__Ú __qualname__Ú__doc__©r r ú3/tmp/pip-install-wfra5znf/pynacl/nacl/exceptions.pyrsrc@seZdZdZdS)ÚBadSignatureErrorzD Raised when the signature was forged or otherwise corrupt. N)rrrr r r r r r sr c@s eZdZdS)Ú RuntimeErrorN)rrrr r r r r sr c@s eZdZdS)ÚAssertionErrorN)rrrr r r r r"src@s eZdZdS)Ú TypeErrorN)rrrr r r r r&src@s eZdZdS)Ú ValueErrorN)rrrr r r r r*src@s eZdZdS)ÚInvalidkeyErrorN)rrrr r r r r.srcOsFd}|jdtƒ}|r.t|jt|jƒdƒƒƒ‚|dkr:dS||Ž‚dS)a„ Return if a condition is true, otherwise raise a caller-configurable :py:class:`Exception` :param bool cond: the condition to be checked :param sequence args: the arguments to be passed to the exception's constructor The only accepted named parameter is `raising` used to configure the exception to be raised if `cond` is not `True` z8check_condition() got an unexpected keyword argument {0}ÚraisingrTN)ÚpoprrÚformatÚreprÚpopitem)ZcondÚargsÚkwdsZ _CHK_UNEXPrr r r Úensure2s  rN) Ú __future__rrrÚ Exceptionrr r rrrrrr r r r Ús