github / VisualStudio

GitHub Extension for Visual Studio
https://visualstudio.github.com
MIT License
2.37k stars 1.21k forks source link

Failed auto pair to mac will sometimes run emulator on wrong NIC #2673

Open JeffIPV opened 2 years ago

JeffIPV commented 2 years ago

Description

Once you have paired to a mac, visual studio will automatically try pair to the mac on startup.

In my instance the pair to mac happens through a vpn connection to a mac at my workplace. It will fail the auto pair because I don't or want to have my vpn enabled. (not doing maui ios work)

Any builds I do, assume that I am trying to got through the VPN nic.

Reproduction Steps

Have a project the tries to reach something some endpoint (google.com, an ip, etc) better if only available thru another nic.

successfully pair to a mac through a vpn or another nic. Relaunch Visual Studio to confirm it does an auto pair. Close visual studio. Disable the vpn or NIC. Reopen visual studio. See that auto pair fails

Run the project and see that it will fail to get endpoint because its using a disabled NIC. See emulated Android started from the run is not picking up wifi

Workaround Have the android simulator open and connected to wifi before running from Visual Studio