Skip to content

fix(updater): route update check/download/install through the app proxy#188

Merged
su-fen merged 1 commit into
mainfrom
fix/app-proxy-updater-coverage
Jul 21, 2026
Merged

fix(updater): route update check/download/install through the app proxy#188
su-fen merged 1 commit into
mainfrom
fix/app-proxy-updater-coverage

Conversation

@su-fen

@su-fen su-fen commented Jul 21, 2026

Copy link
Copy Markdown
Member

Summary

  • github_client() (manifest existence probe + release feed lookup) already routed through the app proxy, but build_updater() left tauri-plugin-updater's own internal client untouched — the authoritative updater.check() and update.download_and_install() connected to GitHub directly, ignoring the app proxy setting (or silently picking up unrelated OS-level proxy env vars).
  • Added system_proxy::current_proxy_url() to resolve the current app-proxy config into a Url for consumers that configure their own client (rather than reusing client_builder()), and wired it into build_updater(): .proxy(url) when enabled, .no_proxy() when disabled, matching the "single source of truth, no OS env leakage" behavior used elsewhere in system_proxy.rs.
  • Since UpdaterBuilder's proxy/no_proxy fields flow through to both Updater::check() and the resulting Update::download_and_install(), this one change covers the entire update flow (check, download, install).

Test plan

  • cargo test for services::system_proxy::tests::* (8 tests, incl. new current_proxy_url_reflects_mode) and commands::app_commands::update::tests::* (5 tests) — all pass
  • cargo check / cargo clippy — no new warnings

🤖 Generated with Claude Code

github_client() already followed the app proxy for manifest lookup, but
build_updater() left tauri-plugin-updater's own client untouched, so the
authoritative check() and download_and_install() connected to GitHub
directly (or silently picked up unrelated OS proxy env vars). Resolve the
same app-proxy config into a Url for the updater builder so the whole
update flow behaves consistently.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@su-fen
su-fen merged commit 24bebca into main Jul 21, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant