You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Exception has occurred: RuntimeError (note: full exception trace is shown but execution is paused at: )
An attempt has been made to start a new process before the
current process has finished its bootstrapping phase.
This probably means that you are not using fork to start your
child processes and you have forgotten to use the proper idiom
in the main module:
if __name__ == '__main__':
freeze_support()
...
The "freeze_support()" line can be omitted if the program
is not going to be frozen to produce an executable.
File "D:\finhack\library\astock.py", line 130, in getStockDailyPrice
mytask=pool.submit(AStock.getStockDailyPriceByCode,code=code,where=where,startdate=startdate,enddate=enddate,fq=fq)
File "D:\finhack\library\market.py", line 52, in load_price
df_price=AStock.getStockDailyPrice(fq='no')
File "D:\finhack\command\cmd_test.py", line 26, in
df_price=market.load_price()
File "", line 1, in (Current frame)
RuntimeError:
An attempt has been made to start a new process before the
current process has finished its bootstrapping phase.
This probably means that you are not using fork to start your
child processes and you have forgotten to use the proper idiom
in the main module:
if __name__ == '__main__':
freeze_support()
...
The "freeze_support()" line can be omitted if the program
is not going to be frozen to produce an executable.
The text was updated successfully, but these errors were encountered:
cmd_test.py执行时x=market.get_price("000044.SZ",'20180102')获取不到值,但是df=AStock.getStockDailyPriceByCode('000043.SZ',fq='no')可以获取到值。
运行过程中,会发生错误,在astock.py
在以下行出现多线程的错误
mytask=pool.submit(AStock.getStockDailyPriceByCode,code=code,where=where,startdate=startdate,enddate=enddate,fq=fq)
Exception has occurred: RuntimeError (note: full exception trace is shown but execution is paused at: )
File "D:\finhack\library\astock.py", line 130, in getStockDailyPrice
mytask=pool.submit(AStock.getStockDailyPriceByCode,code=code,where=where,startdate=startdate,enddate=enddate,fq=fq)
File "D:\finhack\library\market.py", line 52, in load_price
df_price=AStock.getStockDailyPrice(fq='no')
File "D:\finhack\command\cmd_test.py", line 26, in
df_price=market.load_price()
File "", line 1, in (Current frame)
RuntimeError:
An attempt has been made to start a new process before the
current process has finished its bootstrapping phase.
The text was updated successfully, but these errors were encountered: