Skip to content

670 django guardian

Bengfort requested to merge 670-django-guardian into master

This branch does nothing but integrating django-guardian. It is based on !295 (merged).

While doing this, I got a better understanding of what django-guardian can do. My impression is that it is not the right tool for the job:

  • We need to put users in additional groups based on the study context. What django-guardian gives us instead is per-object permissions. Maybe we could wrangle it into what we need, but that would probably be very hacky.
  • django-guardian is a large project that brings a lot of complexity and legacy. Just look at the quirks I had to employ just to get it to work. Plus it uses generic foreign keys which I try to stay away from. It also seems to have issues with multi-database setups

So in conclusion, I think we should stick to the approach outlined in https://git.mpib-berlin.mpg.de/castellum/Castellum-2018/merge_requests/7

Edited by Bengfort

Merge request reports