-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Error: cb is not a function #2329
Comments
Can you post more logs? With debug turned on. |
That's it - after that Gekko crashes. Debug set to true also doesn't provide any more info. Binance market btw. Other strategy seems to work fine. |
Are there no other logs? Like the gekko logo? Having this means we can see
exactly where gekko crashes.
…On Wed, 18 Jul 2018, 17:54 moodyswing, ***@***.***> wrote:
That's it - after that Gekko crashes. Debug set to true also doesn't
provide any more info. Binance market btw. Other strategy seems to work
fine.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#2329 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA7MD1IIzQyVwYgcIi4jhJKUk7CSdZlxks5uHwXxgaJpZM4VTgwE>
.
|
Well, ok. I'll post the whole log later on today. |
Thanks! Because if it happens during initialisation we can see if it
happens during plugin load, or if not which plugins are loaded.
…On Wed, Jul 18, 2018 at 7:47 PM, moodyswing ***@***.***> wrote:
Well, ok. I'll post whole log later on today.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#2329 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA7MD5inxAJggYxtYfnv-9C9e2qXlNSGks5uHyA7gaJpZM4VTgwE>
.
--
PGP key at keybase.io/mikevanrossum
<https://keybase.io/mikevanrossum/key.asc>
|
If your history has empty data this error occurs. For example, a new coin has 1 hour of market data on binance but you imported 1 day. ( gekko needs at least one day import) |
@salihcirgan Thx, will try it out. Here's the log, debug is set to true:
/ \ / |/ | / |/ | / | /
2018-07-17 22:19:14 (INFO): Setting up Gekko in realtime mode 2018-07-17 22:19:14 (INFO): Setting up: 2018-07-17 22:19:17 (INFO): Usable local data available, trying to match with exchange data.. 2018-07-17 22:19:24 (INFO): Portfolio: 2018-07-17 22:19:24 (INFO): Starting to watch the market: Binance ADX/BNB |
I see this exact problem if DB has null data. Every time DB deletion or if full history is available problem gone. maybe, you have something different. |
@salihcirgan I've just finished importing and running simple test :) It seems to work now. Strange, as I'm pretty sure that db wasn't empty... |
Interesting, I'll have a look at that. Thanks @salihcirgan. |
Another funny thing - thing seemed to be working, but after yet enother crash (logs below) TypeError: cb is not a functionis back again... / \ / |/ | / |/ | / | /
2018-07-18 17:57:17 (INFO): Setting up Gekko in realtime mode 2018-07-18 17:57:17 (INFO): Setting up: 2018-07-18 17:57:20 (INFO): Usable local data available, trying to match with exchange data.. 2018-07-18 17:57:26 (INFO): Portfolio: 2018-07-18 17:57:26 (INFO): Starting to watch the market: Binance ADX/BNB |
I had the same "cb is not a function" error. Tried deleting node_module and npm install -- same error. Restored a backup db -- works. I'm using sqllite as db. |
I get this error anytime I have done an import of data and then try to run a strategy after that requires history. When the DataSticher has to piece together both local and exchange data, it when this is happening 100% for me. I have been trying to dig out the unique functionality that is ran in this scenario to find the issue. |
I'm having the same issue. In the config file, I set candleWriter to false for now to get around this bug. |
Got the same issue, I have deleted the "node_modules" folder then run |
Same problem here but the @crypto49er's solution doesn't work for me :/ |
@GuysmoB Nope only in the current folder that's why you need to it twice, once at the root folder and a second time in the exchange folder. |
@nicolasbonnici, your method doesn't work for me. You didn't do something else ? |
@GuysmoB Nope just deleted both node_modules/ and exchange/node_modules then reinstall all dependencies in both folders. |
Deleting both node_modules folders worked for me, thanks. Wasn't that horrible since it looped in pm2 until it eventually worked, but this is nicer. |
I have this often when a market watcher (UI) is running and i start the tradebot (CLI) for the same pair. After stopping the market watcher it works for me. |
Deleting the node_modules folders and reinstalling them work if you don't use the import process to update the historical data. If you update, you will get the same error. My workaround, which I should have clarify, will not work if you try to use historical data. I think we need a real fix for this, not a workaround. |
@crypto49er
I am unable to reproduce this. Are you running on windows? sqlite? etc.
…On Mon, Aug 27, 2018 at 2:33 AM, Jack Crypto49er ***@***.***> wrote:
Deleting the node_modules folders and reinstalling them work if you don't
use the import process to update the historical data. If you update, you
will get the same error. My workaround, which I should have clarify, will
not work if you try to use historical data. I think we need a real fix for
this, not a workaround.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#2329 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA7MD7nImRLVrT4KwM6RPU0QhIEf6S7Eks5uUuoIgaJpZM4VTgwE>
.
--
PGP key at keybase.io/mikevanrossum
<https://keybase.io/mikevanrossum/key.asc>
|
I'm running on a Mac with sqlite. I believe I am able to replicate this on Linux as well. I will confirm shortly and also provide the exact steps. |
Thanks! Would love to reproduce this.
…On Mon, 27 Aug 2018, 22:36 Jack Crypto49er, ***@***.***> wrote:
@askmike <https://github.com/askmike>
I'm running on a Mac with sqlite. I believe I am able to replicate this on
Linux as well. I will confirm shortly and also provide the exact steps.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2329 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA7MD8aRk1psJrAUnEoUYzXUFP8_ZRqOks5uVAP6gaJpZM4VTgwE>
.
|
Hi, I've the same error, on version 0.6.6 today The strategie is RSI_BULL_BEAR_ADX using 1225 minutes of historic data with all datas neede: I also got before this error : Hellpppp : ) Let me know if you need any other infos to help reproduce it. |
p.s.: @askmike > I can share with you the access to the Instance (SSH) if you want to check |
Here are the steps to replicate this issue:
I know people are running into this error with other exchanges, trade pairs and strategies. I haven't been able to replicate this on command with other trade pairs I suspect because Gekko doesn't try to stitch the local data with data from the exchange. I'm quite certain once it tries to stitch the data together, the historical data get corrupted and the user have to re-download that data set, which is a huge pain (unless they backed it up beforehand). Here's how it looks from Terminal:
|
Thanks a lot to @crypto49er for providing me with steps to reproduce. These kind of issues are impossible for me to fix without being able to reproduce. @bobychain @moodyswing @danielm001 @cstegmann @nicolasbonnici @hiyan I was finally able to fix this! Fix landed in develop for now (see #2482), see here for documentation on running that: https://gekko.wizb.it/docs/installation/updating_gekko.html#Updating-the-develop-branch |
Thanks @askmike. Will try. However, I have not seen this error, since I upgraded node to v10 and rebuild node_modules, for a few weeks now. Will report if I see this error again. |
This error only happened when a few different things all happened at the
same time: when your strategies requires a history, when the history is
available locally but not from the exchange, when that history contained
more than 1 big candle (candleSize) and a few other minor details.
Note that if you see "CB is not a function" that error comes from the node
stream complaining. The actual issue was with Gekko. If you see it again
there is a new/another bug triggering it. Since I am sure this one is now
fixed.
…On Tue, 28 Aug 2018, 17:24 Wei Ken, ***@***.***> wrote:
Thanks @askmike <https://github.com/askmike>. Will try.
However, I have not seen this error, since I upgraded node to v10 and
rebuild node_modules, for a few weeks now.
Will report if I see this error again.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#2329 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AA7MD-TDgNbfd7nHzPeallsUpBnBN0Mdks5uVQw8gaJpZM4VTgwE>
.
|
Thanl you @askmike, trying it now! |
I still have the problem, randomly or at start with the version 0.6.6. Gekko got the error 3 days ago and didn't trade since then, I had to restart manually. |
I have seen other variables that are listed as not a function ("done is not a function"), but not cb. @bobychain, I think you should open a new issue. If you want a quick fix, you can have cb return only if it is a function (if typeof cb == 'function). |
I'm submitting a ...
[X ] bug report
[ ] question about the decisions made in the repository
Action taken (what you did)
Running trader (NEO strategy) via CLI (Gekko 6.2); app reaches setting up market watcher
Expected result (what you hoped would happen)
Running Strategy
Actual result (unexpected outcome)
App crashes:
TypeError: cb is not a function
at afterWrite (_stream_writable.js:464:3)
at _combinedTickCallback (internal/process/next_tick.js:144:20)
at process._tickDomainCallback (internal/process/next_tick.js:218:9)
The text was updated successfully, but these errors were encountered: