zenbot | Zenbot is a command-line cryptocurrency trading bot | Cryptocurrency library
kandi X-RAY | zenbot Summary
kandi X-RAY | zenbot Summary
Zenbot is a command-line cryptocurrency trading bot using Node.js and MongoDB. It features:.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of zenbot
zenbot Key Features
zenbot Examples and Code Snippets
Community Discussions
Trending Discussions on zenbot
QUESTION
- Have I written custom code (as opposed to using zenbot vanilla): I have added a strategy and lib files. The strategy uses the lib files to make a pull from the Twitter API and calculate the sentiment of it.
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 16.04
- Zenbot version (commit ref, or version): v4.1.0
- Zenbot branch:unstable
- NodeJS version:v8.11.2
- Python version (when using a python script): python 2.7.12, 3.5.2
- Exact command to reproduce (include everything): ./zenbot.sh trade --paper --strategy sentiment_strat --days 2 --period=10m
- Did I make any changes to conf-sample.js?: No -**Extra libraries used - twitter npm - v1.7.1, vader-sentiment -v1.1.3
The issue is that once the twitter API pull is made the Zenbot will keep printing the same BTC value. It doesn't seem to exit past the onPeriod() function in the strategy. Having the support of pulling from Twitter is a feature request because this would allow users to perform sentiment analysis or perform other types of analysis to make trades. I am close to making it work but I'm stuck on why this is happening. I'm assuming it has something to do with the fact that I'm using an async function - I have to do this because if I don't wait for the return value, the sentiment will be calculated on an undefined value.
I have placed a console.log() in the onPeriod() function after I call main() but as you see from the errorlog.txt, it doesn't get to that point - it is stuck inside main() even though main() has completed and the determination of whether to hold, buy or sell has been performed - See lines 20, 21, 22 (Line 23 is the repeating output of the same BTC price until I exited the process.) errorlog.txt
After running the debugger and seeing that it endlessly loops inside async_hooks.js and net.js - what I found was that the onPeriod() function is called inside an async.queue(). Is having an async call inside another async call a problem? Or is it something else?
Source code / Error logsfile location: zenbot/extensions/strategy/sentiment_strat/strategy.js
...ANSWER
Answered 2018-Sep-16 at 15:22Turns out it was an issue with not including a particular flag. Have to include --minimum_period as a flag.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install zenbot
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page