Prompting to install a github app in a user account not currently active results in a 404 #201203
Replies: 4 comments
-
|
💬 Your Product Feedback Has Been Submitted 🎉 Thank you for taking the time to share your insights with us! Your feedback is invaluable as we build a better GitHub experience for all our users. Here's what you can expect moving forward ⏩
Where to look to see what's shipping 👀
What you can do in the meantime 💻
As a member of the GitHub community, your participation is essential. While we can't promise that every suggestion will be implemented, we want to emphasize that your feedback is instrumental in guiding our decisions and priorities. Thank you once again for your contribution to making GitHub even better! We're grateful for your ongoing support and collaboration in shaping the future of our platform. ⭐ |
Beta Was this translation helpful? Give feedback.
-
|
Yes : ( throwing a generic 404 for this is super lazy on GitHub's part. Their session manager basically just gives up if the active session doesn't perfectly match the target ID, rather than just popping open the account switcher for them. Until they actually fix the redirect logic to handle inactive accounts properly, the only real workaround as an app dev is to just put a giant warning above your install link. You basically have to explicitly tell users to make sure the right account is set to active in their browser before they click the button, otherwise they'll just hit a dead end. |
Beta Was this translation helpful? Give feedback.
-
|
This usually happens because GitHub resolves the currently logged-in user as the install target when the OAuth/App install URL does not pin an explicit account context. Common causes of a 404 during app install prompt
Things to try
For API-driven flows If you can share the install URL pattern (redacted client id) and whether the app is org-only, we can narrow down whether this is expected authorization behavior or a broken install link. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
🏷️ Discussion Type
Bug
💬 Feature/Topic Area
API
Body
endpoint:
/apps/YOUR_APP_NAME/installations/new/permissions?suggested_target_id=<uid>and/apps/YOUR_APP_NAME/installations/new/permissions?target_id=<uid><uid>is the current user, results in a "Approve & Install" screen (or just "Install" iftarget_id)<uid>is an organization the user is a member of, the screen says "Approve, Install, & Request"<uid>is not the current user, results in a 404, even if<uid>is in the account switcher<uid>is an organization the user is not member of, results in a 404Case (3) and (4) are especially annoying when juggling multiple user accounts, especially when all the information is public (e.g. the app is publicly available and the accounts are plain github user or organization accounts not restricted or otherwise hidden).
Beta Was this translation helpful? Give feedback.
All reactions