Cannot push to fork's pull request branch even though maintainers are allowed to edit the pull request #199282
Replies: 3 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.
-
|
This 403 error persists because the "Allow maintainer edits" feature is scoped—it does not grant full repository write access. It often fails with Codespaces or Git clients due to security protocols, LFS restrictions, or credential mismatches.
If you must use the command line, ensure you are pushing to the contributor's fork remote (not the base repo): |
Beta Was this translation helpful? Give feedback.
-
|
The "Allow edits from maintainers" checkbox and the 403 you're hitting in Codespaces are actually two separate permission systems, which is the source of the confusion: Why it fails:
This has been reported as a regression by GitHub staff in a related thread (https://github.com/orgs/community/discussions/36357), so you're not missing a setting — it's a real gap in how Codespaces' credential helper resolves fork permissions. Workaround that reliably works:
If you don't want to re-auth, pushing from your local machine (where your normal SSH key or PAT is already configured) instead of from within the Codespace will also work immediately, since local git isn't using the codespace's scoped token. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
🏷️ Discussion Type
Bug
Body
Has anyone else experienced this?
Seeing the check mark and note
I would assume that would mean that I could open the PR in a Codespace, make changes, and push those changes to the PR's source branch. What actually happens is that I get a 403 error.
Beta Was this translation helpful? Give feedback.
All reactions