wondertrader / wtpy

wtpy是基于wondertrader为底层的针对python的子框架
MIT License
888 stars 250 forks source link

demo里面cta_allday运行错误 Segmentation fault (core dumped) #137

Open hahau6 opened 7 months ago

hahau6 commented 7 months ago

运行环境 ubuntu20.04, wtpy 0.9.9.3 在 ubuntu18.04 下重新编译了环境,也不行,同样错误

先启动了datakit_allday,然后启动了cta_allday,

(wt) nlp@wt:~/code/demos/cta_allday$ python run.py [02.11 13:26:37 - info ] Callbacks of Extented Parser registration done [02.11 13:26:37 - info ] Callbacks of Extented Executer registration done [02.11 13:26:37 - info ] WonderTrader CTA production framework initialzied, version: UNIX v0.9.9 Build@Dec 31 2023 22:48:20 [02.11 13:26:37 - info ] Extended Executer created [02.11 13:26:37 - info ] Trading sessions loaded [02.11 13:26:37 - debug] Commodity OKEX.BTC-USDT has been automatically added [02.11 13:26:37 - info ] Contracts configuration file ./common/okex_tickers.json loaded, 1 exchanges [02.11 13:26:37 - info ] Trading environment initialized, engine name: CTA [02.11 13:26:37 - info ] Running mode: Production [02.11 13:26:37 - debug] 0 position info of portfolio loaded [02.11 13:26:37 - warning] RiskMon is not configured, portfilio fund will be updated every 5s [02.11 13:26:37 - info ] Engine task poolsize is 0 [02.11 13:26:37 - info ] Resampled bars will be aligned by section: no [02.11 13:26:37 - info ] Force to cache bars: yes [02.11 13:26:37 - info ] WtDataReaderAD initialized, root data folder is ../AD_Data/ [02.11 13:26:37 - info ] Data manager initialized [02.11 13:26:37 - info ] Action policies initialized [02.11 13:26:37 - info ] Reading parser config from tdparsers.yaml... [02.11 13:26:37 - info ] [parser1] Parser module /home/nlp/anaconda3/envs/wt/lib/python3.9/site-packages/wtpy/wrapper/linux/parsers/libParserUDP.so loaded [02.11 13:26:37 - info ] [parser1] Parser initialzied, check_time: false [02.11 13:26:37 - info ] 1 parsers loaded [02.11 13:26:37 - info ] 1 parsers started [02.11 13:26:37 - info ] 0 trading channels started [02.11 13:26:37 - info ] CtaTicker will drive engine with session ALLDAY [02.11 13:26:37 - info ] Trading date confirmed: 20240211 [02.11 13:26:37 - info ] 0 conditions recovered, setup time: 0 [02.11 13:26:37 - info ] Market data subscribed: xxx [02.11 13:26:37 - debug] Main KBars confirmed: xxx #m1 [02.11 13:26:37 - debug] min1 db of xxx opened [02.11 13:26:37 - debug] 6 min1 bars of xxx loaded to cache 3402111313 [02.11 13:26:37 - debug] min1 bars of xxx updated to 3402111313 Segmentation fault (core dumped)

运行环境 ubuntu20.04, wtpy 0.9.9.3

在 ubuntu18.04 下重新编译了环境,也不行,同样错误

hahau6 commented 7 months ago

怀疑datakit_allday 和 cta_allday 共享了ad_data目录,写入数据的原因。分开两个目录,还是有错误。 通常datakit_allday正常,错误发生在cta_allday 部分,写入数据的刹那。 image

hahau6 commented 7 months ago

win10环境下也有问题,wtpy 0.993

image

copycodetest commented 1 month ago

win10环境下也有问题,wtpy 0.993

image

你好,这个问题解决了吗?我也遇到这个问题了