[issue34110] cPickle may raise AttributeError when loading concurrently in threads

2018-07-13 Thread Guoqiang Zhang
Change by Guoqiang Zhang : -- keywords: +patch pull_requests: +7812 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue34110> ___ ___ Py

[issue34110] cPickle may raise AttributeError when loading concurrently in threads

2018-07-13 Thread Guoqiang Zhang
New submission from Guoqiang Zhang : If two threads use cPickle to load objects simultaneously, one thread may raise an AttributeError. This problem is caused by the partially loaded module. To reproduce, create a file 'foo.py': import time time.sleep(0.1) class foo(): pas