Cannot create PAT _with_ scope write:packages _without_ repo scope #26673
-
Per the documentation here: docs.github.comPushing and pulling Docker images - GitHub Docs//docs.github.com/en/packages/guides/pushing-and-pulling-docker-images
However, the UI does not appear to allow this; when write:packages is selected, I am unable to deselect the parent repo scope, or any child repo scope. I am creating a PAT here: https://github.com/settings/tokens/new |
Beta Was this translation helpful? Give feedback.
Replies: 10 comments
-
msk:
Same issue creating my token |
Beta Was this translation helpful? Give feedback.
-
👋 Thanks for reporting this bug. We have an issue to track and fix on our end. In the meantime, you can create the PAT with the repo scope, and then edit it to remove the repo scope. I realize this isn’t ideal, but should be a workaround until the UI fix is done. |
Beta Was this translation helpful? Give feedback.
-
How does one edit an existing PAT’s scopes? There doesn’t seem to be an option to do anything except delete one that I can see. |
Beta Was this translation helpful? Give feedback.
-
The access tokens appear as a list, which I guess is where you can see the delete button. The access token description appears to me as blue, bold text. It is a link. Clicking the link will take you to a page where you can modify the scopes. (I agree this doesn’t seem especially intuitive when there is a button for delete and not for edit). |
Beta Was this translation helpful? Give feedback.
-
Even after creating the PAT, saving it, then attempting to edit the saved PAT’s scopes, it’s not possible to keep |
Beta Was this translation helpful? Give feedback.
-
Yup; it appears that it’s no longer possible to remove the repo scope through the UI if you have the write packages scope (although I’m pretty sure you could do it a few weeks ago). |
Beta Was this translation helpful? Give feedback.
-
It still seems to work when modifying the form through the browser console and then saving it. eg. by using
Not that I recommend doing that 🤠 |
Beta Was this translation helpful? Give feedback.
-
I admire your tenacity! :grinning_face_with_smiling_eyes: A more low tech workaround is to navigate to the following url: Hopefully this issue will be fixed soon! |
Beta Was this translation helpful? Give feedback.
-
Thanks @jcansdale! That worked! Just added delete:packages to the scopes (as mentioned in the docs): https://github.com/settings/tokens/new?scopes=write:packages,delete:packages |
Beta Was this translation helpful? Give feedback.
-
I am new with git, Pleased, I need help to get this sorted out. Thanks in advance!! |
Beta Was this translation helpful? Give feedback.
👋 Thanks for reporting this bug. We have an issue to track and fix on our end.
In the meantime, you can create the PAT with the repo scope, and then edit it to remove the repo scope. I realize this isn’t ideal, but should be a workaround until the UI fix is done.