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

Bower install : Angular version problem #196

Open
WilliamChelman opened this issue Nov 4, 2015 · 11 comments
Open

Bower install : Angular version problem #196

WilliamChelman opened this issue Nov 4, 2015 · 11 comments

Comments

@WilliamChelman
Copy link

Using angular 1.4.7, when I try to install date-picker through bower, I get

bower angular-datepicker#* cached git://github.com/g00fy-/angular-datepicker.git#2.0.0
bower angular-datepicker#* validate 2.0.0 against git://github.com/g00fy-/angular-datepicker.git#*
bower angular#1.2.14 cached git://github.com/angular/bower-angular.git#1.2.14
bower angular#1.2.14 validate 1.2.14 against git://github.com/angular/bower-angular.git#1.2.14
bower angular#>=1.3.0 cached git://github.com/angular/bower-angular.git#1.4.7
bower angular#>=1.3.0 validate 1.4.7 against git://github.com/angular/bower-angular.git#>=1.3.0
bower angular#^1.4.7 <2 cached git://github.com/angular/bower-angular.git#1.4.7
bower angular#^1.4.7 <2 validate 1.4.7 against git://github.com/angular/bower-angular.git#^1.4.7 <2
bower angular#1.4.7 cached git://github.com/angular/bower-angular.git#1.4.7
bower angular#1.4.7 validate 1.4.7 against git://github.com/angular/bower-angular.git#1.4.7
bower angular#>=1.2.16 1.4.x cached git://github.com/angular/bower-angular.git#1.4.7
bower angular#>=1.2.16 1.4.x validate 1.4.7 against git://github.com/angular/bower-angular.git#>=1.2.16 1.4.x
bower angular#>=1.2.18 cached git://github.com/angular/bower-angular.git#1.4.7
bower angular#>=1.2.18 validate 1.4.7 against git://github.com/angular/bower-angular.git#>=1.2.18
bower ECONFLICT Unable to find suitable version for angular

In the bower.json, the dependencies are

"dependencies": {
"angular": "1.2.14",
"moment": "~2.10.6",
"moment-timezone": "~0.4.1"
},

Shouldn't it be "angular": ">=1.2.14" since it is supposed to work with angular 1.2+ ?

@WilliamChelman WilliamChelman changed the title Angular version Bower install : Angular version problem Nov 4, 2015
@DanTalash
Copy link
Contributor

I think the angular version needs to be at least 1.3, as the library is using some features of angular which were added in 1.3

  • $validators are used here and here.
    • I cannot find any official documentation that explicitly states what version of angular the $validators pipeline was added, but many blog posts mention that it is new in 1.3.
    • The docs for 1.2 make no mention of $validators.
    • The docs for 1.3 have information on $validators.
  • $watchGroup is used in this PR in the date-range directive. Again, this is a feature of angularjs 1.3+

If support for angular 1.2 is required, $validators and $watchGroup cannot be used, and must be replaced with something else.

@WilliamChelman
Copy link
Author

Yes, but I use Angular 1.4.7, so there should not be compatibility issues with date-picker which requires 1.2+ no ? (the bower.json that I mentionned is the one of date-picker, sorry if I was not clear enough)

@alexeyzimarev
Copy link

I have the same issue. Current bower.json has strict dependency on angular 1.2.14 and this does not work with 1.4.7.

@valera33
Copy link

same issue

@timmyomahony
Copy link

also the same issue

@mcranston18
Copy link

+1

3 similar comments
@Steve-Mc
Copy link

+1

@dejan7
Copy link

dejan7 commented Dec 1, 2015

+1

@randyv12
Copy link

randyv12 commented Dec 2, 2015

+1

@AdamHess
Copy link

AdamHess commented Mar 8, 2016

I'm a little mad that this hasnt been fixed since it's so easy to there are probably a dozen pull requests for it.

Here's the simple fix for your environment:

add the following to your bower.json

"resolutions": {
"angular": "~1.4.7" <-- or whatever version of angular you are using
}

this will force bower to select the version of angular you want instead of being stuck with the 1.2 version the library uses.

@larryspace
Copy link

+1

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