akshare 1.17.75__py3-none-any.whl → 1.17.77__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of akshare might be problematic. Click here for more details.
- akshare/__init__.py +4 -5
- akshare/futures/cons.py +3 -0
- akshare/futures/futures_daily_bar.py +1 -1
- akshare/futures/futures_index_ccidx.py +1 -59
- {akshare-1.17.75.dist-info → akshare-1.17.77.dist-info}/METADATA +1 -1
- {akshare-1.17.75.dist-info → akshare-1.17.77.dist-info}/RECORD +9 -9
- {akshare-1.17.75.dist-info → akshare-1.17.77.dist-info}/WHEEL +0 -0
- {akshare-1.17.75.dist-info → akshare-1.17.77.dist-info}/licenses/LICENSE +0 -0
- {akshare-1.17.75.dist-info → akshare-1.17.77.dist-info}/top_level.txt +0 -0
akshare/__init__.py
CHANGED
|
@@ -3182,9 +3182,11 @@ amac_manager_cancelled_info # 中国证券投资基金业协会-信息公示-诚
|
|
|
3182
3182
|
1.17.73 fix: fix get_receipt interface
|
|
3183
3183
|
1.17.74 fix: fix futures_dce_position_rank interface
|
|
3184
3184
|
1.17.75 fix: fix stock_a_ttm_lyr interface
|
|
3185
|
+
1.17.76 fix: fix futures_index_ccidx interface
|
|
3186
|
+
1.17.77 fix: fix get_dce_daily interface
|
|
3185
3187
|
"""
|
|
3186
3188
|
|
|
3187
|
-
__version__ = "1.17.
|
|
3189
|
+
__version__ = "1.17.77"
|
|
3188
3190
|
__author__ = "AKFamily"
|
|
3189
3191
|
|
|
3190
3192
|
import sys
|
|
@@ -5007,10 +5009,7 @@ from akshare.article.fred_md import fred_md, fred_qd
|
|
|
5007
5009
|
"""
|
|
5008
5010
|
中证商品指数
|
|
5009
5011
|
"""
|
|
5010
|
-
from akshare.futures.futures_index_ccidx import
|
|
5011
|
-
futures_index_min_ccidx,
|
|
5012
|
-
futures_index_ccidx,
|
|
5013
|
-
)
|
|
5012
|
+
from akshare.futures.futures_index_ccidx import futures_index_ccidx
|
|
5014
5013
|
|
|
5015
5014
|
"""
|
|
5016
5015
|
futures_em_spot_stock
|
akshare/futures/cons.py
CHANGED
|
@@ -697,7 +697,7 @@ if __name__ == "__main__":
|
|
|
697
697
|
)
|
|
698
698
|
print(get_futures_daily_df)
|
|
699
699
|
|
|
700
|
-
get_dce_daily_df = get_dce_daily(date="
|
|
700
|
+
get_dce_daily_df = get_dce_daily(date="20251029")
|
|
701
701
|
print(get_dce_daily_df)
|
|
702
702
|
|
|
703
703
|
get_cffex_daily_df = get_cffex_daily(date="20230810")
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# -*- coding:utf-8 -*-
|
|
2
2
|
# !/usr/bin/env python
|
|
3
3
|
"""
|
|
4
|
-
Date: 2025/
|
|
4
|
+
Date: 2025/10/29 15:00
|
|
5
5
|
Desc: 中证商品指数
|
|
6
6
|
http://www.ccidx.com/
|
|
7
7
|
"""
|
|
@@ -54,64 +54,6 @@ def futures_index_ccidx(symbol: str = "中证商品期货指数") -> pd.DataFram
|
|
|
54
54
|
return temp_df
|
|
55
55
|
|
|
56
56
|
|
|
57
|
-
def futures_index_min_ccidx(symbol: str = "中证监控油脂油料期货指数") -> pd.DataFrame:
|
|
58
|
-
"""
|
|
59
|
-
中证商品指数-商品指数-分时数据
|
|
60
|
-
http://www.ccidx.com/index.html
|
|
61
|
-
:param symbol: choice of {"中证商品期货指数", "中证商品期货价格指数", "中证监控油脂油料期货指数", "中证监控软商品期货指数",
|
|
62
|
-
"中证监控能化期货指数", "中证监控钢铁期货指数"}
|
|
63
|
-
:type symbol: str
|
|
64
|
-
:return: 商品指数-分时数据
|
|
65
|
-
:rtype: pandas.DataFrame
|
|
66
|
-
"""
|
|
67
|
-
futures_index_map = {
|
|
68
|
-
"中证商品期货指数": ["100001.CCI", "0"],
|
|
69
|
-
"中证商品期货价格指数": ["000001.CCI", "1"],
|
|
70
|
-
"中证监控油脂油料期货指数": ["606005.CCI", "2"],
|
|
71
|
-
"中证监控软商品期货指数": ["606008.CCI", "3"],
|
|
72
|
-
"中证监控能化期货指数": ["606010.CCI", "4"],
|
|
73
|
-
"中证监控钢铁期货指数": ["606011.CCI", "5"],
|
|
74
|
-
}
|
|
75
|
-
url = "http://www.ccidx.com/cscidx/csciAction/loadTimeData"
|
|
76
|
-
params = {"r": "0.08644997232349438"}
|
|
77
|
-
payload = {
|
|
78
|
-
"indexCode": futures_index_map[symbol][0],
|
|
79
|
-
"indexType": futures_index_map[symbol][1],
|
|
80
|
-
"pointer": "all",
|
|
81
|
-
}
|
|
82
|
-
headers = {
|
|
83
|
-
"Accept": "application/json, text/javascript, */*; q=0.01",
|
|
84
|
-
"Accept-Encoding": "gzip, deflate",
|
|
85
|
-
"Accept-Language": "zh-CN,zh;q=0.9,en;q=0.8",
|
|
86
|
-
"Cache-Control": "no-cache",
|
|
87
|
-
"Content-Length": "44",
|
|
88
|
-
"Connection": "keep-alive",
|
|
89
|
-
"Content-Type": "application/x-www-form-urlencoded; charset=UTF-8",
|
|
90
|
-
"Host": "www.ccidx.com",
|
|
91
|
-
"Origin": "http://www.ccidx.com",
|
|
92
|
-
"Pragma": "no-cache",
|
|
93
|
-
"Proxy-Connection": "keep-alive",
|
|
94
|
-
"Referer": "http://www.ccidx.com/cscidx/quote1",
|
|
95
|
-
"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) "
|
|
96
|
-
"Chrome/92.0.4515.159 Safari/537.36",
|
|
97
|
-
"X-Requested-With": "XMLHttpRequest",
|
|
98
|
-
}
|
|
99
|
-
r = requests.post(url, params=params, data=payload, headers=headers)
|
|
100
|
-
data_json = r.json()
|
|
101
|
-
temp_df = pd.DataFrame(
|
|
102
|
-
[data_json["dataMap"]["axisList"], data_json["dataMap"]["lineList"]]
|
|
103
|
-
).T
|
|
104
|
-
temp_df.columns = [
|
|
105
|
-
"datetime",
|
|
106
|
-
"value",
|
|
107
|
-
]
|
|
108
|
-
temp_df["value"] = pd.to_numeric(temp_df["value"], errors="coerce")
|
|
109
|
-
return temp_df
|
|
110
|
-
|
|
111
|
-
|
|
112
57
|
if __name__ == "__main__":
|
|
113
58
|
futures_index_ccidx_df = futures_index_ccidx(symbol="中证商品期货指数")
|
|
114
59
|
print(futures_index_ccidx_df)
|
|
115
|
-
|
|
116
|
-
futures_index_min_ccidx_df = futures_index_min_ccidx(symbol="中证商品期货指数")
|
|
117
|
-
print(futures_index_min_ccidx_df)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
akshare/__init__.py,sha256=
|
|
1
|
+
akshare/__init__.py,sha256=sfsQVKdz9XQolfZy6q6qZTVaUYrCQK0p6Xdv9Lg9tvQ,199773
|
|
2
2
|
akshare/datasets.py,sha256=rKuRNZrqi6IMsZ9nyvO3Rx02js0tH3zMLjz8HQNAoPQ,963
|
|
3
3
|
akshare/exceptions.py,sha256=WEJjIhSmJ_xXNW6grwV4nufE_cfmmyuhmueVGiN1VAg,878
|
|
4
4
|
akshare/request.py,sha256=HtFFf9MhfEibR-ETWe-1Tts6ELU4VKSqA-ghaXjegQM,4252
|
|
@@ -108,19 +108,19 @@ akshare/fund/fund_scale_em.py,sha256=Fl4ru-j1h99-aEcWZAW6Rd-lvslQ456R0RPdIYPoogE
|
|
|
108
108
|
akshare/fund/fund_scale_sina.py,sha256=A0qIzWBQdE3IGS9-cxO9_FNpuH-BAG5HhPk5KzTFTFc,8167
|
|
109
109
|
akshare/fund/fund_xq.py,sha256=AxMZB-940bNY7-BatVLZiseHNxiWA17hQzTfuxGibPU,11306
|
|
110
110
|
akshare/futures/__init__.py,sha256=RMTf1bT5EOE3ttWpn3hGu1LtUmsVxDoa0W7W0gXHOy8,81
|
|
111
|
-
akshare/futures/cons.py,sha256=
|
|
111
|
+
akshare/futures/cons.py,sha256=nBm_4IvJJNT-suTRP9vtLTHK_uPPmvHVkdFq-oe5qSE,18076
|
|
112
112
|
akshare/futures/cot.py,sha256=hY27LMsSmRvme4ITJdcWAc8N4a7vwNo6M2Gh8jcxz74,57848
|
|
113
113
|
akshare/futures/futures_basis.py,sha256=YB-fOUTCanNZqHNcJXJdFqpCBi9_NYbrTlzx2st5AS0,15710
|
|
114
114
|
akshare/futures/futures_comex_em.py,sha256=NPwOCD6lZUDL4wlGxvbmmJIFkQlW427ERO0vTux13WU,3172
|
|
115
115
|
akshare/futures/futures_comm_ctp.py,sha256=IyVRCUvhLTFzmcUVvlIaYZ1e38ll7AF8ExhgtXKuzrI,1003
|
|
116
116
|
akshare/futures/futures_comm_qihuo.py,sha256=uQfabZ63qME8sTaxUbIUVQBVi8yTaPPDhD7voR9PEx0,10504
|
|
117
117
|
akshare/futures/futures_contract_detail.py,sha256=Glm1x72WBwF4G-f_ZYzHsbNhlQ6Ti1HeF0Rzhx-pfFg,1190
|
|
118
|
-
akshare/futures/futures_daily_bar.py,sha256=
|
|
118
|
+
akshare/futures/futures_daily_bar.py,sha256=LYT9_NmIBoHXtrK_jz0iuOKvfA5xZJ4GvDnxDKm-d9k,25057
|
|
119
119
|
akshare/futures/futures_foreign.py,sha256=2cbMA-eug_jriDFwKZWmA_TbPW2GQAjscpZHBrs287E,2131
|
|
120
120
|
akshare/futures/futures_hf_em.py,sha256=juiJauO7T6YTHXIS--ZDW-Idk73KMOrXgRBi1xEiBqA,8195
|
|
121
121
|
akshare/futures/futures_hist_em.py,sha256=TuHdpcfVxdqoHzg5-JwppLUQgwuaz_LG2UZBlgf73i4,6509
|
|
122
122
|
akshare/futures/futures_hq_sina.py,sha256=HZBAve1yxp1fnwgEy_2CqVoniTXRkt8KI3REt0N0TiY,9575
|
|
123
|
-
akshare/futures/futures_index_ccidx.py,sha256=
|
|
123
|
+
akshare/futures/futures_index_ccidx.py,sha256=4jP0cW_4zPWP1ZIkFSvQAsSxBO39fq5sSlBFUsmu8F8,1988
|
|
124
124
|
akshare/futures/futures_inventory_99.py,sha256=fUsb1ghPcz3KyoAWva_h_oj6EcEuhp_tHtJIO0eLMKI,3424
|
|
125
125
|
akshare/futures/futures_inventory_em.py,sha256=OwgONgg3Tu1WCIADcH6LpahDedAPz0iQcmNJb4ma5Dw,2620
|
|
126
126
|
akshare/futures/futures_news_shmet.py,sha256=1epZ3MwDc-T2n1ie4SSDfvUaBiMpSL0Q_xb2VoZ_llU,2465
|
|
@@ -399,10 +399,10 @@ akshare/utils/func.py,sha256=4cwmXFztU86yJNONJ40KJLvsIEQHBbct4iMm3zT2v30,2315
|
|
|
399
399
|
akshare/utils/multi_decrypt.py,sha256=aWoL2iEPeuXHJg8-n7OtMKixLnIhfzepACgxfrfmQB4,1657
|
|
400
400
|
akshare/utils/token_process.py,sha256=nGtgnZGRprXJkhLXH8mcUH4TgIFwzsTOb0EaEPa0Euo,667
|
|
401
401
|
akshare/utils/tqdm.py,sha256=MuPNwcswkOGjwWQOMWXi9ZvQ_RmW4obCWRj2i7HM7FE,847
|
|
402
|
-
akshare-1.17.
|
|
402
|
+
akshare-1.17.77.dist-info/licenses/LICENSE,sha256=s18q7gS2g1F9-Cnk5eqrJG4OGWSwSxVEMzIuT6HyYNY,1073
|
|
403
403
|
tests/__init__.py,sha256=gNzhlO0UPjFq6Ieb38kaVIODXv4cTDByrdohAZnDYt4,82
|
|
404
404
|
tests/test_func.py,sha256=j1MGYbZI2if2j_LY1S4FLsf4qfq4NwVqD5wmRlv5Log,832
|
|
405
|
-
akshare-1.17.
|
|
406
|
-
akshare-1.17.
|
|
407
|
-
akshare-1.17.
|
|
408
|
-
akshare-1.17.
|
|
405
|
+
akshare-1.17.77.dist-info/METADATA,sha256=oOzZB1YwsCKn419DArNcH04pCCiJwo_ErX62RbNQd_k,12593
|
|
406
|
+
akshare-1.17.77.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
407
|
+
akshare-1.17.77.dist-info/top_level.txt,sha256=jsf9ZzZPmHaISTVumQPsAw7vv7Yv-PdEVW70SMEelQQ,14
|
|
408
|
+
akshare-1.17.77.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|