ionic-team / ionic-cli

The Ionic command-line interface
MIT License
1.99k stars 654 forks source link

ionic run -liverreload not working with Cordova-code-push plugin #2825

Open moshikh opened 6 years ago

moshikh commented 6 years ago

Description: "ionic run iOS -livereload" is not working when Cordova-code-push plugin is installed in the project. **app hangs as soon as the build finishes

Steps to Reproduce: it is easy to reproduce with an empty project

  1. ionic start myApp blank
  2. ionic cordova plugin add cordova-plugin-code-push
  3. ionic Cordova run ios -l

Output: no output

My ionic info: cli packages: (/usr/local/lib/node_modules)

@ionic/cli-utils  : 1.14.0
ionic (Ionic CLI) : 3.14.0

global packages:

cordova (Cordova CLI) : 7.1.0 

local packages:

@ionic/app-scripts : 3.0.0
Cordova Platforms  : ios 4.5.2
Ionic Framework    : ionic-angular 3.7.1

System:

ios-deploy : 1.9.2 
ios-sim    : 5.0.13 
Node       : v6.9.2
npm        : 5.5.1 
OS         : macOS High Sierra
Xcode      : Xcode 9.0 Build version 9A235 

Misc:

backend : legacy
moshik008 commented 6 years ago

HI, I am in 3.18.0 and the issue's still here. can someone confirm it is not just a local issue in my setup.

thanks.

MathieuMenegain commented 6 years ago

Hi, I have the same problem with this ionic info :

cli packages:

@ionic/cli-utils  : 1.19.0
ionic (Ionic CLI) : 3.19.0

global packages:

cordova (Cordova CLI) : 7.1.0 
Gulp CLI              : CLI version 3.9.1 Local version 3.9.1

local packages:

@ionic/app-scripts : 3.1.2
Cordova Platforms  : android 6.2.3 ios 4.4.0
Ionic Framework    : ionic-angular 3.9.2

System:

Android SDK Tools : 26.1.1
Node              : v8.2.1
npm               : 5.5.1 
OS                : Linux 4.13
imhoffd commented 6 years ago

I haven't investigated this yet, but this plugin presumably downloads app files (HTML/JS/CSS) from a server and replaces the app with the downloaded files, just like how Ionic Deploy works in Ionic Pro. Is this happening during development?

Livereload also instructs Cordova running on the app or emulator where to find app files. It uses a server to host files at an http:// URL instead of the traditional file:/// URL of Cordova apps.

I assume these two strategies are conflicting.