Upgrading to Ionic2 beta-11


#1

Hi all,

I’m trying to upgrade to ionic2 (beta-11) as mentioned in the release notes , I’m running the following command

npm install --save --save-exact ionic-angular @angular/common@2.0.0-rc.4 @angular/compiler@2.0.0-rc.4 @angular/core@2.0.0-rc.4 @angular/http@2.0.0-rc.4 @angular/platform-browser@2.0.0-rc.4 @angular/platform-browser-dynamic@2.0.0-rc.4 @angular/forms rxjs@5.0.0-beta.6 zone.js@0.6.12

and as per my understanding it should install all the new libraries (BTW, I’m pretty new to angular :)), but I’m getting this error

├── UNMET PEER DEPENDENCY @angular/common@2.0.0-rc.4
├── UNMET PEER DEPENDENCY @angular/compiler@2.0.0-rc.4
├── UNMET PEER DEPENDENCY @angular/core@2.0.0-rc.4
├── @angular/forms@0.3.0 
├── @angular/http@2.0.0-rc.4 
├── @angular/platform-browser@2.0.0-rc.4 
├── @angular/platform-browser-dynamic@2.0.0-rc.4 
├── ionic-angular@2.0.0-beta.10 
├── rxjs@5.0.0-beta.6 
└── zone.js@0.6.12 

npm WARN @angular/forms@0.3.0 requires a peer of @angular/core@^2.0.0-rc.5 but none was installed.
npm WARN @angular/forms@0.3.0 requires a peer of @angular/common@^2.0.0-rc.5 but none was installed.
npm WARN @angular/forms@0.3.0 requires a peer of @angular/compiler@^2.0.0-rc.5 but none was installed.
npm WARN petrescue-app No description
npm WARN petrescue-app No repository field.
npm WARN petrescue-app No license field.

What am I missing here ? Following is my ionic.info

Cordova CLI: 6.3.0
Gulp version:  CLI version 3.9.1
Gulp local:   Local version 3.9.1
Ionic Framework Version: 2.0.0-beta.10
Ionic CLI Version: 2.0.0-beta.36
Ionic App Lib Version: 2.0.0-beta.19
ios-deploy version: 1.8.6 
ios-sim version: 5.0.8 
OS: Mac OS X El Capitan
Node Version: v4.1.1
Xcode version: Xcode 7.0.1 Build version 7A1001 

thanks in advance

cheers

Sam


Update ionic beta
#2

You can edit package.json manually
"@angular/forms": “0.3.0” -> @angular/forms”: "0.2.0"
and then npm install again
It works


#3

Just follow my guide here: http://meshfields.de/howto-upgrade-to-ionic-2-beta-36-ionic-angular-11/


#4

Hey @nottinhill, thanks for the answer, I followed your steps (on the blog post) and still I see the following

Cordova CLI: 6.3.0 Gulp version: CLI version 3.9.1 Gulp local: Local version 3.9.1 Ionic Framework Version: 2.0.0-beta.10 Ionic CLI Version: 2.0.0-beta.36 Ionic App Lib Version: 2.0.0-beta.19 ios-deploy version: 1.8.6 ios-sim version: 5.0.8 OS: Mac OS X El Capitan Node Version: v4.1.1 Xcode version: Xcode 7.0.1 Build version 7A1001

Am I mis reading something here ?

cheers


#5

Hey @dahyej, thanks for the answer, I followed your solution and still I see the following

Cordova CLI: 6.3.0 Gulp version: CLI version 3.9.1 Gulp local: Local version 3.9.1 Ionic Framework Version: 2.0.0-beta.10 Ionic CLI Version: 2.0.0-beta.36 Ionic App Lib Version: 2.0.0-beta.19 ios-deploy version: 1.8.6 ios-sim version: 5.0.8 OS: Mac OS X El Capitan Node Version: v4.1.1 Xcode version: Xcode 7.0.1 Build version 7A1001

Then I followed the answer given by @nottinhill and still the same Am I mis reading something here in the ionic.info ?

because I expect Ionic Framework Version: 2.0.0-beta.10 -> Ionic Framework Version: 2.0.0-beta.11

cheers


#6

Hey @dahyej, @nottinhill,

I manually updated my package.json to

"@angular/forms": "0.2.0", "ionic-angular": "2.0.0-beta.11",

and ran a npm install

now it seems to be ok

Cordova CLI: 6.3.0 Gulp version: CLI version 3.9.1 Gulp local: Local version 3.9.1 Ionic Framework Version: 2.0.0-beta.11 Ionic CLI Version: 2.0.0-beta.36 Ionic App Lib Version: 2.0.0-beta.19 ios-deploy version: 1.8.6 ios-sim version: 5.0.8 OS: Mac OS X El Capitan Node Version: v4.1.1 Xcode version: Xcode 7.0.1 Build version 7A1001

but is this an acceptable way of doing the upgrade ? thanks in advance

cheers


#7

work great thank you


#8

Hey @sameera207, @nottinhill, I followed both of you answers and got this confusing message

npm ERR! peerinvalid Peer @angular/forms@0.2.0 wants @angular/common@^2.0.0-rc.4 npm ERR! peerinvalid Peer @angular/platform-browser@2.0.0-rc.3 wants @angular/common@2.0.0-rc.3 npm ERR! peerinvalid Peer @angular/platform-browser-dynamic@2.0.0-rc.3 wants @angular/common@2.0.0-rc.3 npm ERR! peerinvalid Peer ionic-angular@2.0.0-beta.11 wants @angular/common@2.0.0-rc.4

How is it possible that it wants both versions?

Gracias,
Andrew

Edit. Strange but this is my ionic info:

Cordova CLI: 6.3.0                                                                                                                           
Ionic Framework Version: 2.0.0-beta.11                                                                                                       
Ionic CLI Version: 2.0.0-beta.36                                                                                                             
Ionic App Lib Version: 2.0.0-beta.19                                                                                                         
ios-deploy version: Not installed                                                                                                            
ios-sim version: Not installed                                                                                                               
OS: Mac OS X El Capitan                                                                                                                      
Node Version: v4.4.7                                                                                                                         
Xcode version: Not installed 

beta.11 seems to have installed even with the messed up dependencies.

UPDATE:
Fixed the issue with @humhann 's fix .

npm install --save ionic-angular@2.0.0-beta.11 @angular/common@2.0.0-rc.4 @angular/compiler@2.0.0-rc.4 @angular/platform-browser@2.0.0-rc.4 @angular/platform-browser-dynamic@2.0.0-rc.4 @angular/http@2.0.0-rc.4 @angular/core@2.0.0-rc.4 rxjs@5.0.0-beta.6 zone.js@0.6.12


#9

I deleted according package Json entries beforehand and also remove ionic global install. That point maybe my tutorial is missing. I will edit my blog post in good faith according to above @andrewgy8 's suggestions (without having tested them myself).


#10

I get the following error when running @humhann command

├── UNMET PEER DEPENDENCY @angular/common@2.0.0-rc.5
├── UNMET PEER DEPENDENCY @angular/compiler@2.0.0-rc.5
├── UNMET PEER DEPENDENCY @angular/core@2.0.0-rc.5
├── @angular/forms@0.2.0 
├── UNMET PEER DEPENDENCY @angular/http@2.0.0-rc.5
├── UNMET PEER DEPENDENCY @angular/platform-browser@2.0.0-rc.5
├── UNMET PEER DEPENDENCY @angular/platform-browser-dynamic@2.0.0-rc.5
├── ionic-angular@2.0.0-beta.11 
├── rxjs@5.0.0-beta.6 
└── zone.js@0.6.12

#11

Never mind For some reason I was using rc.5 :confused: in my packages but after changing it to rc.4 everything is working