def METHOD_NAME(self):
    if self.namespace is None:
        if hasattr(self, "queryset"):
            self.namespace = _common_namespace_path(self.queryset.model)
        elif hasattr(self, "model"):
            self.namespace = _common_namespace_path(self.model)
        else:
            logger.error(
                "invalid mixin, no namespace, queryset or model set on self"
            )
    return self.namespace