Overview

I tried Wagtail, so here are my notes on issues I encountered.

I basically followed the tutorial below:

Search Feature

When I added a page with the Japanese title "My First Article," the following search did not return any results.

http://localhost:8000/admin/pages/search/?q=はじめて

On the other hand, the following search did return results. It appeared that partial matching for Japanese is not supported by default.

http://localhost:8000/admin/pages/search/?q=はじめての記事

Wagtail API

Information about the API is available here:

By also adding rest_framework following the site above, I was able to get results as shown below.

However, the hostname in the results was showing as localhost even though the app was running on localhost:8000.

This issue was resolved by modifying it through the admin panel, following this article:

Specifically, I changed the port number on the /admin/sites/ page.

?search Parameter

As with the search feature above, it appeared that exact matching was required for Japanese.

http://localhost:8000/api/v2/pages/?search=はじめての記事

Elasticsearch

I tried integrating with Elasticsearch.

This time I tried AWS OpenSearch, but the following error occurred.

elasticsearch.exceptions.UnsupportedProductError: The client noticed that the server is not Elasticsearch and we do not support this unknown product

A similar issue was raised in the following link, but it appeared to be unsupported at the time.

Summary

This may contain some inaccuracies, but I hope it serves as a useful reference when using Wagtail.