Fixed an issue where the Schema Diff Tool incorrectly reported differences due to variations in the order of the privileges. #8032

pull/8806/head
Akshay Joshi 2025-05-29 19:08:56 +05:30
parent 58715daf10
commit 7504f6216a
2 changed files with 4 additions and 0 deletions

View File

@ -28,3 +28,4 @@ Housekeeping
Bug fixes
*********
| `Issue #8032 <https://github.com/pgadmin-org/pgadmin4/issues/8032>`_ - Fixed an issue where the Schema Diff Tool incorrectly reported differences due to variations in the order of the privileges.

View File

@ -54,6 +54,9 @@ def parse_priv_from_db(db_privileges):
"with_grant": db_privileges['grantable'][idx]
})
# Sort the privileges based on the privilege_type to fix
# a Schema Diff issue.
privileges.sort(key=lambda x: x['privilege_type'])
acl['privileges'] = privileges
return acl