AirtestProject / AirtestProject/AirtestIDE
print 输出函数 乱码问题
- Lenguaje dominante
- Sin datos de lenguaje
- Estrellas
- 236
- Forks
- 40
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
测试开发环境AirtestIDE使用问题
bug描述
print 函数在AirtestIDE 中输出,会报
UnicodeEncodeError: 'gbk' codec can't encode character '\xa9' in position 83097: illegal multibyte sequence
但是在idea 的编辑器中编写相同的代码,可以正确解析
# -*- encoding=utf8 -*-
__author__ = "admin"
import requests
import string, time
from bs4 import BeautifulSoup
#https://v.qq.com/s/videoplus/218751049
#根据指定的URL获取网页内容
def gethtml(url):
response = requests.get(url)
response.encoding = "utf-8"
print(response.text)
if __name__ == "__main__":
str = "https://v.qq.com/s/videoplus/218751049"
html = gethtml(str)
**python 版本:** `python3.7`
**操作系统:** `Windows10 64bit`
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Evaluación
Este issue todavía no se ha evaluado.