-
Notifications
You must be signed in to change notification settings - Fork 0
Add BanditURLOverrides to ConfigResponse #19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||
|---|---|---|---|---|---|---|---|---|
|
|
@@ -68,6 +68,12 @@ type ConfigResponse struct { | |||||||
| Options O.Options `json:"options,omitempty"` | ||||||||
| SmartRouting SmartRoutingRules `json:"smart_routing,omitempty"` | ||||||||
| AdBlock AdBlockRules `json:"ad_block,omitempty"` | ||||||||
|
|
||||||||
| // BanditURLOverrides maps outbound tags to per-proxy callback URLs for | ||||||||
| // the bandit Thompson sampling system. When set, these override the | ||||||||
| // default MutableURLTest URL for each specific outbound, allowing the | ||||||||
| // server to detect which proxies successfully connected. | ||||||||
| BanditURLOverrides map[string]string `json:"bandit_url_overrides,omitempty"` | ||||||||
| } | ||||||||
|
|
||||||||
| type ConfigRequest struct { | ||||||||
|
|
@@ -83,4 +89,5 @@ type ConfigRequest struct { | |||||||
| Locale string `json:"locale,omitempty"` | ||||||||
| Protocols []string `json:"protocols,omitempty"` | ||||||||
| MetricsOptedIn bool `json:"metrics_opted_in,omitempty"` | ||||||||
| Version string `json:"version,omitempty"` | ||||||||
|
||||||||
| Version string `json:"version,omitempty"` | |
| // AppVersion is the version of the Lantern client application making this request. | |
| AppVersion string `json:"app_version,omitempty"` |
Copilot
AI
Feb 20, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR description only mentions adding BanditURLOverrides to ConfigResponse, but this diff also adds Version to ConfigRequest. If Version is intentional, please update the PR description (and any companion PR references) to reflect this additional API surface change; otherwise, consider dropping it from this PR to keep scope aligned.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are serialization tests for
ConfigResponse/ConfigRequest(seetypes_test.go), but they don’t exercise the newly added fields. Please extend the existing tests to cover JSON round-tripping forBanditURLOverridesandConfigRequest.Version, and verifyomitemptybehavior (field absent when empty/nil).