mrabarnett / mrab-regex

Other
436 stars 49 forks source link

No module named 'unicodedata' error #488

Open Remiol opened 1 year ago

Remiol commented 1 year ago

I receive a regex error in all python scripts since Python 3.11.1. When I remove Python 3.11.1 and reinstall Python 3.11 the error is gone.

This is the error I receive.

c:\Python311\Lib\site-packages\regex\__init__.py, line 1, in <module>
   from .regex import *
c:\Python311\Lib\site-packages\regex\regex.py, line 421, in <module>
   import regex._regex_core as _regex_core
c:\Python311\Lib\site-packages\regex\_regex_core.py, line 18, in <module>
   import unicodedata
ModuleNotFoundError: No module named 'unicodedata'

What does this error mean?

ps: my OS = Win 11 home Thanks for this very useful extension.

mrabarnett commented 1 year ago

unicodedata is part of the standard distribution of Python.

Can you import unicodedata?

I can't reproduce the problem. If it works in Python 3.11 then it should also work in all Python 3.11.x.

Remiol commented 1 year ago

You're right. I have discovered that it is a Vim problem. Sorry. ":py3 import regex" does give this error in vim but "import regex" does work in "idle" A few other extensions do work fine. Don't know what's happening.