Encountering crash in 'Hello' test case #1296
Description
Activity
- addedArea: App RuntimeIssues in `libmonodroid.so`.Issues in `libmonodroid.so`.
on Feb 12, 2018 Can you please provide the diagnostic build log? Also, in the
obj/...tree, what are the contents ofmain.xml?It looks like we’re not properly translating
Mono.Samples.Hello.MyFragmentintomd5whatever.MyFragment, which is why Android can’t find it. Specifically, if I useapktool dto decode the contents ofMono.Samples.HelloTests-Signed.apk,res/layout-v11/main.xmlcontains:<fragment android:name="Mono.Samples.Hello.MyFragment, Hello, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" android:id="@id/csharp_full_assembly" android:layout_width="fill_parent" android:layout_height="wrap_content" />
This is wrong; it should match one of the previous (in the same file!) lines, e.g.:
<fragment android:name="md5c7537e80324c78ebad79edc8b8a9cda5.MyFragment" android:id="@id/csharp_full_assembly" android:layout_width="fill_parent" android:layout_height="wrap_content" />
…but why wouldn’t that be happening? That seems quite odd. :-/
It's plausible that this is fallout from commit e5b1c92 -- last December! -- which wasn't not part of d15-6 (deliberately!). If this is the case, then ~any Xamarin.Android build after 2017-Jan-11 should likewise exhibit this bug, meaning it is not due to the mono/2017-12 bump.
@jonpryor I was unable to reproduce this issue earlier today using monodroid/master/de602598, which is why I was curious as to the delta between master and mono-2017-12.
Diagnostic installation output can be found below:
http://xqa.blob.core.windows.net/gist/log-e7fb0ffa8a224d2ea324a1c06bed7196.txtobj/Release/res/layout/main.xml contains:
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/NameFixups" xmlns:android="http://schemas.android.com/apk/res/android"><ScrollView android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/scroll"><LinearLayout android:id="@+id/extra" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"><ImageView android:id="@+id/image_view" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/case_check" /><md5c7537e80324c78ebad79edc8b8a9cda5.MyView android:id="@+id/csharp_view" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="csharp_view" /><md5c7537e80324c78ebad79edc8b8a9cda5.MyView android:id="@+id/legacy_acw_view" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="legacy_acw_view" /></LinearLayout></ScrollView></LinearLayout>
obj/Release/res/layout-11/main.xml contains:
<LinearLayout android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/NameFixups" xmlns:android="http://schemas.android.com/apk/res/android"><ScrollView android:layout_width="fill_parent" android:layout_height="fill_parent" android:id="@+id/scroll"><LinearLayout android:id="@+id/extra" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent"><ImageView android:id="@+id/image_view" android:layout_width="wrap_content" android:layout_height="wrap_content" android:src="@drawable/case_check" /><md5c7537e80324c78ebad79edc8b8a9cda5.MyView android:id="@+id/csharp_view" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="csharp_view" /><md5c7537e80324c78ebad79edc8b8a9cda5.MyView android:id="@+id/legacy_acw_view" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="legacy_acw_view" /><fragment android:name="md5c7537e80324c78ebad79edc8b8a9cda5.MyFragment" android:id="@+id/csharp_simple_fragment" android:layout_width="match_parent" android:layout_height="wrap_content" /><fragment android:name="md5c7537e80324c78ebad79edc8b8a9cda5.MyFragment" android:id="@+id/csharp_legacy_fragment" android:layout_width="match_parent" android:layout_height="wrap_content" /><fragment android:name="md5c7537e80324c78ebad79edc8b8a9cda5.MyFragment" android:id="@+id/csharp_partial_assembly" android:layout_width="match_parent" android:layout_height="wrap_content" /><fragment android:name="Mono.Samples.Hello.MyFragment, Hello, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null" android:id="@+id/csharp_full_assembly" android:layout_width="match_parent" android:layout_height="wrap_content" /></LinearLayout></ScrollView></LinearLayout>
I think my inability to reproduce yesterday against master may have been due to an accidental usage of a different version which existed in a side by side installation. I am able to reproduce this against master as well.
- changed the title
[-][Mono 2017-12] Encountering crash in 'Hello' test case[/-][+]Encountering crash in 'Hello' test case[/+]on Feb 13, 2018 - added 2 commits that reference this issue
on Feb 14, 2018 - added a commit that references this issue
on Feb 14, 2018 - added a commit that references this issue
on Feb 14, 2018 - added a commit that references this issue
on Feb 21, 2018 Verified fixed in d15-7.
- ghost locked as resolved and limited conversation to collaborators
on Jun 9, 2022
Steps to Reproduce
Mono.Samples.HelloTests-Signed.zip
Expected Behavior
Application launches and the series of test cases which execute at startup will run to completion.
Actual Behavior
Application crashes on startup.
Version Information
Operating System: Microsoft Windows 10 Enterprise 64-bit
Product Name: Xamarin.Android
Branch Name: mono-2017-12
Build Revision: d386c85d46cf4d3b877d6610de14ee2fb84c1b69
[Device] Manufacturer: Google, Model: Pixel XL, Version: 7.1.1, ABI: arm64-v8a, Timezone: America/New_York
Log File
http://xqa.blob.core.windows.net/gist/log-b6d91c4d05284b508516c98e9868492f.txt