Bug 58798 - Failed to load AOT module '(null)' while running in aot-only mode
Summary: Failed to load AOT module '(null)' while running in aot-only mode
Status: RESOLVED NORESPONSE
Alias: None
Product: iOS
Classification: Xamarin
Component: Mono runtime / AOT compiler ()
Version: XI 10.14 (d15-4)
Hardware: Macintosh Mac OS
: --- blocker
Target Milestone: Untriaged
Assignee: Zoltan Varga
URL:
Depends on:
Blocks:
 
Reported: 2017-08-16 00:33 UTC by Frank A. Krueger
Modified: 2018-02-15 13:20 UTC (History)
9 users (show)

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

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:
Status:
RESOLVED NORESPONSE

Description Frank A. Krueger 2017-08-16 00:33:38 UTC
When executing my app, I get the error: Failed to load AOT module '(null)' while running in aot-only mode: doesn't match assembly.

This only happens with the current Alpha channel - Stable builds work fine.

I thought I had already reported this but didn't see it in my history.

The app is an F# iOS app with many dependencies. Please let me know how I can capture better logs to help you find what's wrong.

Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: Failed to load AOT module '(null)' while running in aot-only mode: doesn't match assembly.
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 
Native stacktrace:
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	0   Continuous                          0x000000010ccd88c8 Continuous + 213829832
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	1   libsystem_platform.dylib            0x0000000180bfd348 _sigtramp + 52
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	2   libsystem_pthread.dylib             0x0000000180c03450 pthread_kill + 112
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	3   libsystem_c.dylib                   0x0000000180aaf400 abort + 140
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	4   Continuous                          0x000000010cdd6338 mono_pmip + 1004624
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	5   Continuous                          0x000000010cde545c mono_pmip + 1066356
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	6   Continuous                          0x000000010cca7c10 Continuous + 213629968
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	7   Continuous                          0x000000010ccf4320 mono_pmip + 78904
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	8   Continuous                          0x000000010ccf3ea8 mono_pmip + 77760
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	9   Continuous                          0x000000010ce05340 xamarin_localized_string_format_9 + 23040
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	10  Continuous                          0x000000010ccf611c mono_pmip + 86580
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	11  Continuous                          0x000000010cd13244 mono_pmip + 205660
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	12  Continuous                          0x000000010cce3ce4 mono_pmip + 11772
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	13  Continuous                          0x000000010ce04e40 xamarin_localized_string_format_9 + 21760
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	14  Continuous                          0x00000001001d786c Continuous + 964716
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 	15  libdyld.dylib                       0x0000000180a295b8 <redacted> + 4
Aug 15 17:19:47 Precious-XIV Continuous[268] <Notice>: mono-rt: 
=================================================================
Got a SIGABRT while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries 
used by your application.
=================================================================

=== Visual Studio Enterprise 2017 for Mac (Preview) ===

Version 7.2 Preview (7.2 build 487)
Installation UUID: d6cd6cd1-7a81-4bf4-a56d-059b47bf8f6d
Runtime:
	Mono 5.4.0.135 (2017-06/6425f06) (64-bit)
	GTK+ 2.24.23 (Raleigh theme)

	Package version: 504000135

=== NuGet ===

Version: 4.3.0.2418

=== .NET Core ===

Runtime: /usr/local/share/dotnet/dotnet
Runtime Version: 1.1.0
SDK: /usr/local/share/dotnet/sdk/1.0.0-preview2-1-003177/Sdks
SDK Version: 1.0.0-preview2-1-003177
MSBuild SDKs: /Library/Frameworks/Mono.framework/Versions/5.4.0/lib/mono/msbuild/15.0/bin/Sdks

=== Xamarin.Profiler ===

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

=== Xamarin.Android ===

Version: 7.5.0.3 (Visual Studio Enterprise)
Android SDK: /Users/fak/Library/Developer/Xamarin/android-sdk-mac_x86
	Supported Android versions:
		2.3   (API level 10)
		4.0.3 (API level 15)
		4.4   (API level 19)
		5.0   (API level 21)
		6.0   (API level 23)
		7.0   (API level 24)
		7.1   (API level 25)

SDK Tools Version: 25.2.5
SDK Platform Tools Version: 25.0.3
SDK Build Tools Version: 23.0.2

Java SDK: /usr
java version "1.7.0_51"
Java(TM) SE Runtime Environment (build 1.7.0_51-b13)
Java HotSpot(TM) 64-Bit Server VM (build 24.51-b03, mixed mode)

Android Designer EPL code available here:
https://github.com/xamarin/AndroidDesigner.EPL

=== Apple Developer Tools ===

Xcode 8.3.3 (12175.1)
Build 8E3004b

=== Xamarin.iOS ===

Version: 10.14.0.3 (Visual Studio Enterprise)
Hash: 80f17b0b
Branch: d15-4
Build date: 2017-07-19 10:26:09-0400

=== Xamarin Inspector ===

Version: 1.3.0-alpha2
Hash: fa030e0
Branch: master
Build date: Thu, 01 Jun 2017 20:55:26 GMT
Client compatibility: 1

=== Xamarin.Mac ===

Version: 3.8.0.3 (Visual Studio Enterprise)

=== Build Information ===

Release ID: 702000487
Git revision: 23dbfec46cc34a04c0b4d31238f0a545418724c3
Build date: 2017-08-01 21:03:19-04
Xamarin addins: b3198fe71ae1abc86e13fc057d882c8a2a2deef6
Build lane: monodevelop-lion-d15-4

=== Operating System ===

Mac OS X 10.12.6
Darwin 16.7.0 Darwin Kernel Version 16.7.0
    Thu Jun 15 17:36:27 PDT 2017
    root:xnu-3789.70.16~2/RELEASE_X86_64 x86_64
Comment 1 Zoltan Varga 2017-08-16 04:29:56 UTC
The error reporting is not good in the alpha, since its missing mono commit 14867dbabec0ac617bb5669b05a444e79a2cf7c6 which fixed it, so we don't know which assembly
is causing the problem.
Comment 2 Sebastien Pouliot 2017-08-16 20:29:04 UTC
@Zoltan can you backport this to mono 2017-04 so our next alpha will be able to better report such issue ? 

Ping me once done and I'll do the bumps of xamarin-macios/d15-4, thanks!


@Frank I'll link to an newer alpha build as soon as bots produce one, but we might need more information at that stage to continue. Thanks for the report!
Comment 3 Zoltan Varga 2017-08-16 22:21:08 UTC
https://github.com/mono/mono/pull/5388
Comment 4 Rolf Bjarne Kvinge [MSFT] 2017-08-17 08:30:10 UTC
@Frank, just a wild guess, but can you try cleaning your solution, and removing the app from your device, and see if that fixes it?
Comment 5 Manuel de la Peña [MSFT] 2017-09-19 14:35:46 UTC
@Franck have you tried @Rolf solution? In the mean time, will close the bug as not response yet do feel free to reopen it if the bug is present.
Comment 6 Ian 2017-11-20 21:35:48 UTC
I started to get this error too. Deleting the BIN / OBJ folders from the app and deleting the app from the iPhone seemed to fix it.

Hopefully, this will help others who get this issue.
Comment 7 Adam 2018-02-12 16:10:33 UTC
I just ran into this as well.  Your solution (deleting bin/obj) worked for me. Thanks.
Comment 8 Steffen 2018-02-15 13:20:02 UTC
Clean & rebuild never die! Unbelievable. Thanks.