fetch leaves an existing origin/HEAD alone when the upstream default changes and the old branch survives, so the local ref could still send the wrong base. Ask origin first and use origin/HEAD only when origin cannot answer.
Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com Claude-Session: https://claude.ai/code/session_01XJeHKftfKHD7hSi6ZxJww8 Entire-Checkpoint: 01M673VT0BAZJ62KE71WSQ43SY