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

Org flag raises GraphQL permissions error #72

Open
RichardLitt opened this issue Feb 21, 2018 · 4 comments
Open

Org flag raises GraphQL permissions error #72

RichardLitt opened this issue Feb 21, 2018 · 4 comments
Labels

Comments

@RichardLitt
Copy link
Member

Using the --org flag causes a GraphQL permissions error.

🐕  node src/cli.js -o orbitdb -r example-orbitdb-todomvc
Error: Graphql error: {
  "data": null,
  "errors": [
    {
      "message": "Your token has not been granted the required scopes to execute this query. The 'name' field requires one of the following scopes: ['read:org'], but your token has only been granted the: ['repo', 'user'] scopes. Please modify your token's scopes at: https://github.com/settings/tokens.",
      "locations": [
        {
          "line": 122,
          "column": 1
        }
      ]
    }
  ]
}
    at parseResponse (/Users/richard/src/name-your-contributors/src/graphql.js:414:11)
    at <anonymous>

This works if you use -u instead.

@daviddias
Copy link

daviddias commented Dec 12, 2018

Hit this issue as well, however, changing to -u doesn't seem to work for github orgs. Were you able to get it working @RichardLitt ?

With -u, I get the following error:

» name-your-contributors -u ipfs > contributors.json
Error: Command failed: git config --get remote.origin.url

    at ChildProcess.exithandler (child_process.js:289:12)
    at ChildProcess.emit (events.js:182:13)
    at maybeClose (internal/child_process.js:962:16)
    at Socket.stream.socket.on (internal/child_process.js:381:11)
    at Socket.emit (events.js:182:13)
    at Pipe._handle.close (net.js:606:12)

@RichardLitt
Copy link
Member Author

Hmm. Not sure at the moment. You could use https://github.com/kevva/github-repositories to get a list of all of the repos you need, which could sidestep the issue for now, I think.

@Berkmann18
Copy link
Collaborator

I just tried running ./src/cli.js -o mntnr with a token that had read:project, repo and read:org permissions and got the same error about the INSUFFICIENT_SCOPES.

@lynxlynxlynx
Copy link

Started getting this as well (on 3.4.0), even after updating the token with more permissions. Regenerating it didn't help.

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

No branches or pull requests

4 participants