Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates libXray’s public Xray wrappers/build pipeline to align with an Xray-core v26.5.9 checkout model, removes the deprecated MPH cache surface area, and adjusts Hysteria2 port-hopping “ports” query serialization to use the PortList.String() format.
Changes:
- Removed MPH cache parameters/APIs (and related test/export hooks) from the Xray wrappers.
- Updated Hysteria2 share-link generation/parsing to use
ports=20000-40000style strings. - Modified the build scripts to clone Xray-core by default (or use a local checkout via a
localarg) and updated Go module/dependency wiring.
Reviewed changes
Copilot reviewed 17 out of 18 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| xray/xray.go | Removes MPH cache API and simplifies env init + run signatures. |
| xray/xray_test.go | Deletes the obsolete MPH cache “unsupported” test. |
| xray/validation.go | Updates InitEnv call signature. |
| xray/ping.go | Updates InitEnv call signature. |
| xray_wrapper.go | Removes MPH cache fields from request types and wrapper calls. |
| share/hysteria_mask.go | Updates parsing of ports into conf.PortList for Hy2 masks. |
| share/generate_share.go | Generates Hy2 ports query using PortList.String(). |
| readme/README.zh_CN.md | Documents new build behavior and local arg usage. |
| README.md | Documents new build behavior and local arg usage. |
| go.mod | Adds local-path replace for xray-core and changes required xray-core version. |
| go.sum | Updates sums to reflect dependency/version changes and local replace. |
| desktop_bin/run.go | Updates RunXray invocation to new signature. |
| build/template/main.gotemplate | Removes the exported CGoBuildMphCache entrypoint. |
| build/main.py | Adds parsing for optional local build argument. |
| build/app/build.py | Implements Xray-core checkout preparation + Go replace wiring; disables revert step. |
| build/app/windows.py | Threads through use_local_xray_core flag. |
| build/app/linux.py | Threads through use_local_xray_core flag. |
| build/app/apple_go.py | Threads through use_local_xray_core flag. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
added 2 commits
May 23, 2026 13:06
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.
No description provided.