Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lb freeze at "Enter name of the directory to contain the project" question #36

Closed
1 of 5 tasks
cdokolas opened this issue Jun 9, 2017 · 31 comments
Closed
1 of 5 tasks
Assignees

Comments

@cdokolas
Copy link

cdokolas commented Jun 9, 2017

Bug or feature request

  • Bug
  • Feature request

Description of feature (or steps to reproduce if bug)

I run lb but I only get as far as the "Enter name of the directory to contain the project" question, where I can't type anything in or exit via Ctrl-C.

Same behavior with administrative command prompt. Powershell or classic prompt doesn't affect result.

Tried re-installing loopback-cli (npm uninstall/install). Same.

Expected result

I should be able to enter the directory name for my new project and continue.

Actual result (if bug)

Prompt stuck, not accepting input. Nothing to do but shut-down the terminal window.

Additional information (Node.js version, LoopBack version, etc)

node.js: v8.1.0
npm.js: 5.0.3
loopback-cli (via lb -v): 2.5.1 (generator-loopback@3.7.0 loopback-workspace@3.40.1)
Windows 10 Pro 64-bit (with Creators Update; fully updated/patched as of posting)

Acceptance Criteria

  • verify if the problem still exists
  • if problem still exists, put debug statements to identify the bottleneck
  • see if we can fix the bottleneck
@Omar-allahham
Copy link

here the same!

@juanpedrob9
Copy link

I got basically the same problem here, I can enter the app name but it freeze at second step when you get to choose loopback version. Same result when installed with either npm or yarn. Ctrl-C don't work got to kill -9 pid for it to exit.

loopback-cli: 2.5.1 (generator-loopback@3.7.0 loopback-workspace@3.40.1)
node: 8.1.0
npm: 5.0.3 / yarn 0.24.6
Fedora 25: 4.11.3-202.fc25.x86_64

@raymondfeng
Copy link
Member

I can reproduce the issue with node 8.1.0. It works with node 8.0.0.

@cdokolas
Copy link
Author

Tried strongloop/generator-loopback (yeoman generator) and found the same behavior. Anyone able to further look into it? (I lack the know-how)

@raymondfeng
Copy link
Member

I see the same problem with https://github.com/yeoman/generator-node. I'll open an issue for yeoman.

@raymondfeng
Copy link
Member

It's a bug in Node 8.1. See nodejs/node#13557.

@NadhiyaMajeed
Copy link

Hi

Am facing lb freeze after giving the application name.
node version - v10.6.0
npm version=6.1.0
loopback- 4.2.0
OS- windows10

can anybody help me here since am new to loopback.

@gezquinndesign
Copy link

I'm also experiencing lb freeze after giving the application name.

node version - v10.7.0
npm version=6.1.0
loopback- 4.2.0
OS- windows10

anyone help please?

@bennoll
Copy link

bennoll commented Sep 19, 2018

I'm also encountering lb freeze after entering the application name.

Program Version
node v10.10.0
npm 6.4.1
loopback 4.2.1
OS Windows 8

@NadhiyaMajeed
Copy link

Hi

2 months back i was trying this. i dont remember which one i was installing LTS or current.
if you have tried installing current and getting error go for LTS, then this error will not be getting.

Thanks
Nadhiya.P.M

@andenis
Copy link

andenis commented Oct 11, 2018

The problem is the same in the last node version for Windows (x64) Nodejs: 10.12.0.
For NodeJs version 8.12.0 works fine.

@Patafix
Copy link

Patafix commented Oct 24, 2018

Same problème here :

lb -v 4.2.1 (generator-loopback@5.9.4 loopback-workspace@4.5.0)
node -v v10.7.0

@median-man
Copy link

median-man commented Oct 30, 2018

Same issue here.

lb -v 4.2.1 (generator-loopback@5.9.4 loopback-workspace@4.5.0)
node -v v10.13.0

OS: Windows 10 Home

Update:

I was able to fix the issue after taking the following steps:

  1. Install node v8.12.0
  2. Install OpenSSL 1.1 in C:\OpenSSL-Win64 (strong-ursa hard codes the location)
  3. Create a symbolic link in C:\OpenSSL-Win64\lib named libeay64.lib which targets libcrypto.lib.
  4. Run npm i -g windows-build-tools
  5. Run npm i -g looback-cli again.

I'm not sure if rolling back the NodeJS version to 8.12 is necessary. There are a few widely, albeit not well documented pain points working with Loopback due to strong-ursa's use of native libraries. (Please note, this is unconfirmed information as I'm in a hurry to get back to developing the project at hand.) These steps allowed me to continue using Loopback CLI unhindered.

Useful info:

@bajtos
Copy link
Member

bajtos commented Nov 5, 2018

FWIW, we have been observing freezups on our CI servers since Node.js 10.2.0 was released, but weren't able to pinpoint the problem. You can read the discussion in nodejs/node#21210 to learn about the ways I tried to debug this problem. It would be awesome if somebody on Windows can check whether the problem can be reproduced using the latest Windows and Node.js versions.

@bajtos bajtos reopened this Nov 5, 2018
@Flash619
Copy link

Flash619 commented Nov 14, 2018

@bajtos I can confirm this same behavior.

Node: 10.13.0
NPM: 6.4.1
Loopback: 4.2.1
Generator Loopback: 5.9.4
Loopback Workspace: 4.5.0
Windows 10: (v1803)

I have confirmed the same issue in Node 11.1.0 as well.

@tsnork
Copy link

tsnork commented Nov 16, 2018

Same here

And same behaviour with any of the commands, e.g. lb datasource

@tsnork
Copy link

tsnork commented Nov 16, 2018

FWIW, debugging loopback-cli crashes repeatedly at marked line in screenshot. Seems to be the point the application stops responding:

https://i.imgur.com/T0Zlb0K.png

@tsnork
Copy link

tsnork commented Nov 17, 2018

FWIW, I reinstalled loopback-cli and it's now working. (Using this: https://www.npmjs.com/package/reinstall)

Can't pinpoint it to a specific thing, cause I updated the build tools (VS Studio update), updated OpenSSL and I'm on a totally different network now.

@nabdelgadir
Copy link

Program Version
node 8.14.0/10.14.1
npm 6.4.1
loopback 5.0.0
OS Windows 10

Using the above versions, I'm not able to reproduce the error. It does lag when using the lb app command however, but it doesn't freeze:

screen shot 2018-12-06 at 3 20 49 pm

I was also able to create a datasource and model. Try updating to the latest versions and see if you're still running into the same errors.

@jannyHou
Copy link
Contributor

Closing this issue since we couldn't reproduce it. Feel free to reopen it if you still have the problem (make sure you update node/npm/dependencies) as comment #36 (comment) :)

@smartmouse smartmouse reopened this Jan 31, 2019
@smartmouse
Copy link

smartmouse commented Jan 31, 2019

can reproduce on windows 10.
node 10.15.1
npm 6.4.1
we are using loopback-cli 4.2.1

@dhmlau
Copy link
Member

dhmlau commented Jan 31, 2019

@nabdelgadir, since you cannot reproduce it using loopback-cli@5.x but it seems like others are referring to 4.x, I'd like to propose the following actions:

  1. Confirm whether this issue only happens in loopback-cli@4.x with the same node.js version and windows machine.
  2. If that's the case, we might need to investigate what's changed in 5.x that fixes the problem. (I don't recall we're fixing any hanging/latency issue for 5.x but @jannyHou probably knows the best)

@smartmouse
Copy link

This issue seems to be windows specific, at least it works for me on mac and linux for node 10.15.1

@nabdelgadir
Copy link

screen shot 2019-02-04 at 8 57 34 am

Using node 10.15.1, I tried loopback-cli@4.2.1, 4.2.0, 4.0.0, and even 3.1.0 but all of them seem to have the same problem. The only one that works is loopback-cli@5.0.0. I suspect it was fixed by something done in this one PR by @jannyHou which occurred between 4.2.1 and 5.0.0.

@dhmlau dhmlau removed this from the December 2018 Milestone milestone Feb 12, 2019
@dhmlau
Copy link
Member

dhmlau commented Feb 12, 2019

Thanks @nabdelgadir. For those who have reported the issue here, it seems like this lagging/hanging problem no longer exist in loopback-cli@5.0.0. Could you please try to see if it works for you?

@smartmouse, it might be a good time to upgrade to use the latest version for API Connect v2018.x. Thanks.

@dhmlau
Copy link
Member

dhmlau commented Apr 22, 2019

Closing as resolved as this problem no longer exists in loopback-cli@5.0.0.

@dhmlau dhmlau closed this as completed Apr 22, 2019
@hashirabdullaps
Copy link

The problem still exist on loopback-cli@5.0.0 mac
5.0.0 (generator-loopback@6.0.4 loopback-workspace@5.0.0)
node v10.2.0
npm 6.1.0

freezes on second question

@straeger
Copy link

same problem on my mac
5.0.2 (generator-loopback@6.0.4 loopback-workspace@5.0.0)
node 11.9.0
npm 6.5.0

@KietChan
Copy link

Sorry, but I'm still facing this problem on the new version.

  • OS: Ubuntu 18.04.2
  • Node: v12.4.0
  • npm: 6.9.0
  • 5.0.0 (generator-loopback@6.0.4 loopback-workspace@5.0.0)

@nabdelgadir
Copy link

I think this PR #89 might resolve the issue.

@dhmlau
Copy link
Member

dhmlau commented Jun 20, 2019

@hashirQburst @straeger @KietChan, there's a new issue in inquirer (see SBoudrias/Inquirer.js#811) that causes the hanging. PR #89 that @nabdelgadir mentioned will make loopback-cli to use a lower version of inquirer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests