def post(self, request, project_id, *args, **kwargs):
        """
        Creates the user group.

        Parameter
        ---------
        request : django.http.HttpRequest
            Object representing the request.
        project_id : int
            identifies the project in the data base

        Returns
        -------
        django.http.HttpResponse
            Rendered template
        """

        self.object = None
        context = self.get_context_data(*args, **kwargs)
        project = context.get('project')

        if project is not None:
            cannot_create = 'New user groups cannot be created.'

            if project.islocked:
                messages.error(
                    self.request,
                    cannot_create % 'The project is locked. %s'
                )
            else:
                return super(UserGroupCreate, self).post(
                    request, project_id, *args, **kwargs
                )

        return self.render_to_response(context)
dataset/ETHPy150Open ExCiteS/geokey/geokey/users/views.py/UserGroupCreate.post/swapped operands of `%`