facebook

error on execution path (Error: Cannot find module)

  1. MyEclipse IDE
  2.  > 
  3. Installation, Configuration & Updates
Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #621814 Reply

    leoschuler
    Participant

    I have a fresh install of eclipse and Codemix 3
    when I try to run a node.js file, I am getting the following error:

    module.js:550
        throw err;
        ^
    
    Error: Cannot find module 'C:\C:\Users\LEONARDOSchuler\eclipse\javascript\eclipse\plugins\org.eclipse.wildwebdeveloper_0.3.0.201906060852\language-servers\node_modules\node-debug2\out\src\nodeDebug.js'
        at Function.Module._resolveFilename (module.js:548:15)
        at Function.Module._load (module.js:475:25)
        at Function.Module.runMain (module.js:694:10)
        at startup (bootstrap_node.js:204:16)
        at bootstrap_node.js:625:3
    

    the issue is clearly on the path, you can see it is trying to reach C:\C:\..., but I have no idea where to go to fix it

    #621823 Reply

    Brian Fernandes
    Moderator

    Leo,

    I can see wildwebdeveloper in the error string which could mean you are trying to run node program with tools outside what CodeMix provides.

    Before we investigate further, could you please tell us exactly how you are running the Node.js file? Screenshots of the configuration / wizard would help as well.

    #621836 Reply

    leoschuler
    Participant

    I am right clicking the file and choosing Run As -> Node Program (option 4)
    the screenshot that I provided shows the available options, I have tried to run option 3 (Node:Codemix) and the launching process seems to hang, or it is taking a lot of time.

    Attachments:
    You must be logged in to view attached files.
    #621840 Reply

    Brian Fernandes
    Moderator

    Leo,

    Thank you for the screenshot – that helps.
    1) Option #4 is not a CodeMix option feature, please use option #3 (Node::CodeMix) to launch.
    2) What sort of application is this – if, for example, it’s an express application, the the launch would not really “terminate” but set up a Server, typically at localhost:3000. Can you open your Console view (not the Terminal view) and see if there is some output there?
    3) Do you know what commands you need to launch your application from the command line? What is the command – does the application launch successfully you use that command in Terminal+?

    Thanks!

    #621843 Reply

    leoschuler
    Participant

    it is a simple code, that runs from the command line, the purpose is to run a batch program. if I run node app from the windows command line the code will be executed as expected – it will login into a website and download a page. I use the console.log to keep track of the actions the code is doing.

    #621857 Reply

    Brian Fernandes
    Moderator

    Leo,

    In this case the Node::CodeMix launch should be working fine, did you check the Console view for output? While it normally opens automatically, you can use Window > Show View > Console and from the Console’s menu, choose the “Debug Console” and you should see your Node application running.

    If the launch is still not working, you can always open Terminal+ from within CodeMix, select your project and execute node app in that instead, without having to use an external command line.

    #621909 Reply

    leoschuler
    Participant

    it worked fine, thanks

    either running the command directly into the terminal or right clicking the file and choosing to run as node:Codemix.
    I saw the execution logs in the terminal window. not sure what I was doing wrong, the important thing is that it is working.

    Thank you

Viewing 7 posts - 1 through 7 (of 7 total)
Reply To: error on execution path (Error: Cannot find module)

You must be logged in to post in the forum log in