Migrate views from ds.permissions to ds.actions, refs #2528

Updates all permission debugging views to use the new ds.actions dict
instead of the old ds.permissions dict. Changes include:

- Replace all ds.permissions references with ds.actions
- Update field references: takes_database/takes_resource → takes_parent/takes_child
- Remove default field from permission display
- Rename sorted_permissions to sorted_actions in templates
- Remove source_plugin from SQL queries and responses
- Update test expectations to not check for source_plugin field

This aligns the views with the new Action dataclass structure.
This commit is contained in:
Simon Willison 2025-10-25 08:53:03 -07:00
commit 5c6b76f2f0
5 changed files with 15 additions and 30 deletions

View file

@ -247,7 +247,6 @@ async def test_rules_json_response_structure(ds_with_permissions):
assert "resource" in item
assert "allow" in item
assert "reason" in item
assert "source_plugin" in item
@pytest.mark.asyncio