fix(config): a misspelled field under proxies is an error - #185
Merged
Merged
Conversation
fylorn
force-pushed
the
fix/proxy-unknown-fields
branch
from
September 24, 2026 17:05
72521fd to
9685628
Compare
Every other section of config.yaml refuses a field it does not know, so a typo is reported instead of silently changing behavior. `proxies` and `proxies[].auth` did not: `typ: http` was dropped and the proxy was dialled as socks5h, and `passwd:` was dropped and the proxy answered 407, with a file that looked right. One test fixture was already hit by this: it wrote `kind: http` (the Rust field name, not the YAML one), which was ignored. It now writes `type`. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
fylorn
force-pushed
the
fix/proxy-unknown-fields
branch
from
September 24, 2026 17:23
9685628 to
e125590
Compare
Merged
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.
Every section of
config.yamlrefuses unknown fields (deny_unknown_fields) so a typo is reported rather than silently ignored.proxies[]andproxies[].authwere the exception:typ: httpwas dropped and the proxy was dialled as the defaultsocks5h;passwd:was dropped and the proxy answered 407. Found while writing the configuration reference (#183), which states the rule for the whole file.ProxyandProxyAuthget#[serde(deny_unknown_fields)], with a test that the error names the misspelled field.tw-controltest fixture wrotekind: http(the Rust field name; the YAML key istype), which had been silently ignored. Fixed.The desktop app is unaffected: it saves proxies through the typed
ProxyInput, not raw YAML.🤖 Generated with Claude Code