noflo / noflo-ui

NoFlo Development Environment
https://app.flowhub.io
MIT License
767 stars 173 forks source link

weird error messages from runtime? #440

Closed ensonic closed 9 years ago

ensonic commented 9 years ago

Can we do better here? What is actually wrong? What am I supposed to do to fix it?

screenshot from 2015-02-06 15 14 56

ComFreek commented 9 years ago

:+1: The biggest problem in my opinion is that the errors are not logged in the browser's console. Therefore, neither stack traces nor file names are shown!

Maybe it would also be useful to let the 'normal user' (!= programmer) know that it is the component's fault (and not noflo-ui's fault), so that the author of a specific component should ideally be contacted.

ensonic commented 9 years ago

It seems these come from graph loading and inturn the root issue is that the components are not queried. When this happens the component list on the left only has the items listed that are part of the graph. When I create a new project the errors don't show up, but I still get zero components for that runtime in the UI, I'll get components for other runtimes and I can list the components in this runtime on the target using noflo list.

ensonic commented 9 years ago

The green lines should be what the editor sends to the runtime, right? e.g. ''' {"protocol":"component","command":"list"} ''' And the white ones the reply? ''' {"protocol":"component","command":"component","payload":{"name":"Graph","description":"","subgraph":true,"icon":"sitemap","inPorts":[{"id":"graph","type":"all","required":true,"addressable":false,"description":"NoFlo graph definition to be used with the subgraph component"}],"outPorts":[]}} ''' Shouldn't that start sending the components? What could it cause to not do that? Please.

screenshot from 2015-02-06 19 09 59

ensonic commented 9 years ago

Mystery solved. I switched to use PROJECT_HOME (see https://github.com/noflo/noflo-nodejs/blob/master/index.js#L36-37) to be able to move my flowhub.json out of the runtime package directory. This also caused nodejs to use PROJECT_HOME to for component loading :/