Skip to content

Commit 956726e

Browse files
committed
[Mod] 补充文档和安装脚本
1 parent 8d431a3 commit 956726e

File tree

4 files changed

+70
-5
lines changed

4 files changed

+70
-5
lines changed

README.md

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,32 @@
1-
# vnpy_websocket
1+
# vn.py框架的Websocket API客户端
2+
3+
<p align="center">
4+
<img src ="https://vnpy.oss-cn-shanghai.aliyuncs.com/vnpy-logo.png"/>
5+
</p>
6+
7+
<p align="center">
8+
<img src ="https://img.shields.io/badge/version-1.0.0-blueviolet.svg"/>
9+
<img src ="https://img.shields.io/badge/platform-windows|linux|macos-yellow.svg"/>
10+
<img src ="https://img.shields.io/badge/python-3.7-blue.svg" />
11+
<img src ="https://img.shields.io/github/license/vnpy/vnpy.svg?color=orange"/>
12+
</p>
13+
14+
## 说明
15+
16+
基于asyncio和aiohttp开发的协程异步Websocket API客户端,用于开发高性能的数字货币交易接口。
17+
18+
## 安装
19+
20+
安装需要基于2.2.0版本以上的[VN Studio](https://www.vnpy.com)
21+
22+
直接使用pip命令:
23+
24+
```
25+
pip install vnpy_websocket
26+
```
27+
28+
下载解压后在cmd中运行
29+
30+
```
31+
python setup.py install
32+
```

setup.cfg

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
[metadata]
2+
name = vnpy_websocket
3+
version = 1.0.0
4+
url = https://www.vnpy.com
5+
license = MIT
6+
author = Xiaoyou Chen
7+
author_email = xiaoyou.chen@mail.vnpy.com
8+
description = Websocket API client for vn.py quant trading framework.
9+
long_description = file: README.md
10+
long_description_content_type = text/markdown
11+
keywords =
12+
quant
13+
quantitative
14+
investment
15+
trading
16+
algotrading
17+
classifiers =
18+
Development Status :: 5 - Production/Stable
19+
Operating System :: OS Independent
20+
Programming Language :: Python :: 3
21+
Programming Language :: Python :: 3.7
22+
Programming Language :: Python :: 3.8
23+
Programming Language :: Python :: 3.9
24+
Programming Language :: Python :: 3.10
25+
Topic :: Office/Business :: Financial :: Investment
26+
Programming Language :: Python :: Implementation :: CPython
27+
License :: OSI Approved :: MIT License
28+
Natural Language :: Chinese (Simplified)
29+
30+
[options]
31+
packages = find:
32+
zip_safe = False
33+
install_requires =
34+
aiohttp

setup.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
from setuptools import setup
2+
3+
4+
setup()

vnpy_websocket/websocket_client.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -146,15 +146,11 @@ async def _run(self):
146146
"""
147147
在事件循环中运行的主协程
148148
"""
149-
print(1)
150-
print(self._host)
151-
print(self._proxy)
152149
self._ws = await self._session.ws_connect(
153150
self._host,
154151
proxy=self._proxy,
155152
verify_ssl=False
156153
)
157-
print(2)
158154

159155
self.on_connected()
160156

0 commit comments

Comments
 (0)