Splash resource_timeout 属性
2024-08-27 02:14:03
resource_timeout属性用于设置加载的超时时间,单位是秒,如果设置为 0 代表不检测超时,如下,设置超时时间为 0.1 秒:
function main(splash)
splash.resource_timeout = 0.1
assert(splash:go('https://www.taobao.com/'))
return splash:png()
end
执行之后抛出异常:
{
"description": "Error happened while executing Lua script",
"info": {
"type": "LUA_ERROR",
"source": "[string \"function main(splash)\r...\"]",
"message": "Lua error: [string \"function main(splash)\r...\"]:3: network5",
"error": "network5",
"line_number": 3
},
"type": "ScriptError",
"error": 400
}
最新文章
- Django模板与Vue.js冲突问题
- [LintCode] Maximum Subarray 最大子数组
- Atitit 基于dom的游戏引擎
- 【CodeForces 589F】Gourmet and Banquet(二分+贪心或网络流)
- 9----Lua中的面向对象
- Java for LeetCode 153 Find Minimum in Rotated Sorted Array
- Python学习之路——类
- gulp快速入门
- ORACLE查看和更改的最大连接数
- ASP.NET Web Service中使用Session 及 Session丢失解决方法 续
- IWorkSpace接口介绍
- 百度推送-sitemap-使用playframework框架实现-java
- node.js 模板 ejs 转
- 微信网页分享 jssdk config:invalid signature 签名错误
- 在Linux上安装ant环境
- react组建生命周期
- python 二分查找法
- nginx+tomcat9+redisson+redis+jdk1.8简单实现session共享
- 2017-2018-2 20165237 实验三《 敏捷开发与XP实践》实验报告
- hdu1698 Just a Hook 【区间修改】(模板题)