gangly/datafaker

Can't pickle <class 'sqlalchemy.orm.session.Session'>: it's not the same object as sqlalchemy.orm.session.Session

AlexBdd opened this issue · 1 comments

os system:macos Catalina 10.15.7
python3 version:Python 3.8.5

(base) ➜ Desktop
(base) ➜ Desktop datafaker rdb "mysql+mysqldb://root:123456@10.88.7.93:33060/idss?charset=utf8" tb_users 10 --meta user_meta.txt --outprint
Traceback (most recent call last):
File "/opt/anaconda3/lib/python3.8/site-packages/datafaker/cli.py", line 91, in main
db.do_fake()
File "/opt/anaconda3/lib/python3.8/site-packages/datafaker/utils.py", line 72, in wrapper
ret = func(*args, **kwargs)
File "/opt/anaconda3/lib/python3.8/site-packages/datafaker/dbs/basedb.py", line 99, in do_fake
producer.start()
File "/opt/anaconda3/lib/python3.8/multiprocessing/process.py", line 121, in start
self._popen = self._Popen(self)
File "/opt/anaconda3/lib/python3.8/multiprocessing/context.py", line 224, in _Popen
return _default_context.get_context().Process._Popen(process_obj)
File "/opt/anaconda3/lib/python3.8/multiprocessing/context.py", line 284, in _Popen
return Popen(process_obj)
File "/opt/anaconda3/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 32, in init
super().init(process_obj)
File "/opt/anaconda3/lib/python3.8/multiprocessing/popen_fork.py", line 19, in init
self._launch(process_obj)
File "/opt/anaconda3/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 47, in _launch
reduction.dump(process_obj, fp)
File "/opt/anaconda3/lib/python3.8/multiprocessing/reduction.py", line 60, in dump
ForkingPickler(file, protocol).dump(obj)
_pickle.PicklingError: Can't pickle <class 'sqlalchemy.orm.session.Session'>: it's not the same object as sqlalchemy.orm.session.Session

Can't pickle <class 'sqlalchemy.orm.session.Session'>: it's not the same object as sqlalchemy.orm.session.Session
(base) ➜ Desktop

用python3.7试试呢,3.8没测试