项目地址: fate0/pychrome
直接使用 Google Chrome Dev Protocol 操作 chrome/headless chrome,比较灵活(前提要过一遍 Protocol) 。 更多信息请看 README.md
想使用 headless chrome 来替换 PhantomJS 作爬虫,我找了一下,Python 好像并没有和 chrome-remote-interface 一样直接使用 Chrome DevTools Protocol 来操作 chrome 的 Package,后面就自己写了一个。
欢迎各种 star、issue 以及 pr (·`ω)
![]() | 1 chengxiao 2017-08-03 10:06:38 +08:00 和 selenium 的区别是??? |
![]() | 2 CryMeatel 2017-08-03 10:10:04 +08:00 赞~ 又见 fate 大神~ |
3 JhZ7z587cYROBgVQ 2017-08-03 10:22:34 +08:00 感觉有点意思,但是看了下代码,是不是支持的功能有点少? |
![]() | 5 fate0 OP @chengxiao 区别是更接近 Dev Protocol 吧,selenium 依赖 ChromeDriver,然而 ChromeDriver 还是使用 Dev Protocol 来操作 chrome (这段话单讲 chrome...) |
![]() | 6 fate0 OP @jason0916 功能多不多,主要看 dev protocol 开放的接口多不多,chrome 61 之后多了个 Network.requestIntercepted,看到这个 method,我就觉得 headless chrome 能够写爬虫了。 |
![]() | 7 knightdf 2017-08-03 10:32:24 +08:00 我觉得单论爬虫 splash 比 selenium 好用点 |
![]() | 8 Fen2g 2017-08-03 10:35:58 +08:00 已 star,公司已经有在用不过是 node。这个 python 希望楼主继续加油! |
![]() | 9 scys 2017-08-03 11:02:13 +08:00 Stared :D 挺好,近来研究自动化家庭框架。用得上。 |
10 slideclick 2017-08-03 11:31:07 +08:00 看楼主破解了 ruby 的混乱工具,搭车问一下,python 有比较好的混乱工具么? |
![]() | 11 fate0 OP @slideclick 简单的方法就是转成 c 代码,需要保密的代码我直接用 go 写 |
12 atsummer 2018-05-11 06:55:07 +08:00 好不容易找到的,已经 star,感谢楼主^_^ |