Check if owner account exists
What does this MR do and why?
Check if owner account exists. This attempts to fix a bug on project creation/deletion being interrupted because of a pending owner invitation.
See #387157 (comment 1699919587)
This MR should help prevent the problem from occurring further (See internal logs on GitLab.com), helping to prevent any more Support tickets or issues being created.
This does not fix the projects that are in the "half created" state. These projects may need to be deleted manually.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
How to set up and validate locally
The following occurs before this MR is merged:
- Create a new private group.
- Invite a user to the group via email, add them as an owner.
- Leave the invitation as
Pending
. (Don't create a user account from the invitation) - Create a new project under the group.
- Project returns a 404 as a normal user.
- Project can be viewed as an admin user.
After this MR is merged, the project should no longer 404 as the normal user.