Giter Site home page Giter Site logo

Comments (6)

frangio avatar frangio commented on September 26, 2024

Okay, it seems I'm getting the following response from GitHub:

  data:
   { error: 'redirect_uri_mismatch',
     error_description:
      'The redirect_uri MUST match the registered callback URL for this application.',

I had passed a random redirectUrl. Perhaps this function should check for errors in the response, though?

from auth-app.js.

gr2m avatar gr2m commented on September 26, 2024

Agree, it should! I'm currently working on other parts of Octokit but happy to review a pull request if you would like to give it a go.

from auth-app.js.

frangio avatar frangio commented on September 26, 2024

I've been looking at this a bit and to me it seems like a there is a bug in @octokit/request. It should be rejecting the promise but it isn't.

Perhaps the status code in this situation is not being taken as an error. I'll reproduce to see what status it is.

from auth-app.js.

gr2m avatar gr2m commented on September 26, 2024

Ah I remember there was sth super odd about the POST https://github.com/login/oauth/access_token endpoint, the status code is not set correctly in case of an error. I'm sure I fixed this before ... but might got lost or it's in another repo. The POST https://github.com/login/oauth/access_token endpoint is such a pita :/

Can you start a PR with a failing test and we take it from there?

from auth-app.js.

frangio avatar frangio commented on September 26, 2024

Sure! I've opened octokit/request.js#94.

from auth-app.js.

octokitbot avatar octokitbot commented on September 26, 2024

🎉 This issue has been resolved in version 2.4.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

from auth-app.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.