Browse Source

#8 の対応

main
みてるぞ 4 weeks ago
parent
commit
53ba658319
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      update_db.py

+ 2
- 1
update_db.py View File

@@ -16,6 +16,7 @@ import unicodedata
from datetime import datetime, timedelta from datetime import datetime, timedelta
from typing import Any, TypedDict, cast from typing import Any, TypedDict, cast


import jaconv
import requests import requests
from eloquent import DatabaseManager, Model from eloquent import DatabaseManager, Model


@@ -256,7 +257,7 @@ class CommentResult (TypedDict):
def normalise ( def normalise (
s: str, s: str,
) -> str: ) -> str:
return unicodedata.normalize ('NFKC', s).lower ()
return jaconv.hira2kata (unicodedata.normalize ('NFKC', s)).lower ()




if __name__ == '__main__': if __name__ == '__main__':


Loading…
Cancel
Save