Bug 56227 - Android app doesn't see some of the methods from the referenced library
Summary: Android app doesn't see some of the methods from the referenced library
Alias: None
Product: Android
Classification: Xamarin
Component: General ()
Version: 7.3 (15.2)
Hardware: PC Windows
: --- blocker
Target Milestone: ---
Assignee: Jonathan Pryor
Depends on:
Reported: 2017-05-11 14:54 UTC by Ruben Buniatyan
Modified: 2017-08-21 20:36 UTC (History)
5 users (show)

Tags: 15.2I bb
Is this bug a regression?: ---
Last known good build:

Test project to reproduce the issue (25.60 KB, application/x-zip-compressed)
2017-05-11 14:56 UTC, Ruben Buniatyan

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Ruben Buniatyan 2017-05-11 14:54:24 UTC
# Steps to reproduce
Just run the attached project

# Expected behavior
Must work just fine

# Actual behavior
Throws MissingMethodException or similar error

# Supplemental info (logs, images, videos)
This was working smoothly before the VS 2017 15.2 update. In this case, seems the problem is with ValueTuple types.

# Test environment (full version information)
Microsoft Visual Studio Enterprise 2017 
Version 15.2 (26430.4) Release
Microsoft .NET Framework
Version 4.7.02046

Installed Version: Enterprise

Visual Basic 2017   00369-90000-00000-AA049
Microsoft Visual Basic 2017

Visual C# 2017   00369-90000-00000-AA049
Microsoft Visual C# 2017

Application Insights Tools for Visual Studio Package   8.6.00404.2
Application Insights Tools for Visual Studio

ASP.NET and Web Tools 2017   15.0.30503.0
ASP.NET and Web Tools 2017

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

Azure App Service Tools v3.0.0   15.0.30209.0
Azure App Service Tools v3.0.0

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

JavaScript Language Service   2.0
JavaScript Language Service

JetBrains ReSharper Ultimate 2017.1.2    Build 108.0.20170428.75743
JetBrains ReSharper Ultimate package for Microsoft Visual Studio. For more information about ReSharper Ultimate, visit http://www.jetbrains.com/resharper. Copyright © 2017 JetBrains, Inc.

KofePackagePackage Extension   1.0
KofePackagePackage Visual Studio Extension Detailed Info

Merq   1.1.17-rc (cba4571)
Command Bus, Event Stream and Async Manager for Visual Studio extensions.

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

Mono Debugging for Visual Studio   Mono.Debugging.VisualStudio
Support for debugging Mono processes with Visual Studio.

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

SQL Server Data Tools   15.1.61702.140
Microsoft SQL Server Data Tools

TypeScript tools for Visual Studio

Xamarin (c871575)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android.

Xamarin.Android SDK (448f54f)
Xamarin.Android Reference Assemblies and MSBuild support.

Xamarin.iOS and Xamarin.Mac SDK (30b6e87)
Xamarin.iOS and Xamarin.Mac Reference Assemblies and MSBuild support.
Comment 1 Ruben Buniatyan 2017-05-11 14:56:56 UTC
Created attachment 22087 [details]
Test project to reproduce the issue
Comment 2 Prashant [MSFT] 2017-05-15 05:38:53 UTC
Could you elaborate the issue. 
I am not able to reproduce this issue on my test machines. Detailed steps to reproduce and error would be very useful
Comment 3 Ruben Buniatyan 2017-05-15 12:48:50 UTC
There are two projects -- App3 and ClassLibrary1.
1. Open App3.
2. App3 references ClassLibrary1. If you don't see ClassLibrary1 in your solution, just add it.
3. Run App3, and you'll get a runtime error.
Comment 4 Ruben Buniatyan 2017-05-16 08:42:01 UTC
Any update on this? This bug turned my Android projects simply useless.
Comment 5 Mark McLemore 2017-06-23 22:48:15 UTC
Unable to repro with Visual Studio 2017 15.2, Xamarin, and Xamarin.Android I did the following:

1. Opened the App3 .csproj file (creates a new solution).
2. Added the ClassLibrary1 project to the new solution.
3. Build > Build Solution.
4. Deploy to a Nexus 5 device running Android 6.0.1.

App3 runs without throwing an exception. I was able to leave it running on the device for several minutes.

Can you update to the latest version of Xamarin.Android and try it again? Also, are you getting this error on an emulator or on a device?
Comment 6 Prashant [MSFT] 2017-06-27 05:29:32 UTC
I am no longer able to reproduce this issue on following setup - 

=== Visual Studio Enterprise 2017 for Mac ===

Version 7.0.1 (build 24)
Installation UUID: cbe44f28-b7cf-4fec-aed3-4f13bc08336d
	Mono (2017-02/5077205) (64-bit)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 500010001

=== NuGet ===


=== .NET Core ===

Runtime: /usr/local/share/dotnet/dotnet
SDK: /usr/local/share/dotnet/sdk/1.0.3/Sdks
MSBuild SDKs: /Library/Frameworks/Mono.framework/Versions/5.0.1/lib/mono/msbuild/15.0/bin/Sdks

=== Xamarin.Profiler ===

Version: 1.5.4
Location: /Applications/Xamarin Profiler.app/Contents/MacOS/Xamarin Profiler

=== Xamarin.Android ===

Version: (Visual Studio Enterprise)
Android SDK: /Users/prashantvc/Library/Developer/Xamarin/android-sdk-macosx
	Supported Android versions:
		6.0 (API level 23)
		7.0 (API level 24)
		7.1 (API level 25)

SDK Tools Version: 26.0.1
SDK Platform Tools Version: 25.0.4
SDK Build Tools Version: 25.0.2

Java SDK: /usr
java version "1.8.0_101"
Java(TM) SE Runtime Environment (build 1.8.0_101-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.101-b13, mixed mode)

Android Designer EPL code available here:

=== Xamarin Inspector ===

Version: 1.2.2
Hash: b71b035
Branch: d15-1
Build date: Fri, 21 Apr 2017 17:57:12 GMT

=== Apple Developer Tools ===

Xcode 8.3.3 (12175.1)
Build 8E3004b

=== Xamarin.Mac ===

Version: (Visual Studio Enterprise)

=== Xamarin.iOS ===

Version: (Visual Studio Enterprise)
Hash: d2270eec
Branch: d15-2
Build date: 2017-05-22 16:30:53-0400

=== Build Information ===

Release ID: 700010024
Git revision: 7ab1ca2ced6f584e56b7a0d4d321d00775cd95c9
Build date: 2017-05-19 05:44:51-04
Xamarin addins: 08d17158f3365beee5e60f67999e607cce4b3f93
Build lane: monodevelop-lion-d15-2

=== Operating System ===

Mac OS X 10.12.5
Darwin 16.6.0 Darwin Kernel Version 16.6.0
    Fri Apr 14 16:21:16 PDT 2017
    root:xnu-3789.60.24~6/RELEASE_X86_64 x86_64

=== Enabled user installed addins ===

MFractor 3.00.05
AddinMaker 1.3.7
Comment 7 Jon Douglas [MSFT] 2017-08-21 20:36:09 UTC
I noticed this sample project is using project.json which was deprecated by the .NET team in favor for <PackageReference>. It has also been noted that multiple members were not able to reproduce this issue.

Thank you for taking the time to submit this report. After reviewing the description of this bug, we believe it no longer affects the current version of Xamarin.Android. If you are still experiencing the issue after updating your packages, please reopen this report with an attached reproduction.