赞
踩
解决方案:
# auto_commit = not getattr(threading.currentThread(), 'testing', False) #阙辉注释
auto_commit = not getattr(threading.current_thread(), 'testing', False) #阙辉新增