Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot pair to Mac after Visual Studio 17.11.0 update. #21036

Closed
dajbych opened this issue Aug 14, 2024 · 14 comments
Closed

Cannot pair to Mac after Visual Studio 17.11.0 update. #21036

dajbych opened this issue Aug 14, 2024 · 14 comments
Labels
move-to-vs-feedback Tells automation to ask the person to use VS Feedback to report the issue
Milestone

Comments

@dajbych
Copy link

dajbych commented Aug 14, 2024

Apple platform

iOS

Framework version

net8.0-*

Affected platform version

VS 17.11.0

Description

After an update to Visual Studio 17.11.0, I'm not able to connect/pair to Mac.

Steps to Reproduce

  1. Click to Pair to Mac
  2. Click to Connect...

Did you find any workaround?

Removing the ~/Library/Caches/Xamarin/XMA/SDKs/dotnet/ folder on the Mac did not help.

Build logs

Checking host configuration for connecting to 'Václav’s Mac mini'...
Checking SSH configuration...
Initializing environment...
Checking available disk space...
Verifying dotnet runtime installation...
Checking if Rosetta is installed...
Checking Mono installation...
Checking host configuration for connecting to 'Václav’s Mac mini'...
Host 'Václav’s Mac mini' is configured correctly
Starting connection to 'Václav’s Mac mini'...
Checking Broker 17.11.0.93 installation...
Starting Broker 17.11.0.93 in port 56569...
Broker 17.11.0.93 started successfully
Starting connection to 'Václav’s Mac mini'...
SSH connection to 'Václav’s Mac mini' has been established...
Starting registered Agents: IDB 17.11.0.93...
Starting IDB 17.11.0.93...
Checking IDB 17.11.0.93 installation...
Starting IDB 17.11.0.93 in port 56569...
IDB 17.11.0.93 started successfully
IDB 17.11.0.93 started
Starting registered Agents: ...
The Agents have been started successfully
Performing server validations against 'Václav’s Mac mini'...
Setting up user remote session...
Selected project configuration for DotNet validation: C:\Users\vacla\source\repos\Feed Viewer\Frondend\iOS\Feed Viewer.csproj: Feed Viewer.Debug|AnyCPU|net8.0-ios.17.5
The dotnet SDK is already installed. Version: '8.0.400-rtm.24375.2'
dotnet validation completed
Selected project configuration for DotNet validation: C:\Users\vacla\source\repos\Feed Viewer\Frondend\iOS\Feed Viewer.csproj: Feed Viewer.Debug|AnyCPU|net8.0-ios.17.5
Removing previous workload cache '/Users/vaclav/Library/Caches/Xamarin/XMA/SDKs/dotnet/metadata'...
Manifests directory: /Users/vaclav/Library/Caches/Xamarin/XMA/SDKs/dotnet/sdk-manifests/8.0.100/microsoft.net.sdk.ios
Installing workloads using rollback file:
{
  "microsoft.net.sdk.ios": "17.5.8020/8.0.100",
  "microsoft.net.workload.mono.toolchain.current": "8.0.8/8.0.100",
  "microsoft.net.workload.mono.toolchain.net7": "8.0.8/8.0.100",
  "microsoft.net.workload.emscripten.current": "8.0.8/8.0.100",
  "microsoft.net.workload.emscripten.net7": "8.0.8/8.0.100"
}
NuGet sources by default: N/A
NuGet sources from project: https://api.nuget.org/v3/index.json
Installing workload 'ios'...
workload install ios --from-rollback-file "/var/folders/0w/qn0kcfpd5f5chtrn8nv28dnm0000gn/T/6f32659a-61c7-49e1-a1ec-7cfb2d941139/rollback.json" --source "https://api.nuget.org/v3/index.json"
Installing workload manifest microsoft.net.sdk.ios version 17.5.8020...
Skipping NuGet package signature verification.
Installing workload manifest microsoft.net.workload.mono.toolchain.current version 8.0.8...
Installing workload manifest microsoft.net.workload.mono.toolchain.net7 version 8.0.8...
Installing workload manifest microsoft.net.workload.emscripten.current version 8.0.8...
Installing workload manifest microsoft.net.workload.emscripten.net7 version 8.0.8...
Installing pack Microsoft.iOS.Sdk.net8.0_17.5 version 17.5.8020...
Pack Microsoft.iOS.Sdk.net8.0_17.5 version 17.5.8020 is already installed.
Writing workload pack installation record for Microsoft.iOS.Sdk.net8.0_17.5 version 17.5.8020...
Installing pack Microsoft.iOS.Sdk.net8.0_17.0 version 17.0.8523...
Pack Microsoft.iOS.Sdk.net8.0_17.0 version 17.0.8523 is already installed.
dotnet validation completed
Installing pack Microsoft.iOS.Sdk version 16.4.7142...
Initializing IDB environment...
SDK relative directory: N/A
Server Settings:
- mlaunch path: N/A
- Xcode version: 15.4
- Xcode path: /Applications/Xcode.app

Starting disconnection from Václav’s Mac mini...
Performing server validations against 'Václav’s Mac mini'...
The connection cannot continue because the remote iOS SDK was not found or is corrupted. If the issue persists, please try removing the `~/Library/Caches/Xamarin/XMA/SDKs/dotnet/` folder on the Mac and try again
Starting disconnection from Václav’s Mac mini...
The connection to 'Václav’s Mac mini' has been finished
Checking host configuration for connecting to 'Václav’s Mac mini'...
Checking SSH configuration...
Initializing environment...
Checking available disk space...
Verifying dotnet runtime installation...
Checking if Rosetta is installed...
Checking Mono installation...
Checking host configuration for connecting to 'Václav’s Mac mini'...
Host 'Václav’s Mac mini' is configured correctly
Starting connection to 'Václav’s Mac mini'...
Checking Broker 17.11.0.93 installation...
Starting Broker 17.11.0.93 in port 50163...
Broker 17.11.0.93 started successfully
Starting connection to 'Václav’s Mac mini'...
SSH connection to 'Václav’s Mac mini' has been established...
Starting registered Agents: IDB 17.11.0.93...
Starting IDB 17.11.0.93...
Checking IDB 17.11.0.93 installation...
Starting IDB 17.11.0.93 in port 50163...
IDB 17.11.0.93 started successfully
IDB 17.11.0.93 started
Starting registered Agents: ...
The Agents have been started successfully
Performing server validations against 'Václav’s Mac mini'...
Setting up user remote session...
Selected project configuration for DotNet validation: C:\Users\vacla\source\repos\Feed Viewer\Frondend\iOS\Feed Viewer.csproj: Feed Viewer.Debug|AnyCPU|net8.0-ios.17.5
The dotnet SDK is already installed. Version: '8.0.400-rtm.24375.2'
dotnet validation completed
Selected project configuration for DotNet validation: C:\Users\vacla\source\repos\Feed Viewer\Frondend\iOS\Feed Viewer.csproj: Feed Viewer.Debug|AnyCPU|net8.0-ios.17.5
Removing previous workload cache '/Users/vaclav/Library/Caches/Xamarin/XMA/SDKs/dotnet/metadata'...
Manifests directory: /Users/vaclav/Library/Caches/Xamarin/XMA/SDKs/dotnet/sdk-manifests/8.0.100/microsoft.net.sdk.ios
Installing workloads using rollback file:
{
  "microsoft.net.sdk.ios": "17.5.8020/8.0.100",
  "microsoft.net.workload.mono.toolchain.current": "8.0.8/8.0.100",
  "microsoft.net.workload.mono.toolchain.net7": "8.0.8/8.0.100",
  "microsoft.net.workload.emscripten.current": "8.0.8/8.0.100",
  "microsoft.net.workload.emscripten.net7": "8.0.8/8.0.100"
}
NuGet sources by default: N/A
NuGet sources from project: https://api.nuget.org/v3/index.json
Installing workload 'ios'...
workload install ios --from-rollback-file "/var/folders/0w/qn0kcfpd5f5chtrn8nv28dnm0000gn/T/e3bc7c1e-e518-4abb-8d4c-11f2358516e7/rollback.json" --source "https://api.nuget.org/v3/index.json"
Installing workload manifest microsoft.net.sdk.ios version 17.5.8020...
Skipping NuGet package signature verification.
Installing workload manifest microsoft.net.workload.mono.toolchain.current version 8.0.8...
Installing workload manifest microsoft.net.workload.mono.toolchain.net7 version 8.0.8...
Installing workload manifest microsoft.net.workload.emscripten.current version 8.0.8...
Installing workload manifest microsoft.net.workload.emscripten.net7 version 8.0.8...
Installing pack Microsoft.iOS.Sdk.net8.0_17.5 version 17.5.8020...
Pack Microsoft.iOS.Sdk.net8.0_17.5 version 17.5.8020 is already installed.
Writing workload pack installation record for Microsoft.iOS.Sdk.net8.0_17.5 version 17.5.8020...
Installing pack Microsoft.iOS.Sdk.net8.0_17.0 version 17.0.8523...
Pack Microsoft.iOS.Sdk.net8.0_17.0 version 17.0.8523 is already installed.
dotnet validation completed
Writing workload pack installation record for Microsoft.iOS.Sdk.net8.0_17.0 version 17.0.8523...
Initializing IDB environment...
SDK relative directory: N/A
Server Settings:
- mlaunch path: N/A
- Xcode version: 15.4
- Xcode path: /Applications/Xcode.app

Starting disconnection from Václav’s Mac mini...
Performing server validations against 'Václav’s Mac mini'...
The connection cannot continue because the remote iOS SDK was not found or is corrupted. If the issue persists, please try removing the `~/Library/Caches/Xamarin/XMA/SDKs/dotnet/` folder on the Mac and try again
Starting disconnection from Václav’s Mac mini...
The connection to 'Václav’s Mac mini' has been finished
@rolfbjarne rolfbjarne added the move-to-vs-feedback Tells automation to ask the person to use VS Feedback to report the issue label Aug 14, 2024
@rolfbjarne rolfbjarne added this to the Future milestone Aug 14, 2024
@michaelb-yambay
Copy link

I'm seeing the same thing after an update to Visual Studio 17.11 on Windows.

I'm not sure how this is related to Visual Studio Code - my scenario and the original poster are using Visual Studio Windows to try to connect to a macOS build host for MAUI development. This worked fine with the last version of VS 17.10

@michaelb-yambay
Copy link

Further investigation of this revealed some strange behaviour. I've done the following:

  • Start VS 17.11 and created a brand new .NET MAUI Multi-Project App (must be a multi-project!)
  • Connect/Pair to my macOS machine works
  • This MAUI app successfully runs against an iOS simulator. ✅
  • Closed VS 17.11 (fully closed VS - not just closed the solution)
  • Restarted VS 17.11 and opened the solution from above.
  • Any attempt at connecting/pairing to macOS fails. ❌

If I try the same but create a '.NET MAUI App' (ie a MAUI app with a single .csproj file that has multiple TargetFrameworks), then my connecting/pairing to macOS works fine all the time.

@akghasemi
Copy link

akghasemi commented Aug 17, 2024

I have the same issue, After upgrading to VS 17.11 ,visual studio is unable to connect to Mac and I get this error "The connection cannot continue because the remote iOS SDK was not found or is corrupted. If the issue persists, please try removing the ~/Library/Caches/Xamarin/XMA/SDKs/dotnet/ folder on the Mac and try again"
I tried the following but none of them worked

  • dotnet workload update (both on windows and mac )
  • removed the folder mentioned in error
    what worked for me : I had to rollback visual studio to previous version (17.10.5)

@universaldata-eu
Copy link

same issue here

@rolfbjarne
Copy link
Member

@ommmr
Copy link

ommmr commented Aug 19, 2024

Im having the same problem. is there a fix for this?

@JLfub
Copy link

JLfub commented Aug 21, 2024

I also have the same problem. And adding a line in the .csproj didn't help. The only thing that worked was to downgrade Visual Studio to 17.10.5.

@bzd3y
Copy link

bzd3y commented Aug 21, 2024

I'm also having this problem. I get an error similar to the comment in that Developer Community thread:

The dotnet SDK installation '8.0.400-rtm.24375.2' failed. If trying again doesn't work, please refer to the public documentation for more information and troubleshooting: https://aka.ms/pairtomac/dotnet`

Although now when I try now, it does not show the second part of the message and it has a yellow warning icon instead of a red error icon.

Actually scratch that, retrying then gives the second part with the error icon:

Could not install dotnet SDK '8.0.400-rtm.24375.2'. Details: IO_PathNotFound_Path, /Users/iosdevelopment/Library/Caches/Xamarin/XMA/Agents/IDB/17.11.0.93/Contents/MonoBundle/.xamarin/osx-x64/Scripts/dotnet-install.sh

@vchelaru
Copy link

I am also having this problem as of VS 17.11.4. The proposed solution of making a modification to the csproj file (adding a new line), saving it, and connecting again does not solve the problem.

@bzd3y
Copy link

bzd3y commented Sep 21, 2024

@vchelaru I think the hand full of times this happened to me I fixed this by uninstalling all of the dotnet SDKs from the Mac and then tried to connect again so that VS installed what it needed.

@alejandroortega08
Copy link

I am having the same issue with VS 17.11.4. It used to give you a link to manually download the file but this is the error I get.

~Error: 0 : An unexpected error occurred while requesting product information from the Products Service. Service URL: https://software.xamarin.com/service/products, Request Content: [{"ProductGuid":"4569c276-1397-4adb-9485-82a7696df22e","Version":"16.4.0.23"}], Details: An error occurred while sending the request.
System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel. ---> System.Security.Authentication.AuthenticationException: The remote certificate is invalid according to the validation procedure. ~

@alejandroortega08
Copy link

alejandroortega08 commented Oct 2, 2024

I am having the same issue with VS 17.11.4. It used to give you a link to manually download the file but this is the error I get.

~Error: 0 : An unexpected error occurred while requesting product information from the Products Service. Service URL: https://software.xamarin.com/service/products, Request Content: [{"ProductGuid":"4569c276-1397-4adb-9485-82a7696df22e","Version":"16.4.0.23"}], Details: An error occurred while sending the request. System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel. ---> System.Security.Authentication.AuthenticationException: The remote certificate is invalid according to the validation procedure. ~

I was able to fix this by manually going to the xamarion ios and download it and make sure xcode version command line tool is set.
https://download.visualstudio.microsoft.com/download/pr/ceb0ea3f-4db8-46b4-8dc3-8049d27c0107/3960868aa9b1946a6c77668c3f3334ee/xamarin.ios-16.4.0.23.pkg

@achobanov
Copy link

Same thing here, although it doesn't seem to be fixed by downgrading to 17.10. Wondering if it is possible this is caused by newer version of XCode? In my case I'm trying to build a net6.0 MAUI project using XCode 15.

@bzd3y
Copy link

bzd3y commented Oct 4, 2024

After this issue and XCode got an update (or I updated VS) I definitely ran into issues due to these versions. My Mac can't run the newest XCode now anyway, so I have just paused iOS development until I figure that out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
move-to-vs-feedback Tells automation to ask the person to use VS Feedback to report the issue
Projects
None yet
Development

No branches or pull requests