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

building untrimmed application on Android on Release ends with Exception 'Unable to find Java.Lang.AbstractMethodError constructor' #6569

Closed
janseris opened this issue Apr 27, 2022 · 2 comments
Labels
area-publishing Issues with the app packaging/publishing process (ipk/apk/msix/trimming) platform/android 🤖 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working

Comments

@janseris
Copy link

janseris commented Apr 27, 2022

Description

Error	XALNS7000	System.Exception: Unable to find Java.Lang.AbstractMethodError constructor in Mono.Android assembly
   at MonoDroid.Tuner.FixAbstractMethodsStep.get_AbstractMethodErrorConstructor()
   at MonoDroid.Tuner.FixAbstractMethodsStep.AddNewExceptionMethod(TypeDefinition type, MethodDefinition method)
   at MonoDroid.Tuner.FixAbstractMethodsStep.FixAbstractMethods(TypeDefinition type)
   at MonoDroid.Tuner.FixAbstractMethodsStep.FixAbstractMethods(AssemblyDefinition assembly)
   at Xamarin.Android.Tasks.LinkAssembliesNoShrink.RunTask()
   at Microsoft.Android.Build.Tasks.AndroidTask.Execute() in /Users/runner/work/1/s/xamarin-android/external/xamarin-android-tools/src/Microsoft.Android.Build.BaseTasks/AndroidTask.cs:line 17	MauiApp2	C:\Program Files\dotnet\packs\Microsoft.Android.Sdk.Windows\32.0.300-rc.3.33\tools\Xamarin.Android.Common.targets	1391	

caused by:

<DebugSymbols>True</DebugSymbols>
<PublishTrimmed>False</PublishTrimmed>
<RunAOTCompilation>False</RunAOTCompilation>

Steps to Reproduce

create MAUI Blazor app
build Release

Version with bug

Release Candidate 2 (current)

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 11 (API 30)

Did you find any workaround?

No response

Relevant log output

No response

@janseris janseris added s/needs-verification Indicates that this issue needs initial verification before further triage will happen t/bug Something isn't working labels Apr 27, 2022
@janseris janseris changed the title Running untrimmed application on Android on Release ends with runtime Exception cannot find AndroidTask building untrimmed application on Android on Release ends with runtime Exception cannot find AndroidTask Apr 27, 2022
@janseris janseris changed the title building untrimmed application on Android on Release ends with runtime Exception cannot find AndroidTask building untrimmed application on Android on Release ends with Exception cannot find AndroidTask Apr 27, 2022
@janseris janseris changed the title building untrimmed application on Android on Release ends with Exception cannot find AndroidTask building untrimmed application on Android on Release ends with Unable to find Java.Lang.AbstractMethodError constructor Apr 27, 2022
@janseris janseris changed the title building untrimmed application on Android on Release ends with Unable to find Java.Lang.AbstractMethodError constructor building untrimmed application on Android on Release ends with Exception 'Unable to find Java.Lang.AbstractMethodError constructor' Apr 27, 2022
@v-longmin
Copy link

Verified not repro on Android 12.0 with VS 17.3.0 Preview 1.0 [32414.199.main]. Not repro with above code.

@v-longmin v-longmin added s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage and removed s/needs-verification Indicates that this issue needs initial verification before further triage will happen labels Apr 28, 2022
@Eilon Eilon added the area-publishing Issues with the app packaging/publishing process (ipk/apk/msix/trimming) label Apr 28, 2022
@Redth Redth closed this as completed May 3, 2022
@soundaranbu
Copy link

soundaranbu commented May 17, 2022

Issue still exists in

  • MAUI Blazor RC3,
  • Visual Studio Version 17.3.0 Preview 1.0.
  • Android 11 (API 30)
    image

Attaching sample project here
MauiSqliteErrorSample.zip

Some Background:

@Redth @Eilon

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-publishing Issues with the app packaging/publishing process (ipk/apk/msix/trimming) platform/android 🤖 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

6 participants