Chrome! The only Chrome revision guaranteed to is r575458"/>
while trying to connect to Chrome! The only Chrome revision guaranteed to is r575458
问题描述与解决
使用puppeteer启动chrome会出现Error: Timed out after 30000 ms while trying to connect to Chrome! The only Chrome revision guaranteed to work is r575458错误。根据官方文档,每一个puppeteer版本对应一个版本的chromium。当我们打开puppeteer的package文件时也会看到。
"name": "puppeteer","puppeteer": {"chromium_revision": "575458"},
当遇到这种错误,先尝试用puppeteer去启动相应的chromium版本。
如果还是报这个错误,尝试去掉启动参数。我centos7上,升级puppeteer到
1.18.1时,使用了相对应的chromium版本,但还报这个错。当时启动参数如下。只保留能启动chroium用到的必要参数,随后发现这个版本下加了
–remote-debugging-port=9222选项,就会报这个错。
args: ['--disable-setuid-sandbox','--no-sandbox','--ignore-certificate-errors','--remote-debugging-port=9222','--disable-web-security'],
总结
1.去掉多余参数,最简化问题,看是否首参数影响。
2.查阅官方文档及相关问题及注意事项
3.尝试自己调试
4.向官方提出问题
更多推荐
while trying to connect to Chrome! The only Chrome revision guaranteed to is r57
发布评论