jfrog / bower-art-resolver

Apache License 2.0
15 stars 17 forks source link

Some bower packages still resolving to github #16

Open chrisvdp opened 8 years ago

chrisvdp commented 8 years ago

A very specific set of our bower packages are resolving to github instead of artifactory.

"loader.js": "ember-cli/loader.js#3.4.0",
"ember-cli-shims": "ember-cli/ember-cli-shims#0.0.6",
"ember-cli-test-loader": "ember-cli/ember-cli-test-loader#0.2.2",
"inuit.css": "inuitless/inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f",
"sticky": "garand/sticky#1.0.3"

running bower i shows

bower loader.js#3.4.0       not-cached git://github.com/ember-cli/loader.js.git#3.4.0
bower loader.js#3.4.0          resolve git://github.com/ember-cli/loader.js.git#3.4.0
bower ember-cli-shims#0.0.6 not-cached git://github.com/ember-cli/ember-cli-shims.git#0.0.6
bower ember-cli-shims#0.0.6    resolve git://github.com/ember-cli/ember-cli-shims.git#0.0.6
bower ember-cli-test-loader#0.2.2       not-cached git://github.com/ember-cli/ember-cli-test-loader.git#0.2.2
bower ember-cli-test-loader#0.2.2          resolve git://github.com/ember-cli/ember-cli-test-loader.git#0.2.2
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f       not-cached git://github.com/inuitless/inuit.css.git#954d11d70bc0c468008a9f4f261bb7dd87a3a1f
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f          resolve git://github.com/inuitless/inuit.css.git#954d11d70bc0c468008a9f4f261bb7dd87a3a1f
bower sticky#1.0.3                                            not-cached git://github.com/garand/sticky.git#1.0.3
bower sticky#1.0.3                                               resolve git://github.com/garand/sticky.git#1.0.3
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f         checkout 954d11d70bc0c468008a9f4f261bb7dd87a3a1f
bower loader.js#3.4.0                                           download https://github.com/ember-cli/loader.js/archive/v3.4.0.tar.gz
bower ember-cli-shims#0.0.6                                     download https://github.com/ember-cli/ember-cli-shims/archive/0.0.6.tar.gz
bower ember-cli-test-loader#0.2.2                               download https://github.com/ember-cli/ember-cli-test-loader/archive/v0.2.2.tar.gz
bower sticky#1.0.3                                              download https://github.com/garand/sticky/archive/1.0.3.tar.gz

All packages that use semver symantics resolve correctly. We are using Artifactory v4.4.3

mac:webui chrisvdp$ bower --version
1.7.7
"bower-art-resolver": "^2.0.5"

Full output

bower install -V
bower loader.js#3.4.0       not-cached git://github.com/ember-cli/loader.js.git#3.4.0
bower loader.js#3.4.0          resolve git://github.com/ember-cli/loader.js.git#3.4.0
bower ember-cli-shims#0.0.6 not-cached git://github.com/ember-cli/ember-cli-shims.git#0.0.6
bower ember-cli-shims#0.0.6    resolve git://github.com/ember-cli/ember-cli-shims.git#0.0.6
bower ember-cli-test-loader#0.2.2       not-cached git://github.com/ember-cli/ember-cli-test-loader.git#0.2.2
bower ember-cli-test-loader#0.2.2          resolve git://github.com/ember-cli/ember-cli-test-loader.git#0.2.2
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f       not-cached git://github.com/inuitless/inuit.css.git#954d11d70bc0c468008a9f4f261bb7dd87a3a1f
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f          resolve git://github.com/inuitless/inuit.css.git#954d11d70bc0c468008a9f4f261bb7dd87a3a1f
bower sticky#1.0.3                                            not-cached git://github.com/garand/sticky.git#1.0.3
bower sticky#1.0.3                                               resolve git://github.com/garand/sticky.git#1.0.3
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f         checkout 954d11d70bc0c468008a9f4f261bb7dd87a3a1f
bower loader.js#3.4.0                                           download https://github.com/ember-cli/loader.js/archive/v3.4.0.tar.gz
bower ember-cli-shims#0.0.6                                     download https://github.com/ember-cli/ember-cli-shims/archive/0.0.6.tar.gz
bower ember-cli-test-loader#0.2.2                               download https://github.com/ember-cli/ember-cli-test-loader/archive/v0.2.2.tar.gz
bower sticky#1.0.3                                              download https://github.com/garand/sticky/archive/1.0.3.tar.gz
bower jquery-ajax-retry#~0.2.7                                not-cached art://johnkpaul/jquery-ajax-retry#~0.2.7
bower jquery-ajax-retry#~0.2.7                                   resolve art://johnkpaul/jquery-ajax-retry#~0.2.7
bower ember-localstorage-adapter#0.5.2                        not-cached art://rpflorence/ember-localstorage-adapter#0.5.2
bower ember-localstorage-adapter#0.5.2                           resolve art://rpflorence/ember-localstorage-adapter#0.5.2
bower font-awesome#~4.3.0                                     not-cached art://FortAwesome/Font-Awesome#~4.3.0
bower font-awesome#~4.3.0                                        resolve art://FortAwesome/Font-Awesome#~4.3.0
bower jquery#1.11.3                                           not-cached art://jquery/jquery-dist#1.11.3
bower jquery#1.11.3                                              resolve art://jquery/jquery-dist#1.11.3
bower ember-data-model-fragments#~1.13                        not-cached art://lytics/ember-data-model-fragments#~1.13
bower ember-data-model-fragments#~1.13                           resolve art://lytics/ember-data-model-fragments#~1.13
bower vex#~2.3.2                                              not-cached art://HubSpot/vex#~2.3.2
bower vex#~2.3.2                                                 resolve art://HubSpot/vex#~2.3.2
bower ember-resolver#~0.1.20                                  not-cached art://stefanpenner/ember-jj-abrams-resolver#~0.1.20
bower ember-resolver#~0.1.20                                     resolve art://stefanpenner/ember-jj-abrams-resolver#~0.1.20
bower pretender#0.1.0                                         not-cached art://trek/pretender#0.1.0
bower pretender#0.1.0                                            resolve art://trek/pretender#0.1.0
bower ember-data#1.13.15                                      not-cached art://components/ember-data#1.13.15
bower ember-data#1.13.15                                         resolve art://components/ember-data#1.13.15
bower sinonjs#1.17.1                                          not-cached art://blittle/sinon.js#1.17.1
bower sinonjs#1.17.1                                             resolve art://blittle/sinon.js#1.17.1
bower blanket#~1.1.5                                          not-cached art://alex-seville/blanket#~1.1.5
bower blanket#~1.1.5                                             resolve art://alex-seville/blanket#~1.1.5
bower Case#~1.2.1                                             not-cached art://nbubna/Case#~1.2.1
bower Case#~1.2.1                                                resolve art://nbubna/Case#~1.2.1
bower ember-load-initializers#0.1.7                           not-cached art://ember-cli/ember-load-initializers#0.1.7
bower ember-load-initializers#0.1.7                              resolve art://ember-cli/ember-load-initializers#0.1.7
bower ember-mocha#~0.8.8                                      not-cached art://switchfly/ember-mocha-builds#~0.8.8
bower ember-mocha#~0.8.8                                         resolve art://switchfly/ember-mocha-builds#~0.8.8
bower spin.js#~2.0.2                                          not-cached art://fgnass/spin.js#~2.0.2
bower spin.js#~2.0.2                                             resolve art://fgnass/spin.js#~2.0.2
bower clipboard#~1.4.2                                        not-cached art://zenorocha/clipboard.js#~1.4.2
bower clipboard#~1.4.2                                           resolve art://zenorocha/clipboard.js#~1.4.2
bower ember#1.13.12                                           not-cached art://components/ember#1.13.12
bower ember#1.13.12                                              resolve art://components/ember#1.13.12
bower momentjs#~2.10.3                                        not-cached art://moment/moment#~2.10.3
bower momentjs#~2.10.3                                           resolve art://moment/moment#~2.10.3
bower ember-shortcuts#~0.0.2                                  not-cached art://satchmorun/ember-shortcuts#~0.0.2
bower ember-shortcuts#~0.0.2                                     resolve art://satchmorun/ember-shortcuts#~0.0.2
bower modernizr#~2.8.3                                        not-cached art://Modernizr/Modernizr#~2.8.3
bower modernizr#~2.8.3                                           resolve art://Modernizr/Modernizr#~2.8.3
bower sticky#1.0.3                                               extract archive.tar.gz
bower ember-cli-test-loader#0.2.2                                extract archive.tar.gz
bower ember-cli-shims#0.0.6                                      extract archive.tar.gz
bower loader.js#3.4.0                                            extract archive.tar.gz
bower sticky#1.0.3                                              resolved git://github.com/garand/sticky.git#1.0.3
bower ember-cli-test-loader#0.2.2                               resolved git://github.com/ember-cli/ember-cli-test-loader.git#0.2.2
bower ember-cli-shims#0.0.6                                     resolved git://github.com/ember-cli/ember-cli-shims.git#0.0.6
bower ember-load-initializers#0.1.7                             resolved art://ember-cli/ember-load-initializers#v0.1.7
bower ember-shortcuts#~0.0.2                                    resolved art://satchmorun/ember-shortcuts#v0.0.8
bower pretender#0.1.0                                           resolved art://trek/pretender#0.1.0
bower loader.js#3.4.0                                           mismatch Version declared in the json (3.3.0) is different than the resolved one (3.4.0)
bower sinonjs#1.17.1                                            resolved art://blittle/sinon.js#v1.17.1
bower loader.js#3.4.0                                           resolved git://github.com/ember-cli/loader.js.git#3.4.0
bower ember-mocha#~0.8.8                                        resolved art://switchfly/ember-mocha-builds#v0.8.11
bower ember-localstorage-adapter#0.5.2                          resolved art://rpflorence/ember-localstorage-adapter#0.5.2
bower jquery-ajax-retry#~0.2.7                                  resolved art://johnkpaul/jquery-ajax-retry#0.2.7
bower clipboard#~1.4.2                                          resolved art://zenorocha/clipboard.js#v1.4.3
bower ember-resolver#~0.1.20                                    resolved art://stefanpenner/ember-jj-abrams-resolver#v0.1.21
bower Case#~1.2.1                                               resolved art://nbubna/Case#1.2.1
bower spin.js#~2.0.2                                            resolved art://fgnass/spin.js#v2.0.2
bower ember-data-model-fragments#~1.13                          resolved art://lytics/ember-data-model-fragments#v1.13.2
bower FakeXMLHttpRequest#~1.0.0                               not-cached art://trek/FakeXMLHttpRequest#~1.0.0
bower FakeXMLHttpRequest#~1.0.0                                  resolve art://trek/FakeXMLHttpRequest#~1.0.0
bower route-recognizer#~0.1.1                                 not-cached art://tildeio/route-recognizer#~0.1.1
bower route-recognizer#~0.1.1                                    resolve art://tildeio/route-recognizer#~0.1.1
bower chai#~2.3.0                                             not-cached art://chaijs/chai#~2.3.0
bower chai#~2.3.0                                                resolve art://chaijs/chai#~2.3.0
bower ember-mocha-adapter#~0.3.1                              not-cached art://teddyzeenny/ember-mocha-adapter#~0.3.1
bower ember-mocha-adapter#~0.3.1                                 resolve art://teddyzeenny/ember-mocha-adapter#~0.3.1
bower mocha#~2.2.4                                            not-cached art://mochajs/mocha#~2.2.4
bower mocha#~2.2.4                                               resolve art://mochajs/mocha#~2.2.4
bower ember-data#1.13.15                                        resolved art://components/ember-data#1.13.15
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f     invalid-meta inuit.css is missing "main" entry in bower.json
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f     invalid-meta inuit.css is missing "ignore" entry in bower.json
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f         resolved git://github.com/inuitless/inuit.css.git#954d11d70b
bower FakeXMLHttpRequest#~1.0.0                                 resolved art://trek/FakeXMLHttpRequest#1.0.0
bower route-recognizer#~0.1.1                                   resolved art://tildeio/route-recognizer#0.1.9
bower ember-mocha-adapter#~0.3.1                                resolved art://teddyzeenny/ember-mocha-adapter#0.3.1
bower modernizr#~2.8.3                                          resolved art://Modernizr/Modernizr#v2.8.3
bower chai#~2.3.0                                               resolved art://chaijs/chai#2.3.0
bower jquery#1.11.3                                             resolved art://jquery/jquery-dist#1.11.3
bower mocha#~2.2.4                                              resolved art://mochajs/mocha#2.2.5
bower blanket#~1.1.5                                          deprecated Package blanket is using the deprecated component.json
bower blanket#~1.1.5                                            resolved art://alex-seville/blanket#v1.1.7
bower momentjs#~2.10.3                                          resolved art://moment/moment#2.10.6
bower ember#1.13.12                                             resolved art://components/ember#1.13.12
bower vex#~2.3.2                                                resolved art://HubSpot/vex#v2.3.3
bower font-awesome#~4.3.0                                       resolved art://FortAwesome/Font-Awesome#v4.3.0
bower sticky#1.0.3                                               install sticky#1.0.3
bower ember-cli-test-loader#0.2.2                                install ember-cli-test-loader#0.2.2
bower ember-cli-shims#0.0.6                                      install ember-cli-shims#0.0.6
bower ember-load-initializers#0.1.7                              install ember-load-initializers#v0.1.7
bower ember-shortcuts#~0.0.2                                     install ember-shortcuts#v0.0.8
bower pretender#0.1.0                                            install pretender#0.1.0
bower sinonjs#1.17.1                                             install sinonjs#v1.17.1
bower loader.js#3.4.0                                            install loader.js#3.4.0
bower ember-mocha#~0.8.8                                         install ember-mocha#v0.8.11
bower ember-localstorage-adapter#0.5.2                           install ember-localstorage-adapter#0.5.2
bower jquery-ajax-retry#~0.2.7                                   install jquery-ajax-retry#0.2.7
bower clipboard#~1.4.2                                           install clipboard#v1.4.3
bower ember-resolver#~0.1.20                                     install ember-resolver#v0.1.21
bower Case#~1.2.1                                                install Case#1.2.1
bower spin.js#~2.0.2                                             install spin.js#v2.0.2
bower ember-data-model-fragments#~1.13                           install ember-data-model-fragments#v1.13.2
bower ember-data#1.13.15                                         install ember-data#1.13.15
bower inuit.css#954d11d70bc0c468008a9f4f261bb7dd87a3a1f          install inuit.css#954d11d70b
bower FakeXMLHttpRequest#~1.0.0                                  install FakeXMLHttpRequest#1.0.0
bower route-recognizer#~0.1.1                                    install route-recognizer#0.1.9
bower ember-mocha-adapter#~0.3.1                                 install ember-mocha-adapter#0.3.1
bower modernizr#~2.8.3                                           install modernizr#v2.8.3
bower chai#~2.3.0                                                install chai#2.3.0
bower jquery#1.11.3                                              install jquery#1.11.3
bower mocha#~2.2.4                                               install mocha#2.2.5
bower blanket#~1.1.5                                             install blanket#v1.1.7
bower momentjs#~2.10.3                                           install momentjs#2.10.6
bower ember#1.13.12                                              install ember#1.13.12
bower vex#~2.3.2                                                 install vex#v2.3.3
bower font-awesome#~4.3.0                                        install font-awesome#v4.3.0

sticky#1.0.3 bower_components/sticky
└── jquery#1.11.3

ember-cli-test-loader#0.2.2 bower_components/ember-cli-test-loader

ember-cli-shims#0.0.6 bower_components/ember-cli-shims
└── ember#1.13.12

ember-load-initializers#v0.1.7 bower_components/ember-load-initializers
└── ember#1.13.12

ember-shortcuts#v0.0.8 bower_components/ember-shortcuts

pretender#0.1.0 bower_components/pretender
├── FakeXMLHttpRequest#1.0.0
└── route-recognizer#0.1.9

sinonjs#v1.17.1 bower_components/sinonjs

loader.js#3.4.0 bower_components/loader.js

ember-mocha#v0.8.11 bower_components/ember-mocha
├── chai#2.3.0
├── ember-mocha-adapter#0.3.1
└── mocha#2.2.5

ember-localstorage-adapter#0.5.2 bower_components/ember-localstorage-adapter
├── ember#1.13.12
└── ember-data#1.13.15

jquery-ajax-retry#0.2.7 bower_components/jquery-ajax-retry

clipboard#v1.4.3 bower_components/clipboard

ember-resolver#v0.1.21 bower_components/ember-resolver
└── ember#1.13.12

Case#1.2.1 bower_components/Case

spin.js#v2.0.2 bower_components/spin.js

ember-data-model-fragments#v1.13.2 bower_components/ember-data-model-fragments
└── ember-data#1.13.15

ember-data#1.13.15 bower_components/ember-data
└── ember#1.13.12

inuit.css#954d11d70b bower_components/inuit.css

FakeXMLHttpRequest#1.0.0 bower_components/FakeXMLHttpRequest

route-recognizer#0.1.9 bower_components/route-recognizer

ember-mocha-adapter#0.3.1 bower_components/ember-mocha-adapter

modernizr#v2.8.3 bower_components/modernizr

chai#2.3.0 bower_components/chai

jquery#1.11.3 bower_components/jquery

mocha#2.2.5 bower_components/mocha

blanket#v1.1.7 bower_components/blanket

momentjs#2.10.6 bower_components/momentjs

ember#1.13.12 bower_components/ember
└── jquery#1.11.3

vex#v2.3.3 bower_components/vex

font-awesome#v4.3.0 bower_components/font-awesome
mattlewi commented 8 years ago

same issue here. For every occurrence of this that I've come across, I think the git repo is either missing the bower.json altogether, or the version attribute isn't being provided in the published bower.json. We've been struggling with a lot of Artifactory resolution issues when version isn't provided in bower.json. That reliance should probably be reviewed since the version property is now deprecated.

Artifactory Professional 4.5.0 rev 40115

eyalbe4 commented 8 years ago

@mattlewi and @chrisvdp, The issue you're experiencing could be caused by the fact that you have external dependencies declared in bower.json (dependencies that include a direct git URL). If you use a Virtual Repository in Artifactory to resolve your bower dependencies, you can configure it to re-write the URL for those dependencies and by that enforcing their resolution from Artifactory. You can read about it in the Bower Repositories Documentation page. @mattlewi - as for the point you raised about the version property deprecation: When resolving from Remote or Virtual Repositories, Artifactory lists the packages version by querying the existing tags in the Git repository, so the fact that that the version property became deprecated by Bower should not effect that. You will however still need to declare the version property when deploying your packages to Artifactory.

mhofstetter commented 8 years ago

hi @eyalbe4

I'm facing the same issue behind artifactory pro 4.7.0. I'm using a Virtual Repository with url re-write enabled.

The problem occurs if a third-party dependency uses the bower GitHub shorthand variant in the dependency-section as version. e.g. "Polymer/polymer#^1.2.0" ==> github name/repo. See https://bower.io/#install-packages

"dependencies": {
    "polymer": "Polymer/polymer#^0.5",
    "core-icon": "Polymer/core-icon#^0.5",
    "core-icons": "Polymer/core-icons#^0.5",
    "core-input": "Polymer/core-input#^0.5",
    "core-style": "Polymer/core-style#^0.5"
  }

In this cases the bower-client doesn't make a lookup, justs "appends" this string to the github.com url. bower polymer#^1.2.0 resolve git://github.com/Polymer/polymer.git#^1.2.0

I think this case isn't included in the re-write functionality of the artifactory server, nor in the bower-art-resolver.

eyalbe4 commented 8 years ago

Thanks @mhofstetter. We're looking into this and will update soon.

eyalbe4 commented 8 years ago

@mhofstetter, thanks for reporting this issue. We made sure version 4.11.0 of Artifactory supports Bower's shorthand-resolver. 4.11.0 is planned to be released soon. You'll also need to add the following line to your .bowerrc file: "shorthand-resolver": "art://{{owner}}/{{package}}" We will also try to improve the bower-art-resolver code, so that it adds the above configuration to the bower configuration automatically. We'll update here when this is done.

mhofstetter commented 8 years ago

Thank you very much @eyalbe4. I will try this as soon as we can update our artifactory server to the latest version.

eyalbe4 commented 8 years ago

@mattlewi and @chrisvdp, Did you get a chance to try this out with version 4.11.0 or above of Artifactory?

mattlewi commented 8 years ago

We upgraded to 4.14.0 last week (from 4.5). We'll keep an eye out for a reccurrence of this issue.

Thanks for following up!

Matt

On Oct 30, 2016 9:56 AM, "Eyal Ben Moshe" notifications@github.com wrote:

@mattlewi https://github.com/mattlewi and @chrisvdp https://github.com/chrisvdp, Did you get a chance to try this out with version 4.11.0 or above of Artifactory?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/JFrogDev/bower-art-resolver/issues/16#issuecomment-257152417, or mute the thread https://github.com/notifications/unsubscribe-auth/AGkTOxzwPLea7tMgmY9jVr_Yyr8E1Wxhks5q5KImgaJpZM4HnoL4 .

chrisvdp commented 8 years ago

@eyalbe4 We are still running 4.4.3 rev 40110. I'll try and get it upgraded to see if it fixes the issue, in the meantime feel free to close the bug, I can reopen if it is still an issue.