Custom Kraken Exceptions
Module that provides custom exceptions for the python-kraken-sdk
- exception kraken.exceptions.KrakenException(msg: str | dict | None = None, *args: tuple, **kwargs: Dict[str, Any])
Bases:
ExceptionClass that provides custom exceptions for the python-kraken-sdk based on the error messages that can be received from the Kraken Spot and Futures API.
- exception KrakenApiLimitExceededError(*args, **kwargs)
Bases:
ExceptionAPI rate limit exceeded. Please check your rate limits.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenAuthenticationError(*args, **kwargs)
Bases:
ExceptionCredentials are invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenBadRequestError(*args, **kwargs)
Bases:
ExceptionThe request payload is malformed, incorrect or ambiguous.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenCannotOpenPositionError(*args, **kwargs)
Bases:
ExceptionUser/tier is ineligible for margin trading.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenCostMinimumNotMetError(*args, **kwargs)
Bases:
ExceptionCost (price * volume) does not meet costmin.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenDeadlineElapsedError(*args, **kwargs)
Bases:
ExceptionThe request timed out according to the default or specified deadline.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInsufficientAvailableFundsError(*args, **kwargs)
Bases:
ExceptionClient does not have the necessary funds.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInsufficientFundsError(*args, **kwargs)
Bases:
ExceptionClient does not have the necessary funds.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInsufficientMarginError(*args, **kwargs)
Bases:
ExceptionExchange does not have available funds for this margin trade.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidAPIKeyError(*args, **kwargs)
Bases:
ExceptionAn invalid API-Key header was supplied.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidAccountError(*args, **kwargs)
Bases:
ExceptionThe account is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidAmountError(*args, **kwargs)
Bases:
ExceptionThe specified amount is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidArgumentsError(*args, **kwargs)
Bases:
ExceptionThe request payload is malformed, incorrect or ambiguous.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
Bases:
ExceptionIndex pricing is unavailable for stop/profit orders on this pair.
Exception.add_note(note) – add a note to the exception
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidNonceError(*args, **kwargs)
Bases:
ExceptionAn invalid nonce was supplied.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidOrderError(*args, **kwargs)
Bases:
ExceptionOrder is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidPriceError(*args, **kwargs)
Bases:
ExceptionPrice is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidReferenceIdError(*args, **kwargs)
Bases:
ExceptionThe requested referece id is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidSignatureError(*args, **kwargs)
Bases:
ExceptionAn invalid API-Sign header was supplied.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidStakingMethodError(*args, **kwargs)
Bases:
ExceptionThe staking method is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenInvalidUnitError(*args, **kwargs)
Bases:
ExceptionThe specified unit is invalid.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenMarginAllowedExceededError(*args, **kwargs)
Bases:
ExceptionUser has exceeded their margin allowance.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenMarginLevelToLowError(*args, **kwargs)
Bases:
ExceptionClient has insufficient equity or collateral.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenMarginPositionSizeExceededError(*args, **kwargs)
Bases:
ExceptionClient would exceed the maximum position size for this pair.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenMarketInOnlyCancelModeError(*args, **kwargs)
Bases:
ExceptionRequest can’t be made at this time. Please check system status.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenMarketInOnlyPostModeError(*args, **kwargs)
Bases:
ExceptionRequest can’t be made at this time. Please check system status.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenNotFoundError(*args, **kwargs)
Bases:
ExceptionThe resource is not found.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenOrderForEditNotFoundError(*args, **kwargs)
Bases:
ExceptionThe order for edit could not be found.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenOrderLimitsExceededError(*args, **kwargs)
Bases:
ExceptionOrder limits exceeded. Please check your open orders limit.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenOrderMinimumNotMetError(*args, **kwargs)
Bases:
ExceptionOrder size does not meet ordermin.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenPermissionDeniedError(*args, **kwargs)
Bases:
ExceptionAPI key doesn’t have permission to make this request.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenPositionLimitExceeded(*args, **kwargs)
Bases:
ExceptionPosition limit exceeded. Please check your limits.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenRateLimitExceededError(*args, **kwargs)
Bases:
ExceptionAPI rate limit exceeded. Please check your rate limits.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenRequiredArgumentMissingError(*args, **kwargs)
Bases:
ExceptionThe request is missing a required argument.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
Bases:
ExceptionThe matching engine or API is offline.
Exception.add_note(note) – add a note to the exception
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenTemporaryLockoutError(*args, **kwargs)
Bases:
ExceptionThe account was temporary locked out.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenTickSizeInvalidCheckError(*args, **kwargs)
Bases:
ExceptionPrice submitted is not a valid multiple of the pair’s tick_size.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenToManyAddressesError(*args, **kwargs)
Bases:
ExceptionTo many addresses specified.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
Bases:
ExceptionThe requested resource is unavailable.
Exception.add_note(note) – add a note to the exception
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownAssetError(*args, **kwargs)
Bases:
ExceptionThe asset is unknown.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownAssetPairError(*args, **kwargs)
Bases:
ExceptionThe asset pair is unknown.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownMethodError(*args, **kwargs)
Bases:
ExceptionThe endpoint or method is not known.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownOrderError(*args, **kwargs)
Bases:
ExceptionOrder is unknown.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownPositionError(*args, **kwargs)
Bases:
ExceptionPosition is unknown.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownReferenceIdError(*args, **kwargs)
Bases:
ExceptionThe requested referece id is unknown.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception KrakenUnknownWithdrawKeyError(*args, **kwargs)
Bases:
ExceptionThe requested withdrawal key is unknown.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- exception MaxReconnectError(*args, **kwargs)
Bases:
ExceptionTo many reconnect tries.
- add_note()
Exception.add_note(note) – add a note to the exception
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- add_note()
Exception.add_note(note) – add a note to the exception
- get_exception(data: str | List[str]) Any | None
Returns the exception given by name if available
- with_traceback()
Exception.with_traceback(tb) – set self.__traceback__ to tb and return self.
- kraken.exceptions.docstring_message(cls: Any) Any
Decorates an exception to make its docstring its default message.