MCPcopy Create free account
hub / github.com/Boris-code/feapder / wapper

Function wapper

feapder/db/mysqldb.py:26–37  ·  view source on GitHub ↗
(*args, **kwargs)

Source from the content-addressed store, hash-verified

24
25def auto_retry(func):
26 def wapper(*args, **kwargs):
27 for i in range(3):
28 try:
29 return func(*args, **kwargs)
30 except (err.InterfaceError, err.OperationalError) as e:
31 log.error(
32 """
33 error:%s
34 sql: %s
35 """
36 % (e, kwargs.get("sql") or args[1])
37 )
38
39 return wapper
40

Callers

nothing calls this directly

Calls 2

errorMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected