You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To work-around the missing abstraction in delete_build() logic, we
previously "faked" the user argument with the actual build.copr.owner,
with believe that it will never fail.
That `copr.owner` is actually not guaranteed to have build/admin access
to corresponding 'copr'. Not after a4e7a5a.
Let's invent AutomationUser (having a common ancestor with User)
providing the necessary API to perform permission checks for build
removals, and grant the AutomationUser instances the necessary
permissions.
While on it, tweak the logging and error reporting a bit so there's is
more obvious what is going on.
Fixes: fedora-copr#2523Fixes: fedora-copr#2019
Original issue: https://pagure.io/copr/copr/issue/2019
Opened: 2021-12-22 07:36:38
Opened by: praiskup
In web-UI I get the same message:
https://copr.fedorainfracloud.org/coprs/g/mock/mock/build/1951783/
I'm builder and admin there (+ I'm admin of Copr instance).
praiskup commented at 2021-12-22 08:53:58:
Ah, it is a persistent project. We should have a better message there, like:
Error: Build(s) in persistent projects can not be removed: 1951783.
praiskup commented at 2021-12-22 08:57:06:
(FTR, I removed that build manually, as I believe the persistent flag is there by mistake)
The text was updated successfully, but these errors were encountered: