Skip to content
This repository has been archived by the owner on May 1, 2024. It is now read-only.

[Bug] iOS App Centre Build Fail - Can't resolve the reference 'System.Void UIKit.UITableView::set_SectionHeaderTopPadding(System.nfloat)' #14778

Closed
paul-charlton opened this issue Oct 22, 2021 · 11 comments

Comments

@paul-charlton
Copy link

Description

I updated my version of Xamarin.Forms to address an issue in a version of iOS that added padding to List Views. This builds and runs in Visual Studio, however, when the build is triggered in App Centre it fails with the following error:

MTOUCH : error MT2101: Can't resolve the reference 'System.Void UIKit.UITableView::set_SectionHeaderTopPadding(System.nfloat)', referenced from the method 'System.Void Xamarin.Forms.Platform.iOS.ListViewRenderer::OnElementChanged(Xamarin.Forms.Platform.iOS.ElementChangedEventArgs`1<Xamarin.Forms.ListView>)' in 'Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065'.

I've tried updating the SDK version in App Centre to experimental versions (14.20 & 15) with the same result.

Steps to Reproduce

  1. Build iOS App on App Center

Expected Behavior

Build Completes

Actual Behavior

Build fails with above error

Basic Information

  • Version with issue:
    Xamarin.Forms: 5.0.0.2196
    ios SDK: 14.16, 14.20, 15
    XCode: 13

  • Last known good version:
    Xamarin.Forms: 5.0.0.2195
    ios SDK: 14.14
    XCode: (not sure)

Environment

Show/Hide Visual Studio info
Microsoft Visual Studio Enterprise 2019
Version 16.11.5
VisualStudio.16.Release/16.11.5+31729.503
Microsoft .NET Framework
Version 4.8.04084

Installed Version: Enterprise

.NET Core Debugging with WSL   1.0
.NET Core Debugging with WSL

ADL Tools Service Provider   1.0
This package contains services used by Data Lake tools

ASA Service Provider   1.0

ASP.NET and Web Tools 2019   16.11.75.64347
ASP.NET and Web Tools 2019

ASP.NET Web Frameworks and Tools 2019   16.11.75.64347
For additional information, visit https://www.asp.net/

Azure App Service Tools v3.0.0   16.11.75.64347
Azure App Service Tools v3.0.0

Azure Data Lake Node   1.0
This package contains the Data Lake integration nodes for Server Explorer.

Azure Data Lake Tools for Visual Studio   2.6.3000.0
Microsoft Azure Data Lake Tools for Visual Studio

Azure Functions and Web Jobs Tools   16.11.75.64347
Azure Functions and Web Jobs Tools

Azure Stream Analytics Tools for Visual Studio   2.6.3000.0
Microsoft Azure Stream Analytics Tools for Visual Studio

C# Tools   3.11.0-4.21403.6+ae1fff344d46976624e68ae17164e0607ab68b10
C# components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

CodeMaid   11.2.231
CodeMaid is an open source Visual Studio extension to cleanup and simplify our C#, C++, F#, VB, PHP, PowerShell, R, JSON, XAML, XML, ASP, HTML, CSS, LESS, SCSS, JavaScript and TypeScript coding.

Color Picker   1.0
Integrated Color Picker for Visual Studio IDE and Editor

Common Azure Tools   1.10
Provides common services for use by Azure Mobile Services and Microsoft Azure Tools.

Extensibility Message Bus   1.2.6 (master@34d6af2)
Provides common messaging-based MEF services for loosely coupled Visual Studio extension components communication and integration.

Fabric.DiagnosticEvents   1.0
Fabric Diagnostic Events

GitHub.VisualStudio   2.11.106.19330
A Visual Studio Extension that brings the GitHub Flow into Visual Studio.

IntelliCode Extension   1.0
IntelliCode Visual Studio Extension Detailed Info

Microsoft Azure HDInsight Azure Node   2.6.3000.0
HDInsight Node under Azure Node

Microsoft Azure Hive Query Language Service   2.6.3000.0
Language service for Hive query

Microsoft Azure Service Fabric Tools for Visual Studio   16.10
Microsoft Azure Service Fabric Tools for Visual Studio

Microsoft Azure Stream Analytics Language Service   2.6.3000.0
Language service for Azure Stream Analytics

Microsoft Azure Stream Analytics Node   1.0
Azure Stream Analytics Node under Azure Node

Microsoft Azure Tools for Visual Studio   2.9
Support for Azure Cloud Services projects

Microsoft Continuous Delivery Tools for Visual Studio   0.4
Simplifying the configuration of Azure DevOps pipelines from within the Visual Studio IDE.

Microsoft JVM Debugger   1.0
Provides support for connecting the Visual Studio debugger to JDWP compatible Java Virtual Machines

Microsoft Library Manager   2.1.113+g422d40002e.RR
Install client-side libraries easily to any web project

Microsoft MI-Based Debugger   1.0
Provides support for connecting Visual Studio to MI compatible debuggers

Microsoft Visual Studio Tools for Containers   1.2
Develop, run, validate your ASP.NET Core applications in the target environment. F5 your application directly into a container with debugging, or CTRL + F5 to edit & refresh your app without having to rebuild the container.

Mono Debugging for Visual Studio   16.10.15 (552afdf)
Support for debugging Mono processes with Visual Studio.

NuGet Package Manager   5.11.0
NuGet Package Manager in Visual Studio. For more information about NuGet, visit https://docs.nuget.org/

ProjectServicesPackage Extension   1.0
ProjectServicesPackage Visual Studio Extension Detailed Info

Razor (ASP.NET Core)   16.1.0.2122504+13c05c96ea6bdbe550bd88b0bf6cdddf8cde1725
Provides languages services for ASP.NET Core Razor.

Snapshot Debugging Extension   1.0
Snapshot Debugging Visual Studio Extension Detailed Info

SQL Server Data Tools   16.0.62107.28140
Microsoft SQL Server Data Tools

StylerPackage Extension   1.0
StylerPackage Visual Stuido Extension Detailed Info

ToolWindowHostedEditor   1.0
Hosting json editor into a tool window

TypeScript Tools   16.0.30526.2002
TypeScript Tools for Microsoft Visual Studio

Visual Basic Tools   3.11.0-4.21403.6+ae1fff344d46976624e68ae17164e0607ab68b10
Visual Basic components used in the IDE. Depending on your project type and settings, a different version of the compiler may be used.

Visual F# Tools   16.11.0-beta.21322.6+488cc578cafcd261d90d748d8aaa7b8b091232dc
Microsoft Visual F# Tools

Visual Studio Code Debug Adapter Host Package   1.0
Interop layer for hosting Visual Studio Code debug adapters in Visual Studio

Visual Studio Container Tools Extensions   1.0
View, manage, and diagnose containers within Visual Studio.

Visual Studio Tools for Containers   1.0
Visual Studio Tools for Containers

Visual Studio Tools for Kubernetes   1.0
Visual Studio Tools for Kubernetes

VisualStudio.DeviceLog   1.0
Information about my package

VisualStudio.Foo   1.0
Information about my package

VisualStudio.Mac   1.0
Mac Extension for Visual Studio

VSColorOutput   2.73
Color output for build and debug windows - https://mike-ward.net/vscoloroutput

Xamarin   16.11.000.190 (d16-11@2391ed9)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin Designer   16.11.0.17 (remotes/origin/11e0001f0b17269345e80b58fb3adf1ba4efe2cd@11e0001f0)
Visual Studio extension to enable Xamarin Designer tools in Visual Studio.

Xamarin Templates   16.10.5 (355b57a)
Templates for building iOS, Android, and Windows apps with Xamarin and Xamarin.Forms.

Xamarin.Android SDK   11.4.0.5 (d16-11/7776c9f)
Xamarin.Android Reference Assemblies and MSBuild support.
    Mono: c633fe9
    Java.Interop: xamarin/java.interop/d16-11@48766c0
    ProGuard: Guardsquare/proguard/v7.0.1@912d149
    SQLite: xamarin/sqlite/3.35.4@85460d3
    Xamarin.Android Tools: xamarin/xamarin-android-tools/d16-11@683f375


Xamarin.iOS and Xamarin.Mac SDK   15.0.0.8 (0796d78dc)
Xamarin.iOS and Xamarin.Mac Reference Assemblies and MSBuild support.

Build Logs

(_CompileToNative target) -> 
  MTOUCH : error MT2101: Can't resolve the reference 'System.Void UIKit.UITableView::set_SectionHeaderTopPadding(System.nfloat)', referenced from the method 'System.Void Xamarin.Forms.Platform.iOS.ListViewRenderer::OnElementChanged(Xamarin.Forms.Platform.iOS.ElementChangedEventArgs`1<Xamarin.Forms.ListView>)' in 'Xamarin.iOS, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065'. [/Users/runner/work/1/s/src/...]

Screenshots

Reproduction Link

Workaround

@paul-charlton paul-charlton added s/unverified New report that has yet to be verified t/bug 🐛 labels Oct 22, 2021
@jsuarezruiz jsuarezruiz removed the s/unverified New report that has yet to be verified label Oct 22, 2021
@jsuarezruiz jsuarezruiz self-assigned this Oct 22, 2021
@jsuarezruiz
Copy link
Contributor

Seems to be the same or related with #14752

@jfversluis
Copy link
Member

Yep, duplicate of that one. Thanks for the report @paul-charlton. For now you will have to build your app against Xcode 13. We're working on a fix for this for the next service release. Sorry for the inconvience!

@jfversluis
Copy link
Member

Duplicate of #14752

@jfversluis jfversluis marked this as a duplicate of #14752 Oct 22, 2021
@paul-charlton
Copy link
Author

paul-charlton commented Oct 22, 2021

Apologies I did do a search for that error and didn't find anything!

Is there an approximate timescale for the App Centre update?

(App Centre claims it's building against XCode 13)

@jfversluis
Copy link
Member

No worries, it happens to the best of us!

I can't speak for the App Center update, but our update should be coming around Nov. 10th.

(App Centre claims it's building against XCode 13)

Make sure that is also in your build configuration for iOS. I know you can select an Xcode version there.

@paul-charlton
Copy link
Author

Will do - thanks!

@jantanis
Copy link

jantanis commented Oct 29, 2021

I was able to workaround this on AppCenter by using 2 build scripts:

#appcenter-post-clone.sh
#!/usr/bin/env bash

echo "Post-clone script executing..."

# Update nuget (fix NETSDK1005)
sudo nuget update -self  
#appcenter-pre-build.sh
#!/usr/bin/env bash

# Download Mono 6.12.0.158
wget https://download.mono-project.com/archive/6.12.0/macos-10-universal/MonoFramework-MDK-6.12.0.158.macos10.xamarin.universal.pkg

# Add execution permission
sudo chmod +x MonoFramework-MDK-6.12.0.158.macos10.xamarin.universal.pkg

# Install Mono 6.12.0.158
sudo installer -pkg MonoFramework-MDK-6.12.0.158.macos10.xamarin.universal.pkg -target /  

Source

@jfversluis
Copy link
Member

Thanks for sharing @jantanis !

@gpiano
Copy link

gpiano commented Nov 4, 2021

It didn't work for me @jantanis. Thanks anyway for sharing. Hopefully another workaround will come out while the fix is released.

@jfversluis
Copy link
Member

@gpiano Please see: #14752 (comment)

In contradiction with what I said here before, there won't be a fix on our side most likely. This is due to not compiling the code against the latest Xcode and Xamarin.iOS version which is what you should be doing. Hope you can make it work with your build pipeline.

@mdmota
Copy link

mdmota commented Oct 20, 2022

Any solution?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

6 participants