Skip to content
This repository has been archived by the owner on Aug 11, 2022. It is now read-only.

Peer dependency error with git repos #3307

Closed
donaldpipowitch opened this issue Apr 2, 2013 · 6 comments
Closed

Peer dependency error with git repos #3307

donaldpipowitch opened this issue Apr 2, 2013 · 6 comments

Comments

@donaldpipowitch
Copy link

Hi all,

is it possible to test peer dependencies with git repositories? I always get the following error:

npm ERR! peerinvalid The package repo-a does not satisfy its siblings' peerDependencies requirements!

Say I have the following node_modules as git repositories: repo-a, repo-b, repo-c. repo-b and repo-c peer depend on repo-a. The peer dependency is configured as "peerDependencies": { "repo-a": "git+ssh://git@github.com:my-account/repo-a.git" } in repo-b and repo-c. So basically both depend on the latest and same commit. (It doens't work with version tags either.)

Any ideas? Isn't it possible to test local peer dependencies without using a private npm or non-node_modules (aka just some git repos)?

@donaldpipowitch
Copy link
Author

Here is a test case: https://github.com/donaldpipowitch/test-example

The requested repo from the peer dependency will be downloaded, but throws an error.

Other questions:

  1. Does npm checks version conflicts in commit-ish semver tags? E.g. both modules from my test case request Bootstrap as #v2.2.2, would an error be thrown if one requests #v2.2.2 and the other one #v2.2.3?
  2. Can I shrinkwrap commit-ish semver tags? Will npm resolve #v2.2.x to the latest v2.2.x-tag?
  3. If 1. and 2. do not work, do you plan to implement this feature? If not, would accept a pull request if somebody else would do this?

@domenic
Copy link
Contributor

domenic commented Apr 6, 2013

Dupe of #3218, which is on my to-do list. I don't know the answer to your question 2 though, so I'll leave this open until someone can answer.

@donaldpipowitch
Copy link
Author

If this is a dupe, I will close this issue and create a dedicated issue for question 2. Thank you!

@dwabyick
Copy link

@donaldpipowitch what was the issue created for question 2?

@dwabyick
Copy link

(and just to clarify, this still doesn't work, right? we're running into the same issue)

@donaldpipowitch
Copy link
Author

I'm sorry. I think I didn't create an issue for question 2. I don't know if it was solved by now (- I only know that Bower has this feature, so it shouldn't be that difficult to get it to npm).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants