shepherdpp / qteasy

a python-based fast quantitative investment module
BSD 3-Clause "New" or "Revised" License
73 stars 28 forks source link

下载tushare 数据报错 #164

Closed Baili-BL closed 4 months ago

Baili-BL commented 4 months ago

正在下载tushare 数据库就报错了。请您帮我看看。貌似应该是today这边的函数问题。

代码报错描述如下: D:\anaconda\Lib\site-packages\qteasy__init__.py:147: UserWarning: trade calendar is not loaded, some utility functions may not work properly, to download trade calendar, run "qt.refill_data_source(tables='trade_calendar')" warnings.warn(msg) Filling data source db:mysql://localhost@3306/qt_db ... Traceback (most recent call last): File "c:\Users\Administrator\Desktop\wqwq.py", line 4, in qt.refill_data_source(tables='stock_daily', start_date='20230101', end_date='20231231') File "D:\anaconda\Lib\site-packages\qteasy\core.py", line 696, in refill_data_source data_source.refill_local_source(**kwargs) File "D:\anaconda\Lib\site-packages\qteasy\database.py", line 4804, in refill_local_source elif pd.to_datetime('today') >= pd.to_datetime(latest_calendar_date): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: '>=' not supported be

Environment (please complete the following information) / 请提供更多环境信息:

Baili-BL commented 4 months ago

请大佬帮忙解决看一下。谢谢。

shepherdpp commented 4 months ago

您好,请升级到最新版本的qteasy,这个问题已经解决

Jackie PENG | Founder & Maintainer

From: @.> on behalf of Baili @.> Reply-To: shepherdpp/qteasy @.> Date: Tuesday, June 11, 2024 at 11:23 PM To: shepherdpp/qteasy @.> Cc: Subscribed @.***> Subject: Re: [shepherdpp/qteasy] 下载tushare 数据报错 (Issue #164)

请大佬帮忙解决看一下。谢谢。

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you are subscribed to this thread.Message ID: @.***>

Baili-BL commented 4 months ago

感谢大佬,已经解决了。