Bug 18369 - Java.Lang.StringBuilder.Append(string s) throws NoSuchMethod exception
Summary: Java.Lang.StringBuilder.Append(string s) throws NoSuchMethod exception
Status: VERIFIED FIXED
Alias: None
Product: Android
Classification: Xamarin
Component: Bindings ()
Version: 4.12.0
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Atsushi Eno
URL:
Depends on:
Blocks:
 
Reported: 2014-03-13 16:50 UTC by Paul
Modified: 2014-06-04 07:45 UTC (History)
3 users (show)

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


Attachments
Test project (11.07 KB, application/octet-stream)
2014-03-13 16:52 UTC, Paul
Details
Log (5.64 KB, text/plain)
2014-03-13 16:53 UTC, Paul
Details


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:
VERIFIED FIXED

Description Paul 2014-03-13 16:50:01 UTC
03-13 19:51:31.572 I/mono-stdout( 4923): 	[FAIL] TestAppendMethod : Java.Lang.NoSuchMethodError : Exception of type 'Java.Lang.NoSuchMethodError' was thrown.
03-13 19:51:31.572 I/mono-stdout( 4923): 		  at Android.Runtime.JNIEnv.GetMethodID (IntPtr kls, System.String name, System.String signature) [0x00066] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.12-series/98634deb/source/monodroid/src/Mono.Android/src/Runtime/JNIEnv.g.cs:161 
03-13 19:51:31.572 I/mono-stdout( 4923): 		  at Java.Lang.StringBuilder.Append (System.String str) [0x00014] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.12-series/98634deb/source/monodroid/src/Mono.Android/platforms/android-8/src/generated/Java.Lang.StringBuilder.cs:255 
03-13 19:51:31.572 I/mono-stdout( 4923): 		  at StringBuilderAppend.StringBuilderTests.TestAppendMethod () [0x00007] in d:\Unsorted\IT\Projects\StringBuilderAppend\StringBuilderAppend\StringBuilderTests.cs:13 
03-13 19:51:31.572 I/mono-stdout( 4923): 		  at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
03-13 19:51:31.572 I/mono-stdout( 4923): 		  at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000] in <filename unknown>:0 
03-13 19:51:31.572 I/mono-stdout( 4923): 		  --- End of managed exception stack trace ---
03-13 19:51:31.572 I/mono-stdout( 4923): 		java.lang.NoSuchMethodError: no method with name='append' signature='(Ljava/lang/String;)Ljava/lang/Appendable;' in class Ljava/lang/StringBuilder;
03-13 19:51:31.572 I/mono-stdout( 4923): 			at mono.android.view.View_OnClickListenerImplementor.n_onClick(Native Method)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at mono.android.view.View_OnClickListenerImplementor.onClick(View_OnClickListenerImplementor.java:29)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at android.view.View.performClick(View.java:4240)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at android.view.View$PerformClick.run(View.java:17721)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at android.os.Handler.handleCallback(Handler.java:730)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at android.os.Handler.dispatchMessage(Handler.java:92)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at android.os.Looper.loop(Looper.java:137)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at android.app.ActivityThread.main(ActivityThread.java:5103)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at java.lang.reflect.Method.invokeNative(Native Method)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at java.lang.reflect.Method.invoke(Method.java:525)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:737)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:553)
03-13 19:51:31.572 I/mono-stdout( 4923): 			at dalvik.system.NativeStart.main(Native Method)
Comment 1 Paul 2014-03-13 16:52:45 UTC
Created attachment 6307 [details]
Test project
Comment 2 Paul 2014-03-13 16:53:34 UTC
Created attachment 6308 [details]
Log
Comment 3 Udham Singh 2014-03-14 00:44:27 UTC
I have checked this issue and able to reproduce it with the attached Test project.

Screencast: http://screencast.com/t/uur7QmRSW
Output logs: https://gist.github.com/saurabh360/32fc244c9f5f8b984d64

Environment Info:

Windows 8.1
VS 2013
Xamarin.Android 4.12.01000
Comment 4 Atsushi Eno 2014-04-21 03:14:41 UTC
This will be fixed in monodroid 4.14. Thanks for the report.

[master 5bcabb2]

(Internal note: I thought it is part of the API description issue, turned out that it was rather metadata fixup issue. New API description does not automagically resolve this.)
Comment 5 Atsushi Eno 2014-04-21 03:34:32 UTC
Paul: we are sorry, we needed further fixes to really get this working.

(Unternal note: turned out it was exactly about the broken API description issue that we definitely need fix in API metadata.)
Comment 6 Atsushi Eno 2014-04-22 06:36:49 UTC
This is really fixed, should be included in monodroid 4.14.

[master f9cbe51]

(Internal note: the API metadata could be still based on current in this fix.)
Comment 7 Mohit Kheterpal 2014-06-04 07:45:45 UTC
I have checked this issue and we are not getting this issue while running attached project as shown in screencast : http://screencast.com/t/gqbwPGDszdl

Hence closing this issue.

Environment info:
Microsoft Visual Studio Professional 2012
Version 11.0.61030.00 Update 4
Microsoft .NET Framework
Version 4.5.50938

Xamarin   3.1.159.0 (c376d19d2984310ff50a6e741e3e3e9ce4f920a5)