您的位置:首页 > 产品设计 > UI/UE

pdfkit报错:Exit with code 1 due to network error: ContentNotFoundError

2017-12-24 14:26 1091 查看
try:
if not os.path.exists(item["filename"]):
pdfkit.from_url(item["url"], item["filename"])
else:
print("文件已存在")
except:
# 此处一个Exit with code 1 due to network error: ContentNotFoundError异常
# 此异常为是因为css文件引用了外部的资源,如:字体,图片,iframe加载等。
# 选择忽略此异常
pass


转载自:http://bbs.fishc.com/thread-101282-1-1.html qwc3000的答案
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐