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

Endpoint registration bug #90

Closed
tauren opened this issue Aug 13, 2014 · 5 comments
Closed

Endpoint registration bug #90

tauren opened this issue Aug 13, 2014 · 5 comments

Comments

@tauren
Copy link

tauren commented Aug 13, 2014

It looks like endpoint registration isn't working quite right. Running jspm install git:... will look for a package named jspm-git, instead of whatever the endpoint package was registered as.

I have a package called jspm-stash, but I called the endpoint git. This didn't work:

Tue Aug 12 23:59: 56 PDT tmil11m2 ~/dev/jspm-test  
:jspm config endpoints.git jspm-stash
Wed Aug 13 00:00: 21 PDT tmil11m2 ~/dev/jspm-test  
:more ~/.jspm/config 
{
  "endpoints": {
    "git": "jspm-stash"
  }
}
Wed Aug 13 00:01: 20 PDT tmil11m2 ~/dev/jspm-test  
:jspm install git:stash.nikedev.com/~tmil11/idicons

     Checking versions for git:stash.nikedev.com/~tmil11/idicons

err  Error: Cannot find module 'jspm-git'
         at Function.Module._resolveFilename (module.js:338:15)
         at Function.Module._load (module.js:280:25)
         at Module.require (module.js:364:17)
         at require (module.js:380:17)
         at Object.exports.loadEndpoint (/Users/tmil11/.nvm/v0.10.29/lib/node_modules/jspm/lib/package.js:71:39)
         at Promise.then.versionMap (/Users/tmil11/.nvm/v0.10.29/lib/node_modules/jspm/lib/package.js:173:26)
         at $$$internal$$initializePromise (/Users/tmil11/.nvm/v0.10.29/lib/node_modules/jspm/node_modules/rsvp/dist/rsvp.js:511:9)
         at new $$rsvp$promise$$Promise (/Users/tmil11/.nvm/v0.10.29/lib/node_modules/jspm/node_modules/rsvp/dist/rsvp.js:822:9)
         at Promise.resolve.then.then.rangeVersion (/Users/tmil11/.nvm/v0.10.29/lib/node_modules/jspm/lib/package.js:172:12)
         at $$$internal$$tryCatch (/Users/tmil11/.nvm/v0.10.29/lib/node_modules/jspm/node_modules/rsvp/dist/rsvp.js:464:16)

err  Unable to load endpoint git

warn Installation changes not saved

When I created an endpoint named stash, it then worked:

Wed Aug 13 00:02: 04 PDT tmil11m2 ~/dev/jspm-test  
:jspm config endpoints.stash jspm-stash
Wed Aug 13 00:02: 24 PDT tmil11m2 ~/dev/jspm-test  
:more ~/.jspm/config 
{
  "endpoints": {
    "git": "jspm-stash",
    "stash": "jspm-stash"
  }
}
Wed Aug 13 00:02: 26 PDT tmil11m2 ~/dev/jspm-test  
:jspm install stash:stash.nikedev.com/~tmil11/idicons

     Checking versions for stash:stash.nikedev.com/~tmil11/idicons
     Downloading stash:stash.nikedev.com/~tmil11/[email protected]
ok   Installed stash:stash.nikedev.com/~tmil11/idicons as stash:stash.nikedev.com/~tmil11/idicons@^0.1.1 (0.1.1)
ok   Loader set to local library sources

ok   Install complete
@guybedford
Copy link
Member

I've posted a fix to aa9a35d

@guybedford
Copy link
Member

Note you need to register the endpoint with jspm config endpoint.stash npm-module-name

@tauren
Copy link
Author

tauren commented Aug 13, 2014

I was registering endpoints.stash instead of endpoint.stash. Thanks for clarifying. I'll try out your fix and let you know.

@guybedford
Copy link
Member

Did this work out ok in the end?

@tauren
Copy link
Author

tauren commented Aug 19, 2014

Yes, I will close this.

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

2 participants