DeviaVir / zenbot

Zenbot is a command-line cryptocurrency trading bot using Node.js and MongoDB.
MIT License
8.22k stars 2.04k forks source link

Localhost site crashes server process on Windows #13

Closed xangma closed 8 years ago

xangma commented 8 years ago

Hi,

After just updating to your v3.0.2 and rebuilding /data/db, everything is working fine (expect still requiring cross-spawn on Windows), but when I go to load the localhost website it gives me this error:

08/14/2016 10:37:14 PM BST [      server] open http://localhost:3013/?secret=dc3d5ed33f476e8e to see a live graph.
D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:48
        if (typeof file === 'undefined') throw new Error('template not found: ' + p);
                                         ^

Error: template not found: home
    at render (D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:48:48)
    at ServerResponse.res.render (D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:70:23)
    at Runner.<anonymous> (D:\zenbot-3.x\plugins\server\controllers\home.js:11:11)
    at Immediate.nextRoute [as _onImmediate] (D:\zenbot-3.x\node_modules\motley\node_modules\middler\node_modules\bladerunner\index.js:51:23)
    at processImmediate [as _immediateCallback] (timers.js:383:17)
 08/14/2016 10:37:14 PM BST [    launcher] cmd `server` exited with code 1, respawning now.
08/14/2016 10:37:17 PM BST [    launcher] cmd `server` booting

I can't figure it out myself sorry, so I thought I'd report it.

carlos8f commented 8 years ago

hmm, looks like my templating library is failing on windows. not surprising, I don't test on windows at all. I recommend running this on a linux docker container or mac instead.

ghostnegotiator commented 8 years ago

Heya, just updated and currently on my mobile phone (SSH FTW!). Bot seems to be running smoothly. Although it would be verry pleasent to have config.js moved to sample-config.js (one for Euro and one for USD). I wilk report back as soon as possible.

There are a few things I am really hoping for like:

Next to that this is some great stuff!

Yours Faithfully, RDash

On Sun, Aug 14, 2016, 23:40 xangma notifications@github.com wrote:

Hi,

After just updating to your v3.0.2 and rebuilding /data/db, everything is working fine (expect still requiring cross-spawn on Windows), but when I go to load the localhost website it gives me this error:

08/14/2016 10:37:14 PM BST [ server] open http://localhost:3013/?secret=dc3d5ed33f476e8e to see a live graph. D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:48 if (typeof file === 'undefined') throw new Error('template not found: ' + p); ^

Error: template not found: home at render (D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:48:48) at ServerResponse.res.render (D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:70:23) at Runner. (D:\zenbot-3.x\plugins\server\controllers\home.js:11:11) at Immediate.nextRoute as _onImmediate at processImmediate as _immediateCallback 08/14/2016 10:37:14 PM BST [ launcher] cmd server exited with code 1, respawning now. 08/14/2016 10:37:17 PM BST [ launcher] cmd server booting

I can't figure it out myself sorry, so I thought I'd report it.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/carlos8f/zenbot/issues/13, or mute the thread https://github.com/notifications/unsubscribe-auth/AHMwQ_V6iiNBi-3ZXVIYNf4M7EaQ1wL0ks5qf4thgaJpZM4Jj_mB .

ghostnegotiator commented 8 years ago

Whoops, replied to the wrong mail :')

On Sun, Aug 14, 2016, 23:49 Daan Montijn anime.machina@gmail.com wrote:

Heya, just updated and currently on my mobile phone (SSH FTW!). Bot seems to be running smoothly. Although it would be verry pleasent to have config.js moved to sample-config.js (one for Euro and one for USD). I wilk report back as soon as possible.

There are a few things I am really hoping for like:

  • BTC-ETH Trading (GDAX)
  • Euro/USD (Seperated configs)
  • Config renamed to sample-eur-config.js. (example)
  • config.js added to .gitignore (saves trouble!)

Next to that this is some great stuff!

Yours Faithfully, RDash

On Sun, Aug 14, 2016, 23:40 xangma notifications@github.com wrote:

Hi,

After just updating to your v3.0.2 and rebuilding /data/db, everything is working fine (expect still requiring cross-spawn on Windows), but when I go to load the localhost website it gives me this error:

08/14/2016 10:37:14 PM BST [ server] open http://localhost:3013/?secret=dc3d5ed33f476e8e to see a live graph. D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:48 if (typeof file === 'undefined') throw new Error('template not found: ' + p); ^

Error: template not found: home at render (D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:48:48) at ServerResponse.res.render (D:\zenbot-3.x\node_modules\motley-templ\node_modules\templ\index.js:70:23) at Runner. (D:\zenbot-3.x\plugins\server\controllers\home.js:11:11) at Immediate.nextRoute as _onImmediate at processImmediate as _immediateCallback 08/14/2016 10:37:14 PM BST [ launcher] cmd server exited with code 1, respawning now. 08/14/2016 10:37:17 PM BST [ launcher] cmd server booting

I can't figure it out myself sorry, so I thought I'd report it.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/carlos8f/zenbot/issues/13, or mute the thread https://github.com/notifications/unsubscribe-auth/AHMwQ_V6iiNBi-3ZXVIYNf4M7EaQ1wL0ks5qf4thgaJpZM4Jj_mB .

ghostnegotiator commented 8 years ago

_http_outgoing.js:399 throw new Error('Can\'t render headers after they are sent to the client'); ^
Error: Can't render headers after they are sent to the client at ServerResponse.OutgoingMessage._renderHeaders (_http_outgoing.js:399:11) at ServerResponse.writeHead (_http_server.js:184:20) at ServerResponse.res.renderStatus (/home/gekko/zenbot/node_modules/templ/index.js:83:13) at Object. (/home/gekko/zenbot/plugins/server/controllers/data.js:17:37) at Immediate. (/home/gekko/zenbot/node_modules/sosa/api.js:15:12) at runCallback (timers.js:570:20) at tryOnImmediate (timers.js:550:5) at processImmediate as _immediateCallback 08/15/2016 12:06:38 AM CEST [ launcher] cmd server exited with code 1, respawning now.

Linux too apparently

carlos8f commented 8 years ago

@RDash21 just published 3.0.3 which should resolve that.

ghostnegotiator commented 8 years ago

Pulled & did not crash when attempting to break it. Great job!

On Mon, Aug 15, 2016, 00:20 Carlos Rodriguez notifications@github.com wrote:

@RDash21 https://github.com/RDash21 just published 3.0.3 which should resolve that.

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/carlos8f/zenbot/issues/13#issuecomment-239701366, or mute the thread https://github.com/notifications/unsubscribe-auth/AHMwQ1m_9YETvT3MRCHAgqvUP_xlO0v4ks5qf5SjgaJpZM4Jj_mB .

xangma commented 8 years ago

@carlos8f Ah that's fair enough. A sell signal didn't execute either when running under Windows so I've not set up a virtual machine to run it on Ubuntu instead.