Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
修复
ProxyConfig.ip自动解析错误:IPv6 地址被冒号切成[2001,带用户信息的 URL 会取出用户名,带尾随路径时也会污染主机名。现在使用 URL 解析器提取 hostname,兼容带协议和无协议的服务器地址。现有显式ip、server、认证信息保持不变。List of files changed and why
crawl4ai/async_configs.py、crawl4ai/proxy_strategy.py:同时修复当前和兼容导出的 ProxyConfig。tests/unit/test_proxy_hostname_extraction.py:覆盖 IPv6、认证、SOCKS、IPv4、域名、工厂入口及显式 IP。How Has This Been Tested?
python -m pytest tests/unit/test_proxy_hostname_extraction.py -q:17 passed。tests/proxy/test_proxy_deprecation.py时为 18 passed、1 failed:既有的test_browser_config_proxy_string_emits_deprecation_and_autoconverts未收到弃用警告。已切换到未修改的origin/develop(1f68e5b)复核,该文件同样为 1 failed、1 passed。这是上游既有失败,本补丁未更改警告逻辑或删除测试。git diff --check通过。只验证配置解析,未连接真实代理或启动浏览器。Checklist
AI 披露:本补丁与本地验证由 OpenAI Codex 完成,尚未经人工审阅。