Skip to content

Conversation

@stuartmaxwell
Copy link
Owner

Started this with the intention of exposing the plugin storage, but this uncovered some deeper issues.

Fixes #150

  • For starters, the plugin storage was already exposed in the admin but only to super admins.
  • I created a new group called admin that would get all DJ Press permissions, including the plugin storage.
  • Then I realised that I should prefix my group names in case the existing Django site already used groups with overlapping names.
  • All DJ Press groups are now prefixed with djpress_
  • Obviously this is a breaking change and people will need to re-add themselves (and others) to the new groups.
  • I kept the logic to create/update the groups in the post_migrate signal
  • But I moved this logic to its own module
  • I also added a management command to create/update the groups manually, although this shouldn't be needed if the migrate command is run as part of the app start-up.
  • Added/updated all tests
  • Added/updated docs.

Creates groups and permissions. Moved this from signals.py and added the
admin role.
Introduce a fourth group (djpress_admin) and expand the permissions
matrix to include an Admin column and management permissions
(categories, tags, media, plugin storage). Add Group Setup and Assigning
Users sections with migrate/djpress_setup_groups commands and a shell
example. Document djpress_ prefix for group names.
@stuartmaxwell stuartmaxwell self-assigned this Nov 4, 2025
@codecov
Copy link

codecov bot commented Nov 4, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.

Files with missing lines Coverage Δ
src/djpress/__init__.py 100.00% <100.00%> (ø)
src/djpress/admin.py 100.00% <100.00%> (ø)
...jpress/management/commands/djpress_setup_groups.py 100.00% <100.00%> (ø)
src/djpress/permissions.py 100.00% <100.00%> (ø)
src/djpress/signals.py 100.00% <100.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@stuartmaxwell stuartmaxwell merged commit 1582a97 into main Nov 4, 2025
7 checks passed
@github-project-automation github-project-automation bot moved this to Done in DJ Press Nov 4, 2025
@stuartmaxwell stuartmaxwell deleted the expose_plugin_storage_admin branch November 4, 2025 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Expose the plugin storage

2 participants