This commit is contained in:
Jing Ling
2020-03-19 00:03:32 +08:00
parent f8b6f5ece2
commit 991befb4c3
2 changed files with 5 additions and 5 deletions
+2 -2
View File
@@ -176,8 +176,8 @@ def request_callback(future, index, datas):
datas[index]['header'] = str(dict(headers))[1:-1]
if isinstance(text, str):
title = get_title(text).strip()
datas[index]['title'] = utils.remove_string(title)
datas[index]['response'] = utils.remove_string(text)
datas[index]['title'] = utils.remove_invalid_string(title)
datas[index]['response'] = utils.remove_invalid_string(text)
def get_connector():
+3 -3
View File
@@ -277,7 +277,7 @@ def mark_subdomain(old_data, now_data):
return mark_data
def remove_string(string):
def remove_invalid_string(string):
# Excel文件中单元格值不能直接存储以下非法字符
return re.sub(r'[\000-\010]|[\013-\014]|[\016-\037]', r'', string)
@@ -348,8 +348,8 @@ def get_timestamp():
return int(time.time())
def get_classname(clsobj):
return clsobj.__class__.__name__
def get_classname(classobj):
return classobj.__class__.__name__
def python_version():