RosiKyu opened a new issue, #14849:
URL: https://github.com/apache/cloudstack/issues/14849

   ### problem
   
   An account that was added to a project with a user role (for example 
`addUserToProject roletype=Admin`), whose project was then deleted on a version 
without the fix from #14150, cannot be deleted after upgrading to a version 
with that fix. `deleteAccount` fails with "Unable to delete account [5], 
because it manages the following project(s): [1]. Please, remove the account 
from these projects or demote it to a regular project role first." The project 
named in the error is no longer listed in `listProjects`, so the account cannot 
be removed from it.
   
   ### versions
   
   Seen when upgrading from 4.20.3.1 to the #14150 PR packages (4.20 branch), 
KVM, 2 hosts.
   
   ### The steps to reproduce the bug
   
   1. On 4.20.3.1, create an account with a User role, create a project, and 
add the account's user to the project with `addUserToProject roletype=Admin`.
   2. Delete the project with `deleteProject cleanup=true`. The project is 
removed.
   3. Upgrade to a version that includes #14150.
   4. Disable and delete the account.
   
   
   ### What to do about it?
   
   **Expected Result:** the account is deleted, as it is for projects deleted 
after the upgrade.
   
   **Actual Result:** `deleteAccount` fails with the error above, and the 
project it names is not listed in `listProjects`.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to