code: def can_access(self, permission_name, view_name):
          
          user = g.user
          if user.is_anonymous:
              return self.is_item_public(permission_name, view_name)
          return self._has_view_access(user, permission_name, view_name)
docs: Protecting from has_access failing from missing perms/view