Ticket #947 (closed enhancement: duplicate)

Opened 3 years ago

Last modified 3 years ago

Move the assignment of roles to a package on package creation to an extension

Reported by: rgrp Owned by:
Priority: awaiting triage Milestone:
Component: ckan Keywords: extension authz
Cc: Repository: ckan
Theme: none


At the moment the assignment of user roles on package creation is done in setup_user_roles method in ckan/model/authz.py and is hard-coded.

This can be a pain to override (you can use a Plugin listening for package create events) and makes some things such as putting system in restricted mode more complex than it should be (see ticket:833).

An elegant solution would be to move this into an Extension this simplifies the code and make it easier for people override (just remove the default extension and plugin your own).

Change History

comment:1 Changed 3 years ago by dread

  • Repository set to ckan
  • Status changed from new to closed
  • Theme set to none
  • Resolution set to duplicate

This was done in #1025 through configuration. Happily you can setup config in an extension, so covers this ticket's aims too.

Note: See TracTickets for help on using tickets.