{"action":"opened","issue":{"url":"https://api.github.com/repos/FINRAOS/karma-msl/issues/10","labels_url":"https://api.github.com/repos/FINRAOS/karma-msl/issues/10/labels{/name}","comments_url":"https://api.github.com/repos/FINRAOS/karma-msl/issues/10/comments","events_url":"https://api.github.com/repos/FINRAOS/karma-msl/issues/10/events","html_url":"https://github.com/FINRAOS/karma-msl/issues/10","id":57090474,"number":10,"title":"incorrect path to msl-server/web-server","user":{"login":"ilinkuo","id":1105240,"avatar_url":"https://avatars.githubusercontent.com/u/1105240?v=3","gravatar_id":"","url":"https://api.github.com/users/ilinkuo","html_url":"https://github.com/ilinkuo","followers_url":"https://api.github.com/users/ilinkuo/followers","following_url":"https://api.github.com/users/ilinkuo/following{/other_user}","gists_url":"https://api.github.com/users/ilinkuo/gists{/gist_id}","starred_url":"https://api.github.com/users/ilinkuo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ilinkuo/subscriptions","organizations_url":"https://api.github.com/users/ilinkuo/orgs","repos_url":"https://api.github.com/users/ilinkuo/repos","events_url":"https://api.github.com/users/ilinkuo/events{/privacy}","received_events_url":"https://api.github.com/users/ilinkuo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-02-09T21:12:12Z","updated_at":"2015-02-09T21:12:12Z","closed_at":null,"body":"in https://github.com/FINRAOS/karma-msl/blob/master/lib/index.js, there is a line:\r\n\r\n    require('../node_modules/msl-server/web-server');\r\n\r\nThis path is wrong for the DIVER project -- it should be `'../node_modules/msl-server/web-server'`. As a result, there will be a \"node_modules/msl-server/web-server\" not found message the first time you try to run karma. Others have reported that uninstalling and reinstalling modules fixes the problem, but this is the root cause (I don't know how reinstallling fixes this).\r\n\r\nThe current code seems very dependent on whether modules are installed locally or globally. That's a bad idea. If the web-server configuration is project-specific and not generic, then it should be separate, not part of the module itself, and its location passed in as a parameter. Also, referencing a local module should be done according to http://www.bennadel.com/blog/2169-where-does-node-js-and-require-look-for-modules.htm (I haven't tried this myself)."}}