Skip to content

Fetching Codecov repository tokens fails if repo exists as private GH repo but you say it should be public #5

@sqs

Description

@sqs

npm init @sourcegraph in the existing private repo https://github.com/sourcegraph/extensions-client-common consistently failed. I fixed it by making the repo public (so I am not blocked on this and it is not urgent).

$ TRAVIS_TOKEN=REDACTED BUILDKITE_TOKEN=REDACTED CODECOV_TOKEN=REDACTED GITHUB_TOKEN=REDACTED npm init @sourcegraph
npx: installed 154 in 3.028s
Using GITHUB_TOKEN from env var
Using CODECOV_TOKEN from env var
Using BUILDKITE_TOKEN from env var
*️⃣ Welcome to the Sourcegraph npm package initializer
? What should the name of the package be? Examples: @sourcegraph/codeintellify, @sourcegraph/react-loading-spinner, cxp @sourcegraph/ext
ensions-client-common
? Description 
? 🔐 Should this package be public or private? public
📘 Existing git remote detected, skipping GitHub repository creation
🔑 Giving all FTTs admin access
? License? MIT
📄 Adding LICENSE
? Does this package have tests? Yes
📄 tsconfig.json already exists, skipping creation
📄 tslint.json already exists, skipping creation
📄 Adding prettier.config.js
📄 Adding .prettierignore
📄 Adding .gitignore
📄 package.json already exists, skipping creation
📂 Creating src directory
📦 Installing dependencies

> [email protected] uninstall /home/sqs/src/github.com/sourcegraph/extensions-client-common/node_modules/husky
> node ./bin/uninstall.js

husky
uninstalling Git hooks
done


> [email protected] install /home/sqs/src/github.com/sourcegraph/extensions-client-common/node_modules/husky
> node ./bin/install.js

husky
setting up Git hooks
done

npm WARN @gql2ts/[email protected] requires a peer of graphql@>= 0.10 <1.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @gql2ts/[email protected] requires a peer of graphql@>= 0.10 <1.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of [email protected] - 3 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of typescript@>= 2.3.1 < 3 but none is installed. You must install peer dependencies yourself.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

+ @commitlint/[email protected]
+ @sourcegraph/[email protected]
+ @commitlint/[email protected]
+ [email protected]
+ [email protected]
+ [email protected]
+ [email protected]
+ [email protected]
+ [email protected]
+ [email protected]
+ @sourcegraph/[email protected]
+ @sourcegraph/[email protected]
updated 12 packages and audited 12303 packages in 11.362s
found 0 vulnerabilities

🔑 Fetching CodeCov repository tokens
{ StatusCodeError: 404 - {"error":{"reason":"GitHub API: Not Found","context":null},"meta":{"status":404}}
    at new StatusCodeError (/home/sqs/.npm/_npx/20320/lib/node_modules/@sourcegraph/create/node_modules/request-promise-core/lib/errors.js:32:15)
    at Request.plumbing.callback (/home/sqs/.npm/_npx/20320/lib/node_modules/@sourcegraph/create/node_modules/request-promise-core/lib/plumbing.js:104:33)
    at Request.RP$callback [as _callback] (/home/sqs/.npm/_npx/20320/lib/node_modules/@sourcegraph/create/node_modules/request-promise-core/lib/plumbing.js:46:31)
    at Request.self.callback (/home/sqs/.npm/_npx/20320/lib/node_modules/@sourcegraph/create/node_modules/request/request.js:185:22)
    at Request.emit (events.js:182:13)
    at Request.<anonymous> (/home/sqs/.npm/_npx/20320/lib/node_modules/@sourcegraph/create/node_modules/request/request.js:1161:10)
    at Request.emit (events.js:182:13)
    at IncomingMessage.<anonymous> (/home/sqs/.npm/_npx/20320/lib/node_modules/@sourcegraph/create/node_modules/request/request.js:1083:12)
    at Object.onceWrapper (events.js:273:13)
    at IncomingMessage.emit (events.js:187:15)
    at endReadableNT (_stream_readable.js:1081:12)
    at process._tickCallback (internal/process/next_tick.js:63:19)
  name: 'StatusCodeError',
  statusCode: 404,
  message:
   '404 - {"error":{"reason":"GitHub API: Not Found","context":null},"meta":{"status":404}}',
  error:
   { error: { reason: 'GitHub API: Not Found', context: null },
     meta: { status: 404 } },
  options:
   { resolveWithFullResponse: true,
     baseUrl: 'https://codecov.io/api/',
     json: true,
     headers: { Authorization: 'token REDACTED' },
     uri: 'gh/sourcegraph/extensions-client-common',
     method: 'GET',
     callback: [Function: RP$callback],
     transform: undefined,
     simple: true,
     transform2xxOnly: false },

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions