Bug 12844 - Getting exception "Java.Lang.NoClassDefFoundError" when click on 'Basic Map' or 'Markers'
Summary: Getting exception "Java.Lang.NoClassDefFoundError" when click on 'Basic Map' ...
Status: VERIFIED FIXED
Alias: None
Product: Android
Classification: Xamarin
Component: Samples ()
Version: 4.6.x
Hardware: PC Mac OS
: --- normal
Target Milestone: 4.8 (async)
Assignee: Peter Collins
URL:
Depends on:
Blocks:
 
Reported: 2013-06-24 05:45 UTC by Nischal
Modified: 2013-07-11 04:39 UTC (History)
2 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:
VERIFIED FIXED

Description Nischal 2013-06-24 05:45:06 UTC
Steps to reproduce this issue:
1. Open Android 'GooglePlayServices' sample.
2. Follow the read me steps.
3. Build the application.
4. Debug or run the application.
5. Click either 'Basic Map' or 'Markers'.

Actual Result: When user click on  'Basic Map' or 'Markers', Application crashed and throwing exception "Java.Lang.NoClassDefFoundError"

Expected Result: Application should not crashed after clicking on 'Basic Map' or 'Markers'.

Supplement info:
Crash log: https://gist.github.com/atin360/ef4d20efb3dfb0b2d104
Android logcat: https://gist.github.com/atin360/5615cc8c2a058bcfdd8d
Diagnostics logs: https://gist.github.com/atin360/d87dac137fa63d3d4cf6

Environment details:
All Mac
X.S 4.0.99build 9)
Mono 2.10.12
Xamarin.Android 4.6.9

Regression Status:
NOT A REGRESSION same behavior happening with 4.6.8-7
Comment 1 Nischal 2013-06-24 05:59:35 UTC
An update to the issue is:

We have tried it on Physical device Google Nexus 4.1.2 and Google API-10's Emulator.
Comment 2 PJ 2013-07-01 13:38:14 UTC
Peter can you check on the regression status here and talk to Eno about it? I'm not sure if there's a new Google Play Library involved with the regression status report of 'Not a regression'.
Comment 4 Prashant manu 2013-07-04 09:45:58 UTC
Today I have checked this issue with following builds:

All Mac
X.S 4.0.9(build 12)
Mono 3.0.12
Xamarin.Android 4.7.11-2-1

And we have added docs folder and project.properties as a link in GooglePlayServices project and then we have run the project on GoogleAPI-17 emulator and we are still getting exception. Please view the screencast of Project which having docs on Project.properties: http://screencast.com/t/vykKU63R8BDU

Hence reopening this issue
Comment 5 Peter Collins 2013-07-08 17:35:19 UTC
This exception seems to be occurring when the google_play_services_lib project has not been updated and built with ant. Please attempt to build the Google Play Services binaries the following instructions before building the GooglePlayServicesTest sample.

>Build the Google Play Services SDK binaries, using eclipse or ant. The library is located at: >$(ANDROID_SDK)/extras/google/google_play_services/libproject/google-play-services_lib.

>Run the following in the directory mentioned above to build with ant:
>   $(ANDROID_SDK)/tools/android update project -p .
>   ant debug

After building the google play services binaries, properly linking the required files and updating the API Key I am unable to reproduce the issue mentioned above.
Comment 6 Peter Collins 2013-07-08 17:36:19 UTC
Build instructions ran over by mistake, reposting better format:

>Build the Google Play Services SDK binaries, using eclipse or ant. The library is located at:

>$(ANDROID_SDK)/extras/google/google_play_services/libproject/google-play-services_lib.

>Run the following in the directory mentioned above to build with ant:
>   $(ANDROID_SDK)/tools/android update project -p .
>   ant debug
Comment 8 Nischal 2013-07-11 04:39:04 UTC
Today I have checked this issue with following builds

X.S 4.0.9(build 9)
Mono 3.1.1-2
Xamarin.Android 4.8.0-1

We have followed the comment which are mentioned in comment#6 and then we observed that build.xml file is missing form GooglePlayServices/libs/google-play-services, first we have created build.xml file using command   "Desktop/android-sdk-macosx/tools/android update project -p Desktop/android-sdk-macosx/extras/google/google_play_services/libproject/google-play-services_lib/"

And then we have build and debug the Google_Play_Services/libs/google_play_services using ant this is the gist for the same: https://gist.github.com/atin360/d07a4915d72a90102e73 after that we open the GooglePlayServices in XS and added file and folder in GooglePlayServices Project as a link and then we run the project on device. Now application working fine and we are successfully able to open map after clicking on Basic Map and successfully able to open Drag Melbourne after clicking on Markers.

Device info:
Galaxy S4 version 4.2.2
HTC one version 4.0.4

Now closing this issue.