简体   繁体   English

我可以使用 python 访问谷歌浏览器开发者工具的网络选项卡吗?

[英]can I access to network tab of google chrome developer tools with python?

I tried to get some information in a request in some web pages and I need some information that can find it from network tab of google chrome developer tools for example when I click on followers on Instagram web, the browser sends a GET method with a parameter named "query_id", I want to find it, I can find it in network tab in google chrome dev tools but now I want to find this parameter with python, how can I do it?我试图在某些网页的请求中获取一些信息,并且我需要一些可以从 google chrome 开发者工具的网络选项卡中找到它的信息,例如当我点击 Instagram 网站上的关注者时,浏览器会发送一个带有参数的 GET 方法名为“query_id”,我想找到它,我可以在谷歌浏览器开发工具的网络选项卡中找到它,但现在我想用python找到这个参数,我该怎么做? is there any way that I access network tab with python?有什么办法可以用python访问网络选项卡吗?

Would a Node.js solution work instead? 可以使用Node.js解决方案吗? Puppeteer may help you accomplish this task. 木偶可能会帮助您完成此任务。

If not, search around for Python libraries that interact with the Chrome DevTools Protocol . 如果不是,请搜索与Chrome DevTools协议交互的Python库。 This protocol gives you a lot of low-level information about pages. 该协议为您提供了许多有关页面的底层信息。

I used Selenium to do this.我使用硒来做到这一点。 Try logging the performance and find the information you used to find in the network tab.尝试记录性能并在网络选项卡中查找您以前查找的信息。

Check out this answer below:在下面查看这个答案:

https://stackoverflow.com/a/68363046/8491363 https://stackoverflow.com/a/68363046/8491363

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何使用 python 在 chrome 开发人员工具中访问网络选项卡 - How to access network tab in chrome developer tools using python 如何使用 python selenium 访问 google chrome 开发人员工具上的安全面板? - How to access Security panel on google chrome developer tools with python selenium? Python 请求标头不起作用 - 检查 Chrome 开发者工具 -> 网络 - Python requests header not working - Checked Chrome developer tools -> Network 如何使用 Python 访问 Chrome Devtools 网络选项卡中的值? - How to access values in the Chrome Devtools network tab using Python? Python selenium 获取“开发者工具”→网络→媒体日志 - Python selenium get "Developer Tools" →Network→Media logs Cookie未显示在Chrome开发者工具(Django Python)中 - Cookie does not show up in Chrome Developer Tools (Django Python) 有没有办法通过 Python 加载网页的网络活动(您可以在 Chrome Dev Tools 上看到)? - Is there a way to get a webpage's Network activity (which you can see on Chrome Dev Tools) on load via Python? 如何使用 python 请求获取网络选项卡? - How can i get the network tab with python requests? 来自谷歌开发者工具的 JSON 链接在 Python(或浏览器)中不起作用 - JSON link from google developer tools not working in Python (or in browser) Selenium 相当于使用 Google Chrome 开发者工具并在最外面的 HTML 元素上单击“复制 OuterHTML”? - What is the Selenium equivalent of using Google Chrome Developer Tools and clicking "Copy OuterHTML" on the outermost HTML element?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM