下面的代码,会报TypeError: ‘tuple’ object is not callable
# list = [1,2,3]
# p= Pool(1)
# result_list = []
# for i in range(1):
# result_list.append(p.apply_async(test(listt)))
# p.close()
# p.join()
#
# for result in result_list:
# qc_record_translation_dic, clue_qc_check_dic = result.get()
# print(qc_record_translation_dic)
# print(clue_qc_check_dic)
其实是因为子进程的函数test的调用方式有误,不能将参数直接放在test里,而是需要给到apply_async的args参数里,例如:result_list.append(p.apply_async(test, args=(list,)))