2

I have a project hosted on Github and one of it's dependencies is hosted on Bitbucket. Both repositories are private, but we have access to them.

I've recently added git tag for versioning, because build server on customer's site did not pick up the most recent version of one dependency.

So the package.json now looks like this

"ember-custom-adapter": "git+ssh://git@bitbucket.org:path-to-project.git#v0.0.7",

I have made 100% sure that the git tag v0.0.7 is really available on that Bitbucket repository.

But when Travis CI runs the build, it fails with error missing npm packages See screenshot for details

Mark #1 shows the npm install command being called, but mark #2 shows hint to run it again, because the package was not found. Which does not make sense to me. It used to work without the tags, but for some reason the older version of dependency package was used.

Any ideas?

enter image description here

UPDATE

It is fixed now, but it is still unclear what really caused the issue. It seems that our Travis CI build works a little bit differently than customer's build on Jenkins. So what passed in our Travis, did not work in his Jenkins. Which is weird. I will add current working solution as an answer

David Votrubec
  • 3,968
  • 3
  • 33
  • 44

1 Answers1

0

We have managed to find a working solution, but we did not found what actually caused the issue.

We use Travis CI as our build server, but customer uses Jenkins. What passed on Travis, did not work on Jenkins. Specifically it could not find one npm dependency.

So the working solution is like this

  • Git tab on dependent repository is labelled by numeric values only. We have changed v0.0.7 to 0.0.9
  • package.json in that repository has the same version
  • main project references the dependency like this "ember-custom-adapter": "git+ssh://git@bitbucket.org:path-to-project.git#0.0.9"

If anyone finds out what the issue was I will be glad

David Votrubec
  • 3,968
  • 3
  • 33
  • 44