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

Doesn't work with github branches #671

Closed
onlywei opened this issue Oct 11, 2016 · 6 comments
Closed

Doesn't work with github branches #671

onlywei opened this issue Oct 11, 2016 · 6 comments

Comments

@onlywei
Copy link

onlywei commented Oct 11, 2016

v0.15.1

Do you want to request a feature or report a bug?
Feature? Bug? Not sure.

What is the current behavior?
I just tried installing yarn today for a spin, and immediately failed when I tried to execute yarn in my directory because I have this dependency listed in my package.json:
"istanbul": "gotwarlost/istanbul.git#source-map"

If the current behavior is a bug, please provide the steps to reproduce.
Just try running yarn with that listed in as a dependency or devDependency in package.json

What is the expected behavior?
Install?

Please mention your node.js, yarn and operating system version.
Node v6.3.1, Yarn v0.15.1, Mac OS X 10.11.6

@tabrindle
Copy link

I'm having the same issue:

excerpt from the package.json

    "css-mqpacker": "^5.0.1",
    "eslint": "^3.4.0",
    "icon-font-generator": "git+https://github.com/tabrindle/icon-font-generator.git#feature/optional-font-types",
    "jasmine-core": "^2.5.1",

Throws this error:

info No lockfile found.
[1/4] 🔍  Resolving packages...
error Couldn't find match for "feature/optional-font-types" in "feature,master" for "https://github.com/tabrindle/icon-font-generator.git".
info Visit http://yarnpkg.com/en/docs/cli/install for documentation about this command.

@andrewaustin
Copy link

andrewaustin commented Oct 11, 2016

Same issue happens with other repository hosts, including bitbucket.

EDIT: This is a dupe of #513

@milosivanovic
Copy link

@onlywei it should work for your case if you follow #708.

@tabrindle looks like in this specific case the slash is the culprit. If the branch has no / in it, it'll work. Nice find.

@tabrindle
Copy link

I believe the / issue is solved with #813

@jmonster
Copy link

I'm having issues despite the proposed workarounds, but I did find that pointing at the tarball fixed my problem. In my package.json, the following pulls in what I expect:

"ember-sprite": "https://github.com/jmonster/ember-sprite/tarball/engines",

However, the following attempts all failed:

"ember-sprite": "ssh://github.com/jmonster/ember-sprite.git#engines",
"ember-sprite": "jmonster/ember-sprite#engines",
etc

To be specific, Yarn was able to clone the repo in the latter attempts -- but the code it used was not the correct branch. This was obvious because I kept getting either the following error:

error Couldn't find any versions for ember-sprite that matches ssh://git@github.com:jmonster/ember-sprite#engines. Possible versions: 0.0.1, 0.0.2, 0.0.3, 0.0.4, 0.1.0, 0.2.1, 0.3.0, 0.3.1, 0.4.0, 0.5.0, 0.6.0, 0.7.0

or this one (which is what the branch engines fixed)

error ember-sprite@0.7.0: The engine "node" is incompatible with this module. Expected version "4.2.x".
error Found incompatible module

@samccone
Copy link
Member

This has been fixed by a collection of fixed that have landed in master over the past 2 weeks. please reopen if you are still able to reproduce on master.

thanks everyone.

@wyze wyze removed the needs triage label Nov 10, 2016
kelvin-chappell added a commit to guardian/frontend that referenced this issue Jan 11, 2018
Because yarn bug causes head of branch not be fetched
if there is already a cached version of the branch.
See yarnpkg/yarn#671
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

8 participants