mirror of
https://github.com/xinnan-tech/xiaozhi-esp32-server.git
synced 2026-11-29 05:09:46 +01:00
修复启动报错问题 (#247)
修复启动时SyntaxWarning: invalid escape sequence '\]'
half_width_punctuations = '!"#$%&\'()*+,-./:;<=>?@[\]^_`{|}~'的报错问题
This commit is contained in:
parent
06c5dba302
commit
ec25c67fa3
1 changed files with 1 additions and 1 deletions
|
|
@ -75,7 +75,7 @@ def get_string_no_punctuation_or_emoji(s):
|
||||||
def remove_punctuation_and_length(text):
|
def remove_punctuation_and_length(text):
|
||||||
# 全角符号和半角符号的Unicode范围
|
# 全角符号和半角符号的Unicode范围
|
||||||
full_width_punctuations = '!"#$%&'()*+,-。/:;<=>?@[\]^_`{|}~'
|
full_width_punctuations = '!"#$%&'()*+,-。/:;<=>?@[\]^_`{|}~'
|
||||||
half_width_punctuations = '!"#$%&\'()*+,-./:;<=>?@[\]^_`{|}~'
|
half_width_punctuations = r'!"#$%&\'()*+,-./:;<=>?@[\]^_`{|}~'
|
||||||
space = ' ' # 半角空格
|
space = ' ' # 半角空格
|
||||||
full_width_space = ' ' # 全角空格
|
full_width_space = ' ' # 全角空格
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue