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

All Ionic commands stops without error #3099

Closed
MAPFRE-DCTP opened this issue Apr 24, 2018 · 23 comments
Closed

All Ionic commands stops without error #3099

MAPFRE-DCTP opened this issue Apr 24, 2018 · 23 comments

Comments

@MAPFRE-DCTP
Copy link

Description:

All Ionic commands are stopping without errors ( 'ionic serve','ionic cordova platform..', 'ionic cordova run..', etc.)
Ionic serve: it does not open browser and stops after 'lint finished'
ionic cordova platform add android: stops after Using cordova-fetch for cordova-android@7.0.0 (nothing in platform folder or package.json). But I can run cordova platform add android and it works.

It happens with all of my projects, even the projects that worked before.

I have tried to install other version of app-script.
I have tried to uninstall node.js and reinstall it but no lucky.

Steps to Reproduce:

Output:

ionic cordova platform add android --verbose
[DEBUG] Reason for not using local CLI: LOCAL_CLI_NOT_FOUND
[DEBUG] CLI flags: { interactive: true, confirm: false }
[DEBUG] { cwd: 'C:\\Users\\agarciaiglesias\\Documents\\chronic_painn', local: false, binPath:
        'C:\\Users\\agarciaiglesias\\AppData\\Roaming\\npm\\node_modules\\ionic\\bin\\ionic', libPath:
        'C:\\Users\\agarciaiglesias\\AppData\\Roaming\\npm\\node_modules\\ionic\\dist\\index.js' }
[DEBUG] New daemon pid: 17580
> cordova platform add android --save
Using cordova-fetch for cordova-android@7.0.0

My ionic info:

ionic info

cli packages: (C:\Users\agarciaiglesias\AppData\Roaming\npm\node_modules)

    @ionic/cli-utils  : 1.19.2
    ionic (Ionic CLI) : 3.20.0

global packages:

    cordova (Cordova CLI) : 8.0.0

local packages:

    @ionic/app-scripts : 2.1.4
    Cordova Platforms  : none
    Ionic Framework    : ionic-angular 3.9.2

System:

    Android SDK Tools : 26.1.1
    Node              : v8.11.1
    npm               : 5.6.0
    OS                : Windows 10

Environment Variables:

    ANDROID_HOME : C:\Users\agarciaiglesias\AppData\Local\Android\Sdk

Misc:

    backend : pro

Other Information:

@ionitron-bot ionitron-bot bot added the triage label Apr 24, 2018
@agarciaiglesias
Copy link

I have the same issue.
Please help!

@imhoffd
Copy link
Contributor

imhoffd commented Apr 24, 2018

Does it happen when you just run cordova platform add android --save ?

@leolux
Copy link

leolux commented Apr 24, 2018

Same for me after setting up ionic today and starting helloworld the process quits immediately:

$ ionic serve --verbose
[DEBUG] Reason for not using local CLI: LOCAL_CLI_NOT_FOUND
[DEBUG] CLI flags: { interactive: true, confirm: false }
[DEBUG] { cwd: 'D:\\ionic_test\\helloWorld', local: false, binPath:
        'C:\\Users\\rbl\\AppData\\Roaming\\npm\\node_modules\\ionic\\bin\\ionic', libPath:
        'C:\\Users\\rbl\\AppData\\Roaming\\npm\\node_modules\\ionic\\dist\\index.js' }
[DEBUG] Daemon found (pid: 6788)
Starting app-scripts server: --address 0.0.0.0 --port 8100 --livereload-port 35729 --dev-logger-port 53703 --nobrowser -
Ctrl+C to cancel
[20:25:11]  watch started ...
[20:25:11]  build dev started ...

And the command stops executing here

@imhoffd
Copy link
Contributor

imhoffd commented Apr 24, 2018

@leolux @agarciaiglesias Which version of app-scripts?

@leolux
Copy link

leolux commented Apr 24, 2018

ionic/app-scripts : 3.1.9
Cordova Platforms : none
Ionic Framework : ionic-angular 3.9.2

@agarciaiglesias
Copy link

@dwieeb cordova platform add android --save works well.
my ionic info:

cli packages: 

    @ionic/cli-utils  : 1.19.2
    ionic (Ionic CLI) : 3.20.0

global packages:

    cordova (Cordova CLI) : not installed

local packages:

    @ionic/app-scripts : 2.1.4
    Cordova Platforms  : none
    Ionic Framework    : ionic-angular 3.9.2

System:

    Android SDK Tools : 26.1.1
    Node              : v8.11.1
    npm               : 5.6.0
    OS                : Windows 10

@noeliamansog
Copy link

I have the same problem. Please, help as soon as possible.

@imhoffd
Copy link
Contributor

imhoffd commented Apr 26, 2018

Is everyone on Windows 10?

@agarciaiglesias
Copy link

yes I am on windows 10.

@noeliamansog
Copy link

Yes! on windows 10.

@leolux
Copy link

leolux commented Apr 26, 2018

Yes.

@imhoffd
Copy link
Contributor

imhoffd commented Apr 26, 2018

And it happens on every command? This is so weird, the CLI is working perfectly for me on Windows 10. Is everyone using Command Prompt? or a different terminal?

@leolux
Copy link

leolux commented Apr 26, 2018

I am using only git bash using MINGW64. I have tested the windows Command Prompt but the issue is the same.

@agarciaiglesias
Copy link

I have use cmd and PowerShell

@agarciaiglesias
Copy link

Any progress with this?
This is a bug that completely blocks me.
Please help.

@leolux
Copy link

leolux commented May 3, 2018

Me too. I am using the windows D:\ partition and I have faced some issues because of this in other projects. Do you run your project on the windows C:\ partition?

@agarciaiglesias
Copy link

Yes, I am on C:/ partition.

@imhoffd
Copy link
Contributor

imhoffd commented May 4, 2018

What if --no-interactive flag is used in commands?

@agarciaiglesias @leolux Please understand I'm just guessing at what the problem might be. It's difficult to debug something on a computer far away, and I still haven't been able to reproduce this on my Windows machine. 😞

@agarciaiglesias
Copy link

@dwieeb Commands with flag --no-interactive are working for me!!!!

Thank You very much for your help. I appreciate very much the effort to help us.

Only one question, What I miss with that flag?

@imhoffd
Copy link
Contributor

imhoffd commented May 7, 2018

The --no-interactive flag turns off our interactive prompts and fancy output. Basically, it makes the CLI much less friendly, but simpler when it comes to rendering on the terminal.

@agarciaiglesias If you have a second, could you test if the RC CLI has the same issue? npm i -g ionic@rc

@leolux
Copy link

leolux commented May 30, 2018

I have just updated git bash to the latest version and now everything works!

@imhoffd
Copy link
Contributor

imhoffd commented May 30, 2018

@leolux Nice! Great to hear. If the --no-interactive flag didn't work for you like it did for @agarciaiglesias, then I wonder if it was two separate issues.

Do the interactive prompts work for you, @leolux? Traditionally, Git Bash has been a non-interactive terminal which means our prompt library doesn't work with it (see SBoudrias/Inquirer.js#570).

I highly recommend Bash on Windows via the Ubuntu subsystem, if you're familiar with Git Bash. I use it at home and it's great!

@imhoffd imhoffd closed this as completed Jun 4, 2018
@imhoffd imhoffd removed the triage label Jun 4, 2018
@NDMCreative
Copy link

NDMCreative commented Aug 13, 2018

Try

npm remove -g ionic cordova -f
npm -g cache clean -f
npm i -g update npm
npm i -g ionic cordova socks
npm remove cordova -f
npm i cordova

npm i -D -E @ionic/app-scripts

Make sure that the platforms and resources folder physically exist, if they do not make them

Then see what errors occur when running each of these one at a time

ionic doctor fix
ionic cordova resources android -f -i -s
ionic cordova prepare android --prod
ionic cordova build android --prod --release

As the --prod may show errors normally hidden

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

6 participants