Skip to content

[Fixes #14219] Implement permissons diffing#14218

Merged
giohappy merged 11 commits into
masterfrom
perms_diffing
May 14, 2026
Merged

[Fixes #14219] Implement permissons diffing#14218
giohappy merged 11 commits into
masterfrom
perms_diffing

Conversation

@giohappy
Copy link
Copy Markdown
Contributor

No description provided.

@giohappy giohappy requested a review from sijandh35 May 12, 2026 13:36
@cla-bot cla-bot Bot added the cla-signed CLA Bot: community license agreement signed label May 12, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a structured mechanism for diffing and patching resource permissions by adding a diff method to PermSpecCompact and implementing the PermSpecCompactDiff class. The patch_perms utility and the resource permissions API view were updated to utilize this new logic. Review feedback identified a high-severity issue where missing buckets in a permission spec are incorrectly treated as removals, potentially breaking partial updates. Additionally, an optimization was suggested for the apply method to improve the efficiency of adding new permission entries.

Comment thread geonode/security/permissions.py
Comment thread geonode/security/permissions.py Outdated
@giohappy giohappy linked an issue May 12, 2026 that may be closed by this pull request
@giohappy giohappy changed the title Implement permissons diffing [Fixes #14219]Implement permissons diffing May 12, 2026
@giohappy giohappy changed the title [Fixes #14219]Implement permissons diffing [Fixes #14219] Implement permissons diffing May 12, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented May 12, 2026

Codecov Report

❌ Patch coverage is 98.46939% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 74.76%. Comparing base (a9ac0a2) to head (1346e30).
⚠️ Report is 17 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff             @@
##           master   #14218       +/-   ##
===========================================
+ Coverage   43.23%   74.76%   +31.53%     
===========================================
  Files         960      967        +7     
  Lines       58824    59351      +527     
  Branches     8018     8069       +51     
===========================================
+ Hits        25432    44375    +18943     
+ Misses      32113    13169    -18944     
- Partials     1279     1807      +528     
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@giohappy giohappy merged commit 0afd650 into master May 14, 2026
7 checks passed
@giohappy giohappy deleted the perms_diffing branch May 14, 2026 09:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed CLA Bot: community license agreement signed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implement permissions diffing

2 participants