Error in Meilisearch while deleting a course

Hi,
while deleting a course with: `tutor local run cms ./manage.py cms delete_course course-v1:COURSENAME’ I run into the following exception.

MeiliSearch should be version: v1.8.4
Which version am I supposed to run, and how to update?

Are you sure you want to delete course course-v1:COURSENAME? [y/N] y
Are you sure? This action cannot be undone! [y/N] y
2025-06-02 05:17:54,145 INFO 1 [xmodule.modulestore.split_mongo.split] [user None] [ip None] split.py:2614 - deleting course from split-mongo: course-v1:COURSENAME
2025-06-02 05:17:54,190 ERROR 1 [django.dispatch] [user None] [ip None] dispatcher.py:213 - Error calling listen_for_course_delete in Signal.send_robust() (MeilisearchApiError. Error code: invalid_search_filter. Error message: Attribute `course` is not filterable. Available filterable attributes are: `modes org enrollment_end catalog_visibility language`.
1:7 course = "course-v1:COURSENAME". Hint: It might not be working because you're not up to date with the Meilisearch version that search call requires. Error documentation: https://docs.meilisearch.com/errors#invalid_search_filter Error type: invalid_request)
Traceback (most recent call last):
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/_httprequests.py", line 135, in __validate
    request.raise_for_status()
  File "/openedx/venv/lib/python3.11/site-packages/requests/models.py", line 1024, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: http://meilisearch:7700/indexes/tutor_course_info/search

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/openedx/venv/lib/python3.11/site-packages/django/dispatch/dispatcher.py", line 211, in send_robust
    response = receiver(signal=self, sender=sender, **named)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/openedx/edx-platform/cms/djangoapps/contentstore/signals/handlers.py", line 165, in listen_for_course_delete
    CourseAboutSearchIndexer.remove_deleted_items(course_key)
  File "/openedx/edx-platform/cms/djangoapps/contentstore/courseware_index.py", line 677, in remove_deleted_items
    response = searcher.search(field_dictionary=cls._get_location_info(structure_key))
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/openedx/venv/lib/python3.11/site-packages/search/meilisearch.py", line 179, in search
    meilisearch_results = self.meilisearch_index.search(query_string, opt_params)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/errors.py", line 75, in wrapper
    raise exc
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/errors.py", line 72, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/index.py", line 304, in search
    return self.http.post(
           ^^^^^^^^^^^^^^^
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/_httprequests.py", line 88, in post
    return self.send_request(requests.post, path, body, content_type, serializer=serializer)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/_httprequests.py", line 68, in send_request
    return self.__validate(request)
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/openedx/venv/lib/python3.11/site-packages/meilisearch/_httprequests.py", line 138, in __validate
    raise MeilisearchApiError(str(err), request) from err
meilisearch.errors.MeilisearchApiError: MeilisearchApiError. Error code: invalid_search_filter. Error message: Attribute `course` is not filterable. Available filterable attributes are: `modes org enrollment_end catalog_visibility language`.
1:7 course = "course-v1:COURSENAME". Hint: It might not be working because you're not up to date with the Meilisearch version that search call requires. Error documentation: https://docs.meilisearch.com/errors#invalid_search_filter Error type: invalid_request
2025-06-02 05:17:54,433 INFO 1 [openedx.core.djangoapps.content.course_overviews.signals] [user None] [ip None] signals.py:53 - DELETE_COURSE_DETAILS triggered upon course_deleted signal. Key: [course-v1:COURSENAME]
2025-06-02 05:17:54,436 INFO 1 [openedx.core.djangoapps.content.block_structure.store] [user None] [ip None] store.py:116 - BlockStructure: Deleted from cache and store; block-v1:COURSENAME+type@course+block@course.```

If someone ever has the same issue, I fixed it by connecting to the Meilisearch container and deleting the entries by hand.

curl -X DELETE 'http://localhost:7700/indexes/tutor_course_info/documents/THE_pk1_VALUE_OF_THE COURSE' -H 'Authorization: Bearer YOUR_TOKEN'