Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
self._key = key
def __repr__(self):
return "{}(masters={}, key='{}')".format(
self.__class__.__name__,
list(self._masters),
self._key,
)
def __str__(self):
return "masters={}, key='{}'".format(list(self._masters), self._key)
class QuorumNotAchieved(PrimitiveError, RuntimeError):
...
class TooManyExtensions(PrimitiveError, RuntimeError):
...
class ReleaseUnlockedLock(PrimitiveError, RuntimeError):
...
return "{}(masters={}, key='{}')".format(
self.__class__.__name__,
list(self._masters),
self._key,
)
def __str__(self):
return "masters={}, key='{}'".format(list(self._masters), self._key)
class QuorumNotAchieved(PrimitiveError, RuntimeError):
...
class TooManyExtensions(PrimitiveError, RuntimeError):
...
class ReleaseUnlockedLock(PrimitiveError, RuntimeError):
...
def __init__(self, masters, key):
super().__init__()
self._masters = masters
self._key = key
def __repr__(self):
return "{}(masters={}, key='{}')".format(
self.__class__.__name__,
list(self._masters),
self._key,
)
def __str__(self):
return "masters={}, key='{}'".format(list(self._masters), self._key)
class QuorumNotAchieved(PrimitiveError, RuntimeError):
...
class TooManyExtensions(PrimitiveError, RuntimeError):
...
class ReleaseUnlockedLock(PrimitiveError, RuntimeError):
...