You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After the PR #200 was merged, I face the following error:
>>> from hazm import Normalizer
>>> h=Normalizer()
>>> h.normalize("hi")
Traceback (most recent call last):
File "/usr/lib/python3.8/sre_parse.py", line 1039, in parse_template
this = chr(ESCAPES[this][1])
KeyError: '\\u'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/ubuntu/.local/lib/python3.8/site-packages/hazm/Normalizer.py", line 75, in normalize
text = self.character_refinement(text)
File "/home/ubuntu/.local/lib/python3.8/site-packages/hazm/Normalizer.py", line 106, in character_refinement
text = pattern.sub(repl, text)
File "/usr/lib/python3.8/re.py", line 327, in _subx
template = _compile_repl(template, pattern)
File "/usr/lib/python3.8/re.py", line 318, in _compile_repl
return sre_parse.parse_template(repl, pattern)
File "/usr/lib/python3.8/sre_parse.py", line 1042, in parse_template
raise s.error('bad escape %s' % this, len(this))
re.error: bad escape \u at position 0
FYI, I am on the latest commit and python 3.7
To fix the error, I am currently using the version before the PR was merged:
After the PR #200 was merged, I face the following error:
FYI, I am on the latest commit and python 3.7
To fix the error, I am currently using the version before the PR was merged:
The text was updated successfully, but these errors were encountered: