MCPcopy
hub / github.com/rholder/retrying / get

Method get

retrying.py:237–249  ·  view source on GitHub ↗

Return the return value of this Attempt instance or raise an Exception. If wrap_exception is true, this Attempt is wrapped inside of a RetryError before being raised.

(self, wrap_exception=False)

Source from the content-addressed store, hash-verified

235 self.has_exception = has_exception
236
237 def get(self, wrap_exception=False):
238 """
239 Return the return value of this Attempt instance or raise an Exception.
240 If wrap_exception is true, this Attempt is wrapped inside of a
241 RetryError before being raised.
242 """
243 if self.has_exception:
244 if wrap_exception:
245 raise RetryError(self)
246 else:
247 six.reraise(self.value[0], self.value[1], self.value[2])
248 else:
249 return self.value
250
251 def __repr__(self):
252 if self.has_exception:

Callers 1

callMethod · 0.95

Calls 1

RetryErrorClass · 0.85

Tested by

no test coverage detected