Giter VIP home page Giter VIP logo

nodequant's People

Contributors

dependabot[bot] avatar kaienonline avatar zhangshuiyong avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nodequant's Issues

订阅行情

遇到一个订阅行情,没收到推送的问题

订阅行情只收到一条推送

我用的是方正期货的接口,看穿式监管生产版本,6.3.15
https://www.founderfu.com/fzzqqh_2019/technology_407.html

可以正常登录交易端口和行情端口。
也可以正常拿到所有合约,但是不管我订阅所有合约还是只订阅一条合约,都只能收到一条推送,之后就收不到了。

如果再次订阅,又会收到一条,并不是持续不断的收到推送。

不知道哪位大佬能帮我看一下这个问题?

NodeQuant.node源码有吗?

node 8下面加载NodeQuant.node失败了,不知道是不是nodejs版本问题

> [email protected] start E:\nodequant\nodequant
> node ./bin/www

CtpClient Node Addon Path:./CTP/win32/x64/NodeQuant.node
module.js:653
  return process.dlopen(module, path._makeLong(filename));
                 ^

Error: The specified procedure could not be found.
\\?\E:\nodequant\nodequant\model\client\CTP\win32\x64\NodeQuant.node
    at Object.Module._extensions..node (module.js:653:18)
    at Module.load (module.js:545:32)
    at tryModuleLoad (module.js:508:12)
    at Function.Module._load (module.js:500:3)
    at Module.require (module.js:568:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (E:\nodequant\nodequant\model\client\CTPClient.js:10:10)
    at Module._compile (module.js:624:30)
    at Object.Module._extensions..js (module.js:635:10)
    at Module.load (module.js:545:32)

再来几点建议

a.聚焦于Feed/Broker,与backtest/Strategy等模块分离开来
将Feed的数据通过消息队列(NATS/ZeroQM/...)发送出去,再进入到backtest/Strategy模块中去
https://github.com/nats-io/node-nats

b.尽量借鉴gekko/zenbot等基于NodeJS的交易平台,并进行改造

CTP Client is undefine.....

CtpClient is undefine!!!CtpClient Only Support Windows Node.js-v8.9.1-32bit/Windows Node.js-v8.9.1-64bit/Linux x64 Node.jsv8.9.1
SgitClient is undefine!!!SgitClient Only Support Windows Node.js-v8.9.1-32bit/Linux x64 Node.js-v8.9.1

NodeQuant <<<<<<<<<<
Date :下午4:50:22

大佬,我是在MAC 搭建了这套环境,目前已经运行不报错了,但是启动的时候CTP Client is undefine 是因为 我的操作系统问题吗?

出现错误来源CTP ,Msg:Market Front Response Error. ErrorId:77,ErrorMsg:undefined

可以正常登陆,无法获取市场信息,报错代码77.

NodeQuant <<<<<<<<<<
Date :00:52:46
2018-4-27 00:52:46,信息来源MainEngine ,Msg:MainEngine Start
CtpClient Created
2018-4-27 00:52:46,信息来源CTP ,Msg:Trade Front connected.--> The Login
docker0: Success
2018-4-27 00:52:46,信息来源CTP ,Msg:Trade Front login request sended. Return:0
2018-4-27 00:52:46,信息来源CTP ,Msg:Market Front connected. --> Then Login
docker0: Success
2018-4-27 00:52:46,信息来源CTP ,Msg:Market Front login request sended. return:0
2018-4-27 00:52:46,信息来源CTP ,Msg:CTP Trade Front login successfully
2018-4-27 00:52:46,信息来源CTP ,Msg:Trade Front confirm settlementInfo request sended. Return:0
2018-4-27 00:52:46,信息来源CTP ,Msg:Market Front login successfully
2018-4-27 00:52:46,信息来源CTP ,Msg:Trade Front confirm settlementInfo successfully. --> Then query all contracts.
2018-4-27 00:52:47,信息来源CTP ,Msg:Trade Front query all contract: Received all contracts.
2018-4-27 00:52:47,信息来源StrategyEngine ,Msg:StrategyEngine Start
2018-4-27 00:52:47,信息来源Demo ,Msg:Demo策略启动成功
出现错误来源CTP ,Msg:Market Front Response Error. ErrorId:77,ErrorMsg:undefined

再一次开源建议

兄弟 读了你的代码,发觉你的js不是很熟练,引擎里的逻辑也有不少可以优化的地方,何不开源出ctp addon的源码,大家一起群策群力,共同维护好这个项目呢?我的软肋在于不会封装ctp addon,但相对精于js和交易,有10年前端经验和四年交易经验,想与你一起做这个项目,但苦于不开源核心代码,真的是不敢用。兄弟考虑考虑。

提一些小建议

  1. 建议添加 eslint , editorconfig 等代码风格 config , 比较方便其他人提交代码
  2. 可以开一个 slack group 吗?感觉在 qq 群不能贴代码,slack 或者 gitter 比较适合
  3. 看到很多变量放到了 global 变量里,其实是不是应该直接新建一个单例暴露出来会比较好
  4. 感觉如果把接收的逻辑分离出来会比较好,一个是可以避免策略逻辑复杂阻塞 tick 行情的推送,一个是可以支持回测。

Error: %1 is not a valid Win32 application.

运行时遇到问题:
module.js:602
return process.dlopen(module, path._makeLong(filename));
^

Error: %1 is not a valid Win32 application.
\?\C:\my\nodequant\nodequant\model\client\CTP\NodeQuant.node
at Object.Module._extensions..node (module.js:602:18)
at Module.load (module.js:507:32)
at tryModuleLoad (module.js:470:12)
at Function.Module._load (module.js:462:3)
at Function.Module.runMain (module.js:609:10)
at startup (bootstrap_node.js:158:16)
at bootstrap_node.js:598:3

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.