Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Py_UNICODE with Py_UCS4 #25

Closed
wants to merge 1 commit into from

Conversation

tpdn
Copy link

@tpdn tpdn commented Oct 9, 2023

fix #24

Currently mojimoji cannot be installed on Python 3.12.
This diff avoids this problem by replacing Py_UNICODE with Py_UCS4.

https://docs.python.org/3.12/c-api/unicode.html

Pytest results with Python 3.12 on my MacBook

============================================= 15 passed in 0.01s =============================================
(hoge-3.12) [15:36:38] tpdn@GrandMacdoBookProXP /Users/tpdn/gitlab/tpdn/hoge  
> pytest mojimoji/test_mojimoji.py
============================================ test session starts =============================================
platform darwin -- Python 3.12.0, pytest-7.4.2, pluggy-1.3.0
rootdir: /Users/tpdn/gitlab/tpdn/hoge/mojimoji
collected 15 items                                                                                           

mojimoji/test_mojimoji.py ...............                                                              [100%]

@ikuyamada
Copy link
Member

Thank you very much for submitting the pull request!
I fixed mojimoji.pyx based on the suggested changes in this PR.

@ikuyamada ikuyamada closed this Jan 12, 2024
@tpdn tpdn deleted the fix_for_py312 branch January 14, 2024 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot install on Python 3.12
2 participants