Correct creation model with RoleChain import roles

for right work this functional

  1. question = models.Question(data, role=role)
class Question(Model):
    import_roles = {
            'bidder': (
                RoleChain() +
                blacklist('any_field') +
                StatusRole({'any_status'}, whitelist('another_field'))
            )
        }
  1. now it fails with error AttributeError: 'RoleChain' object has no attribute 'fields'
Edited by Andrey Veltischev

Merge request reports