bug#42
Open
drgtdrgtgsd wants to merge 1 commit into
Open
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.
发现问题
您好,感谢您开发这个好用的工具!我在 Windows 环境下使用时遇到了一些兼容性 Bug,目前已经自行在本地修复,特地反馈给您供参考w
仅限于Windows环境,mac和Linux我暂时没有测试
在 Windows PowerShell 中,默认的
curl实际上是Invoke-WebRequest的别名,不支持脚本里的参数,导致二进制测速文件下载失败。当出现下载失败或其他错误时,脚本会调用
input()。如果是自动化运行等非交互式环境,会导致进程永久卡住挂起。建议的修复方案
我修改了
cloudflare_speedtest.py,主要改动如下:subprocess里的curl统一改为curl.exe。input()包装在if sys.stdin.isatty():中。现在windows环境下能进行测速
系统:Windows11 25H2
可能讲的不是很好,我第一次尝试这样,如有什么问题,请多指正谢谢