首页 > 解决方案 > HTTPConnectionPool = 80 应该是 8080

问题描述

我正在尝试使用 ZapLibrary ( https://github.com/airesv/robotframework-zaplibrary ) 并且在运行我的 RobotFrameWork 测试时它尝试连接到 port=80

而在 Zap 我的localhost:8080(所以它在端口 8080 上运行)

如何更改或设置它以尝试访问端口 8080

ProxyError: HTTPConnectionPool(host='localhost', port=80): Max retries exceeded with url: http://zap/JSON/core/action/shutdown/?apikey=d9i7specimen (Caused by ProxyError('Cannot connect to proxy.', NewConnectionError('<urllib3.connection.HTTPConnection object at 0x00000193028DF070>: Failed to establish a new connection: [WinError 10061] Kan geen verbinding maken omdat de doelcomputer de verbinding actief heeft geweigerd')))

标签: robotframeworkurllib3

解决方案


1 转到
C:\Users\You\AppData\Local\Programs\Python\Python38\Lib\site-packages\urllib3

2

查看文件、池管理器、连接池和连接

3把80换成8080


推荐阅读