✨ feat: Compatible with MajsoulMax & 🐛 fix: Subprogress bug in macOS #79
+65
−17
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.
如题。
关于 MajsoulMax 的说明:我尝试了颠倒代理顺序,使用现有的 upstream_proxy 来完成(即 Program -> MahjongCopilot(10999) -> MajsoulMax(23410) -> Server),但发现会出现如下表现:
所以我将 MajsoulMax 前置了以正确完成整个流程,这导致需要修改本仓库的代码,以及 settings.json 的设置项。
关于 subprogress 的说明:
注意到 #59 (comment) 这里的说明,发现非 Windows 下没有
subprocess.STARTUPINFO()这一属性,进而导致判断证书存在失败,永远都要输密码,所以这里需要特判;然后由于 mitmproxy 没有采用默认的路径 ~/.mitmproxy 下的证书,所以需要对比指纹而不是仅仅对比 CN 来确保证书安装成功,故新增一个依赖项。同时,参考 #59 (comment) ,建议锁一下 numpy 的版本,macOS 上锁定后正常,但未在 Windows 上测试,所以暂时没有修改。
相关 Issue: