Tagged: Unable to start server
- This topic has 49 replies, 14 voices, and was last updated 6 years, 3 months ago by support-tony.
-
AuthorPosts
-
steveiapps-ccParticipantThis problem still exists. I’m on the latest release of Webclipse and trying to debug an Angular 4 app running on Node.js 8.2.1 and debugging hangs at 73%.
I’m on MacOS Sierra.
steveiapps-ccParticipantI’m seeing this exact problem using @angular/cli: 1.0.0. What gives???
Brian FernandesModeratorSteve,
Sorry – we seem to have missed your earlier post here as well. Here’s what I’m assuming is happening:
1) Project created using wizards in Angular IDE and the specified version of Node – 8.2.1. Project is created successfully.
2) You’ve added your custom code to the project (i.e. this is not the vanilla project created by the wizard).
3) Select the app in the Servers view and click the Start button. Is the failure at this point – that the webpack build stops at 73%? Sending the contents of the terminal view at this point will help.
4) We also have that explicit action – “debug application in chrome” – is this what sticks at 73%? If yes, and instead of choosing to debug the application, you choose to just open it instead, does the application work fine in your browser?Do let us know exactly what’s happening in your case and we’ll get to the bottom of it. Also, please confirm the version of Weclipse you are on.
Apologies for the inconvenience caused.
Brian FernandesModeratorSteve,
I see you sent in a more detailed note to our support email address. I’ll follow up there. Thanks!
steveiapps-ccParticipantThank you Brian
wodgeParticipantI have the same issue – and it is preventing some critical development at the moment.
Brian – could you please give an update, as the issue still exists?
Warren
Brian FernandesModeratorWarren,
The problem that Steve had was fixed in the CI 8 release of Webclipse. It was specific to Mac Pro machines with two ethernet cards.
If you already have CI 8 (confirm at Window > Preferences > Webclipse) but still see this problem (or you don’t have two Ethernet cards), you’re probably experiencing some other issue.
Just so we’re clear, do you mind restating the problem you are experiencing exactly? Also mention the versions of Node, NPM and Angular CLI you’re using.
sayantansinhaParticipantHi,
I am using Angular IDE 2017 CI 13b plugin on Eclipse Photon running on MacOS 10.12.6. I am getting the same error and my app does not even startup. It is stuck on the below command (shown on terminal) that gets executed on starting the server.<project path>/node_modules/angular-ide/bin/ng serve --port=4200 --live-reload=true --webclipse-launch-id=5631518283988507515
Throws the same error as noted in the original question, I checked my node_modules and angular-ide is installed there
Starting app on Angular CLI Server… has encountered a problem Timed out waiting for server to start. Please ensure you have angular-ide NPM plugin installed in your project. Run npm install –save-dev angular-ide
Refer to below package versions
node: 8.11.3 npm: 5.6.0 @angular/cli: ^6.1.2
I am not able to find the .webclipse directory being referred. Any solutions for this?
- This reply was modified 6 years, 4 months ago by sayantansinha.
- This reply was modified 6 years, 4 months ago by sayantansinha.
support-tonyKeymastersayantansinha,
We’ve been trying to replicate your project environment, though on a later version of Mac OS. So far, unsuccessfully.
Can you confirm the problem, since there have been several problems mentioned in this topic, with the opening post mentioning that the server starts but the server status shows “Starting” until a timeout? On the third page of the topic, it’s mentioned that the server starting process state seems to hang at 73%, so, to be clear, could you give details of the problem?
The
.webclipse
folder referred to in some earlier posts is located in your home directory. It will not show in Finder by default (you can search for techniques to show hidden files, but here is one for quick reference).Also, please go to the eclipse Error Log view and export the current log to a text file, then attach it to your reply here.
sayantansinhaParticipantHi Tony,
Thank you so much for your response.Can you confirm the problem, since there have been several problems mentioned in this topic, with the opening post mentioning that the server starts but the server status shows “Starting” until a timeout? On the third page of the topic, it’s mentioned that the server starting process state seems to hang at 73%, so, to be clear, could you give details of the problem?
For me, the server does not start and yes, it hangs at 73%, post which it gives the timeout error. However, seems like on the terminal the command is still running even after eclipse throws the error, as, when I press “Ctrl+C” to break the command from the terminal, it prints the below error on the terminal:
TypeError: You provided an invalid object where a stream was expected. You can provide an Observable, Promise, Array, or Iterable. at Object.exports.subscribeTo (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/util/subscribeTo.js:42:15) at Object.subscribeToResult (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/util/subscribeToResult.js:7:26) at MergeMapSubscriber._innerSub (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/mergeMap.js:75:38) at MergeMapSubscriber._tryNext (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/mergeMap.js:72:14) at MergeMapSubscriber._next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/mergeMap.js:55:18) at MergeMapSubscriber.Subscriber.next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/Subscriber.js:64:18) at MapSubscriber._next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/map.js:52:26) at MapSubscriber.Subscriber.next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/Subscriber.js:64:18) at TapSubscriber._next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/tap.js:62:26) at TapSubscriber.Subscriber.next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/Subscriber.js:64:18) at MergeMapSubscriber.notifyNext (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/mergeMap.js:84:26) at InnerSubscriber._next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/InnerSubscriber.js:25:21) at InnerSubscriber.Subscriber.next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/Subscriber.js:64:18) at MapSubscriber._next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/operators/map.js:52:26) at MapSubscriber.Subscriber.next (<project path>/node_modules/@angular-devkit/architect/node_modules/rxjs/internal/Subscriber.js:64:18) at MergeMapSubscriber.notifyNext (<project path>/node_modules/@angular-devkit/core/node_modules/rxjs/internal/operators/mergeMap.js:84:26)
The .webclipse folder referred to in some earlier posts is located in your home directory
I was able to find the .webclipse folder and followed and removed the file requested but that did not work as well. One imported thing I noticed that a “nodejs” directory was created there and it was referring to v4.2.4 whereas my global nodejs is on v8.11.3, and in my eclipse preferences I am pointing to my global installation as well. Not sure if that is related but just wanted to state my observation if it helps in your troubleshooting.
Also, please go to the eclipse Error Log view and export the current log to a text file, then attach it to your reply here.
Attached the same
Attachments:
You must be logged in to view attached files.
support-tonyKeymastersayantansinha,
Thanks for the additional information. Unfortunately, the log file doesn’t show any errors other than the timeout. However, you mentioned that you’ve set preferences to your global node installation. These preferences are for other functions related to node development but, for Angular projects, the versions are specified during project creation or in the project properties. You can check which versions are specified by right clicking on the project and going to the Properties page, then the CLI Tool Management page. If the project is using the system installation of node and npm, those entries will be de-selected. Can you confirm the versions chosen? Note that for project specific versions, you will see the versions of node and npm shown at the top of a Terminal+ console; if you’re using system installed versions, the versions are not shown at the top of the console.
If you’re still seeing problems, try this:
- start a new Terminal+ session for the project
- enter
set -x
in the session console - copy the
ng serve
command which failed and paste it to the new Terminal+ session then hit Enter
This should give us a bit more information on where it seems to be stuck. You can copy and paste the terminal output and paste it here in a code section (click the
code
button at the top of the reply text box, for a code section – click to start one, click again to end it).Either way, please let us know how you get on.
sayantansinhaParticipantTony,
You can check which versions are specified by right clicking on the project and going to the Properties page, then the CLI Tool Management page. If the project is using the system installation of node and npm, those entries will be de-selected. Can you confirm the versions chosen?
Refer to attached screenshot from my eclipse properties. It is using the system installation as you can see. However, there is a warning on the top where it states “Cannot update list of versions” or something like that.
If you’re still seeing problems, try this:
start a new Terminal+ session for the project
enter set -x in the session console
copy the ng serve command which failed and paste it to the new Terminal+ session then hit EnterRefer to attached txt file with the output. I have masked the directories and git branches as this is a public thread.
Attachments:
You must be logged in to view attached files.
support-tonyKeymastersayantansinha,
Thanks for confirming that information. I must apologize for suggesting the
set -x
run as I’d forgotten that the ng command is actually a node script, not a shell script, and so the tracing cannot be done in this way and I don’t think there is a way to trace it.In trying to figure this out, we have a few ideas which may either help or may offer more information.
- We’ve seen that, on rare occasions, the CodeLive feature has caused problems with the app build and launch, so it would be worth turning this off to see if it has an impact. Right click on the appropriate server in the Servers view then select CodeLive, if it is ticked, to disable it. Now try to start the server again.
- To determine if the server can be launched at all, please try to launch it outside of eclipse. In a terminal,
cd
to the folder for the project then enter:ng serve
. If that works, you could also try the full command, which stalls, as shown in the Terminal+ console, as this will execute the angular-ide version of theng
command and the server would be recognized as started, in the Servers view. - We have sometimes seen some conflicts with various installations of node that may be accessible. For example, a node_modules folder in the home directory has caused some commands to fail. Could you check for multiple full or partial installations of node and npm? If you find any, then try cleaning them up.
- Is there something unusual about your project structure? Perhaps nested projects?
- As a test to see if the problem is project related, you could try creating a new Angular project with the Angular IDE and see if this new untouched project runs OK.
There is no particular order to these suggestions, please try in whichever order suits. Please let us know how you get on.
sayantansinhaParticipanttony,
Thanks for the details. I did try each of these, below are my comments (provided in the same order) against those based on that,- tried disabling CodeLive, did not work
ng serve
works fine, infact that is how I have been running it so far in the absence of this working. When I copied the same command that webclipse is generating, that is also getting stuck from the terminal window- I have only one node and npm installation which has been installed globally. As I have stated earlier my node has v8.11.3 and npm has v5.6.0
- nothing unusual, but this project was initially generated by Angular ClI 1.x and then migrated to the latest 6.x
- when I tried creating, it seems like it is using angular cli of 1.x and it says npm list not updated and it does not allow me to create a new project as well. See screenshot.
- One more additional thing, not related to this, I have some library projects generated separately on a diff angular app using Angular CLI 6 as that now has built-in support for ng-packagr, but for some reason the IDE does not complain of compilation errors. I do see the tslint.json available
Attachments:
You must be logged in to view attached files.
support-tonyKeymastersayantansinha,
Thanks for trying those suggestions. I hadn’t really considered network issues, since you hadn’t mentioned other issues and certainly, an
npm install
would need network access, for example (you mentioned upgrading the project to Angular version 6 so that would require downloading modules). However, the dialog in your screenshot is definitely in a state that would be expected if there were networking issues from eclipse and that might explain the freeze when starting the server (depending on whatng
thinks needs to be done).You can check network access by opening a new Terminal+ session on the project and entering
npm update
. If the network access hasn’t been set properly, this will eventually produce an error (ENOTFOUND).You can set your proxy using Eclipse->Preferences->General->Network Connections. There is a FAQ about this on our site.
Please let us know if this resolves the issue.
-
AuthorPosts