Skip the GCP availability lookup on non-interactive deploys
Split out of #7054. Two-line change in the hosting CLI.
Changes
_resolve_deploy_provider called hosting.gcp_deploy_available(client) before checking interactive; a non-interactive deploy then threw the answer away and kept the app's current provider. Only make the request when a prompt can actually use it. Tests cover the non-interactive path for apps on no provider, fly, and gcp, and assert the interactive prompt still performs the lookup.
Measurement
One fewer authenticated HTTPS request (GET /orgs/{org}/provider-accounts/gcp/status) per non-interactive deploy, i.e. every CI deploy. I could not time it from the sandbox this was prepared in (the hosting host is blocked by its network policy); it is one round trip to build.reflex.dev, serialized before the export starts.
Type of change
- Performance improvement (non-breaking)
Checklist
- Tests added for the change; the full
tests/unitssuite passes locally except the 14reflex_bench/drivers/test_browser.pycases that need a Playwright browser launch, which fail identically on untouchedmainin this sandbox -
ruff check,ruff format --check,codespell, andpyright reflex testspass locally - News fragment added for every package touched
https://claude.ai/code/session_018nWB9r2HcC5tkT72UxWgGj
Generated by Claude Code