Skip to content

Commit

Permalink
[generate-type-forwarders] Fix issues with properties stubs (#10941)
Browse files Browse the repository at this point in the history
Examples

* Fix visibility, e.g. `protected`

```diff
-		public virtual System.IntPtr RawJointLandmarks {
+		protected virtual System.IntPtr RawJointLandmarks {
```

* Remove non-visible properties, e.g. `internal`

```diff
-		public virtual System.IntPtr _AddressBook {
-			get { throw new global::System.PlatformNotSupportedException (global::Constants.UnavailableOnMacCatalyst); }
-			set { throw new global::System.PlatformNotSupportedException (global::Constants.UnavailableOnMacCatalyst); }
-		}
```

* Fix `abstract` members

```diff
-public abstract ARSession Session { get; }
+public virtual ARSession Session { get; }
```
  • Loading branch information
spouliot committed Mar 24, 2021
1 parent 8056ae1 commit 2b7dc07
Showing 1 changed file with 63 additions and 16 deletions.
79 changes: 63 additions & 16 deletions src/generate-type-forwarders/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
*/

namespace GenerateTypeForwarders {
class MainClass {
static class MainClass {
public static int Main (string [] args)
{
var forwardFrom = args [0];
Expand All @@ -27,6 +27,30 @@ public static int Main (string [] args)
return Fix (forwardFrom, forwardTo, output);
}

static bool IsVisible (this TypeDefinition type)
{
if (!type.IsNested)
return true;
return type.IsNestedPublic || type.IsNestedFamily;
}

static bool IsVisible (this MethodDefinition method)
{
if (method is null)
return false;
return method.IsPublic || method.IsFamily;
}

static bool IsVisible (this PropertyDefinition property)
{
return property.GetMethod.IsVisible () || property.SetMethod.IsVisible ();
}

static bool IsVisible (this FieldDefinition field)
{
return field.IsPublic || field.IsFamily;
}

static void EmitTypeName (StringBuilder sb, TypeReference type)
{
if (type.FullName == "System.Void") {
Expand Down Expand Up @@ -357,10 +381,14 @@ static bool HasPropertyInTypeHierarchy (TypeDefinition type, MethodDefinition ac

static void EmitProperty (StringBuilder sb, PropertyDefinition pd, int indent)
{
var strIndent = new string ('\t', indent);
sb.Append (strIndent);
sb.Append ("public ");
var m = pd.GetMethod ?? pd.SetMethod;
sb.Append ('\t', indent);
var gm = pd.GetMethod;
var sm = pd.SetMethod;
var m = gm ?? sm;
if (m.IsPublic)
sb.Append ("public ");
else
sb.Append ("protected ");
if (m.IsStatic) {
sb.Append ("static ");
if (HasPropertyInTypeHierarchy (pd.DeclaringType, m, out var _))
Expand All @@ -373,20 +401,32 @@ static void EmitProperty (StringBuilder sb, PropertyDefinition pd, int indent)
sb.Append ("new ");
}
} else if (!pd.DeclaringType.IsSealed) {
sb.Append ("virtual ");
if (m.IsAbstract)
sb.Append ("abstract ");
else
sb.Append ("virtual ");
}
}
EmitTypeName (sb, pd.PropertyType);
sb.Append (' ');
sb.Append (pd.Name);
sb.AppendLine (" {");
if (pd.GetMethod != null) {
sb.AppendLine ($"{strIndent}\tget {{ throw new global::System.PlatformNotSupportedException (global::Constants.UnavailableOnMacCatalyst); }}");
if (gm.IsVisible ()) {
sb.Append ('\t', indent + 1);
if (gm.IsAbstract)
sb.AppendLine ("get;");
else
sb.AppendLine ("get { throw new global::System.PlatformNotSupportedException (global::Constants.UnavailableOnMacCatalyst); }");
}
if (pd.SetMethod != null) {
sb.AppendLine ($"{strIndent}\tset {{ throw new global::System.PlatformNotSupportedException (global::Constants.UnavailableOnMacCatalyst); }}");
if (pd.SetMethod.IsVisible ()) {
sb.Append ('\t', indent + 1);
if (sm.IsAbstract)
sb.AppendLine ("set;");
else
sb.AppendLine ("set { throw new global::System.PlatformNotSupportedException (global::Constants.UnavailableOnMacCatalyst); }");
}
sb.AppendLine ($"{strIndent}}}");
sb.Append ('\t', indent);
sb.AppendLine ("}");
}

static void EmitEvent (StringBuilder sb, EventDefinition ed, int indent)
Expand Down Expand Up @@ -425,7 +465,12 @@ static void EmitPNSE (StringBuilder sb, TypeDefinition type, int indent)
EmitParameters (sb, invoke.Parameters);
sb.AppendLine (");");
} else {
sb.Append ($"{strIndent}public ");
sb.Append (strIndent);
// other are filtered not to generate stubs
if (type.IsNestedFamily)
sb.Append ("protected ");
else
sb.Append ("public ");
if (type.IsInterface) {
sb.Append ("interface ");
} else if (type.IsEnum) {
Expand Down Expand Up @@ -484,7 +529,7 @@ static void EmitPNSE (StringBuilder sb, TypeDefinition type, int indent)
sb.Append (" {");
sb.AppendLine ();
foreach (var nestedType in type.NestedTypes) {
if (nestedType.IsNestedPrivate)
if (!nestedType.IsVisible ())
continue;
EmitPNSE (sb, nestedType, indent + 1);
}
Expand All @@ -498,18 +543,20 @@ static void EmitPNSE (StringBuilder sb, TypeDefinition type, int indent)
bt = bt.BaseType?.Resolve ();
}
foreach (var method in type.Methods) {
// need .ctor(IntPtr) for chaining
if (!method.IsVisible () && !method.IsConstructor)
continue;
EmitPNSE (sb, method, indent + 1, nsobject);
}

foreach (var field in type.Fields) {
if (field.IsPrivate)
if (!field.IsVisible ())
continue;

EmitField (sb, field, indent + 1);
}

foreach (var prop in type.Properties) {
if (prop.GetMethod?.IsPrivate != false && prop.SetMethod?.IsPrivate != false)
if (!prop.IsVisible ())
continue;
EmitProperty (sb, prop, indent + 1);
}
Expand Down

4 comments on commit 2b7dc07

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ Tests failed on Build ❌

Tests failed on Build.

API diff

✅ API Diff from stable

View API diff

Packages generated

View packages

Test results

1 tests failed, 181 tests passed.

Failed tests

  • monotouch-test/tvOS - simulator/Debug (all optimizations): Failed

Pipeline on Agent XAMBOT-1022'

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ Tests failed on VSTS: device tests tvOS ❌

Tests failed on VSTS: device tests tvOS.

Test results

1 tests failed, 156 tests' device not found, 5 tests passed.

Failed tests

  • monotouch-test/Mac Catalyst/Debug: BuildFailure

Pipeline on Agent XAMTESTMAC14

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ Tests failed on VSTS: device tests iOS32b ❌

Tests failed on VSTS: device tests iOS32b.

Test results

1 tests failed, 169 tests' device not found, 5 tests passed.

Failed tests

  • monotouch-test/Mac Catalyst/Debug: BuildFailure

Pipeline on Agent XI-CAPTAIN-MARVEL

@vs-mobiletools-engineering-service2
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❌ Tests failed on VSTS: device tests iOS ❌

Tests failed on VSTS: device tests iOS.

Test results

158 tests failed, 5 tests passed.

Failed tests

  • monotouch-test/Mac Catalyst/Debug: BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Debug: BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug, profiling): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug, profiling): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Release: BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (release): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Debug (dynamic registrar): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Release (all optimizations): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Debug (all optimizations): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Debug: SGenConc: BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Debug (interpreter): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Debug (interpreter -mscorlib): BuildFailure
  • monotouch-test/iOS Unified 64-bits - device/Release (interpreter -mscorlib): BuildFailure
  • fsharp/iOS Unified 64-bits - device/Debug: HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • fsharp/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug): HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • fsharp/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug): HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • fsharp/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug, profiling): HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • fsharp/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug, profiling): HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • fsharp/iOS Unified 64-bits - device/Release: HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • fsharp/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (release): HarnessException (Harness exception for 'fsharp': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/Debug: HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug): HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug): HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug, profiling): HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug, profiling): HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/Release: HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • framework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (release): HarnessException (Harness exception for 'framework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • xcframework-test/iOS Unified 64-bits - device/Debug: HarnessException (Harness exception for 'xcframework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • xcframework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug): BuildFailure
  • xcframework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug): HarnessException (Harness exception for 'xcframework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • xcframework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: dylib (debug, profiling): BuildFailure
  • xcframework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (debug, profiling): HarnessException (Harness exception for 'xcframework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • xcframework-test/iOS Unified 64-bits - device/Release: HarnessException (Harness exception for 'xcframework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String hostName) [0x00000] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:308
    at System.Net.Dns.GetHostByName (System.String hostName) [0x00021] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:441
    at System.Net.Dns.GetHostEntry (System.String hostNameOrAddress) [0x00052] in /Users/builder/jenkins/workspace/build-package-osx-mono/2020-02/external/bockbuild/builds/mono-x64/mcs/class/System/System.Net/Dns.cs:397
    at Xharness.AppRunner.RunAsync () [0x00369] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/AppRunner.cs:247
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x00ac4] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:163
    at Xharness.Jenkins.TestTasks.RunDevice.RunTestAsync () [0x0129e] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunDevice.cs:229
    at Xharness.Jenkins.TestTasks.RunTest.ExecuteAsync () [0x001b9] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/RunTest.cs:109
    at Xharness.Jenkins.TestTasks.TestTasks.RunInternalAsync () [0x00226] in /Users/xamarinqa/azdo/_work/141/s/xamarin-macios/tests/xharness/Jenkins/TestTasks/TestTask.cs:283 )
  • xcframework-test/iOS Unified 64-bits - device/AssemblyBuildTarget: SDK framework (release): HarnessException (Harness exception for 'xcframework-test': System.Net.Sockets.SocketException (0x80004005): Could not resolve host 'XAMTESTMAC01'
    at System.Net.Dns.Error_11001 (System.String \n\nThe message from CI is too large for the GitHub comments. You can find the full results here.

Please sign in to comment.