Contents

Cerberus Access Control

Travis-CI Build Status Codacy Code Quality Status Codacy Code Coverage PyPI Package latest release PyPI Wheel Updates Join the chat at https://gitter.im/dj-CerberusAC/Lobby

Django Ontology Based Access Control Module

License

Software licensed under ISC license.

Installation

pip install django-cerberus-ac

Documentation

On ReadTheDocs

Development

To run all the tests: tox

Contributing

Contributions are welcome, and they are greatly appreciated! Every little bit helps, and credit will always be given.

Bug reports

When reporting a bug please include:

  • Your operating system name and version.
  • Any details about your local setup that might be helpful in troubleshooting.
  • Detailed steps to reproduce the bug.

Documentation improvements

Cerberus Access Control could always use more documentation, whether as part of the official Cerberus Access Control docs, in docstrings, or even on the web in blog posts, articles, and such.

Feature requests and feedback

The best way to send feedback is to file an issue at https://github.com/Deavelleye/dj-CerberusAC/issues.

If you are proposing a feature:

  • Explain in detail how it would work.
  • Keep the scope as narrow as possible, to make it easier to implement.
  • Remember that this is a volunteer-driven project, and that code contributions are welcome :)

Development

To set up dj-CerberusAC for local development:

  1. Fork dj-CerberusAC (look for the “Fork” button).

  2. Clone your fork locally:

    git clone git@github.com:your_name_here/dj-CerberusAC.git
    
  3. Create a branch for local development:

    git checkout -b name-of-your-bugfix-or-feature
    

    Now you can make your changes locally.

  4. When you’re done making changes, run all the tests with one command:

    tox
    
  5. Commit your changes and push your branch to GitHub:

    git add .
    git commit -m "Your detailed description of your changes."
    git push origin name-of-your-bugfix-or-feature
    
  6. Submit a pull request through the GitHub website.

Pull Request Guidelines

If you need some code review or feedback while you’re developing the code just make the pull request.

For merging, you should:

  1. Include passing tests (run tox) [1].
  2. Update documentation when there’s new API, functionality etc.
  3. Add a note to CHANGELOG.rst about the changes.
  4. Add yourself to AUTHORS.rst.
[1]

If you don’t have all the necessary python versions available locally you can rely on Travis - it will run the tests for each change you add in the pull request.

It will be slower though ...

Tips

To run a subset of tests:

tox -e envname -- py.test -k test_myfeature

To run all the test environments in parallel (you need to pip install detox):

detox

Authors

  • Mihnea Gheorghiu
  • Timothée Mazzucotelli

Changelog

0.1.7 (2017-04-19)

  • Add d3.min.js as a static asset to enable it in SSL context.

0.1.6 (2017-04-19)

  • Finish implementation of edit privileges page (efficient below 1000*1000 matrices).

0.1.5 (2017-04-18)

  • Improve admin display.
  • Add allow_update_own_privileges setting.
  • Improve instance_from_ method.
  • Add skip_implicit and log kwargs on can method.
  • Fix role hierarchy chart, use allow_own_update setting.
  • Put back setting_prefix.
  • Add django-app-settings dependency, remove autowidth from data-table.
  • Move access to objects into get to avoid migrate errors.
  • Remove Github pages configuration file.
  • Update django from 1.10.6 to 1.11.
  • Fix migrations (missing __init__.py).

0.1.4 (2017-04-10)

  • Implement Ajax call with notification.
  • Interface no_datatable template with backend.
  • Set namespace to cerberus, improve consistency.
  • Match application name in breadcrumbs.
  • Move application settings into apps module.
  • Change IDs from int to str.
  • Add migration file, avoid loading role instances at start-up.
  • Change mapping setting.
  • Register models in admin.
  • Fix unique constraint with integers default 0.

0.1.3 (2017-04-04)

  • Admin classes added for separation of privileges.
  • Models updated.

0.1.2 (2017-04-03)

  • Added views, templates, and models for testing.
  • Changed Bootstrap version from 3.3.1 to 2.3.1 and JQuery 3.1.1 to 2.1.1.

0.1.1 (2017-02-21)

  • Alpha release on PyPI.

Indices and tables