Skip to content

tsp install ignores user .npmrc #11665

Description

Repro Steps

  1. create a user .npmrc pointing to an alternative package registry
  2. run "tsp install"

Expected: Respects user .npmrc
Actual: Ignores user .npmrc, tries to fetch from npmjs.org

Also appears to ignore NPM_CONFIG_REGISTRY env var:

% export NPM_CONFIG_REGISTRY=...     

% npx tsp install --debug                                              
trace cli.args: CLI args: { _: [ 'install' ], debug: true, pretty: true, '$0': 'tsp' }
Internal compiler error!
File issue at https://github.com/microsoft/typespec

[TypeError: fetch failed] {
  [cause]: Error: read ENOTCONN
      at TLSWrap.onStreamRead (node:internal/stream_base_commons:216:20) {
    errno: -57,
    code: 'ENOTCONN',
    syscall: 'read'
  }
}

Metadata

Metadata

Labels

bugSomething isn't workingcompiler:coreIssues for @typespec/compiler

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions