问题描述
在python中deepcopy一个自定义的对象时报错
maximum recursion depth exceeded while calling a Python object
而且在本机运行并不会报错,在服务器上运行才会报错。
解决
参考: https://developer.aliyun.com/article/548660
在代码中加入:
import sys
sys.setrecursionlimit(10000)
在python中deepcopy一个自定义的对象时报错
maximum recursion depth exceeded while calling a Python object
而且在本机运行并不会报错,在服务器上运行才会报错。
参考: https://developer.aliyun.com/article/548660
在代码中加入:
import sys
sys.setrecursionlimit(10000)