Android application not launching (on device or emulator) - android

I have an Android application that used to work fine. I think the last piece of code I added was some sqlite database code. Now, when I run the application:
Says "Launching Application (100%)" in the bottom, right corner.
In the Progress tab, the progress bar is not filled in at all (for launching the application).
Uses up all the allowed ram (760M)
The application doesn't actually get installed on my device (I've also tried this without my device plugged in, and it doesn't make it to the screen to ask me which emulator I want to launch).
When I create a new Android application in the workspace the new application runs fine.
System Details:
Eclipse 4.3 for Mac OS X (installed the latest version including the ADT in an attempt to fix the problem).
Android Developer Tools. Build: v22.6.2-1085508
OS X 10.8.5
Just let me know if I've left out any information and I'll add it in asap.
[Edit:] After leaving it running (not force-quitting), I get this error message:
[2014-06-25 10:07:53 - Application] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class
(org.ibex.nestedvm.util.Sort$1) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
solution is to recompile the class from source, using an up-to-date compiler
and without specifying any "-target" type options. The consequence of ignoring
this warning is that reflective operations on this class will incorrectly
indicate that it is not an inner class.
[2014-06-25 10:18:10 - Dex Loader] Unable to execute dex: Java heap space
[2014-06-25 10:18:10 - Application] Conversion to Dalvik format failed: Unable to execute dex: Java heap space

Related

Android FirebasePerformance issue with Proguard

We implemented FirebasePerformance in our project and when are unable to build the project. I get below error in Proguard which has something to do with having a two classes with same name but different cases (A.class and a.class) in the external library (qrchart_obfuscation.jar). I am not very familiar with proguard also.
Reading thru sources, I am looking to add -dontwarn option in proguard but this will be my last resort since sources says to "use it only when you know what you are doing".
I still tried to add -dontwarn qr.android.chart and I compared Mapping.txt with my previous builds which does not have FirebasePerformance and I see a difference on the class (qr.android.chart) not sure if this detail helps
Appreciate your help and suggestions with proguard setup for FirebasePerformance.
Reading program directory [C:\...\build\intermediates\transforms\FirebasePerformancePlugin\adevelop\release\4] (filtered)
Warning: class [qr/android/chart/b/a.class] unexpectedly contains class [qr.android.chart.b.A]
Warning: class [qr/android/chart/b/b.class] unexpectedly contains class [qr.android.chart.b.B]
Warning: class [qr/android/chart/b/c.class] unexpectedly contains class [qr.android.chart.b.C]
Warning: class [qr/android/chart/b/d.class] unexpectedly contains class [qr.android.chart.b.D]
Warning: class [qr/android/chart/b/e.class] unexpectedly contains class [qr.android.chart.b.E]
Warning: class [qr/android/chart/b/f.class] unexpectedly contains class [qr.android.chart.b.F]
Warning: class [qr/android/chart/b/g.class] unexpectedly contains class [qr.android.chart.b.G]
Warning: class [qr/android/chart/b/h.class] unexpectedly contains class [qr.android.chart.b.H]
Warning: class [qr/android/chart/b/i.class] unexpectedly contains class [qr.android.chart.b.I]
Warning: class [qr/android/chart/b/j.class] unexpectedly contains class [qr.android.chart.b.J]
Warning: class [qr/android/chart/b/k.class] unexpectedly contains class [qr.android.chart.b.K]
Warning: there were 11 classes in incorrectly named files.
You should make sure all file names correspond to their class names.
The directory hierarchies must correspond to the package hierarchies.
(http://proguard.sourceforge.net/manual/troubleshooting.html#unexpectedclass)
If you don't mind the mentioned classes not being written out,
you could try your luck using the '-ignorewarnings' option.
I saw this link with regards to Firebase performance and proguard issue during build of signed APK but different case -FirebasePerformance SDK external library issue in progaurd
The problem is the qr.android.chart library isn't using the dontusemixedcaseclassnames option when proguarding.
When building on a case insensitive file system (i.e., that Mac OSX likes to use), the byte code instrumentation process Firebase Performance uses runs into issues because the unarchived classes end up overwriting each other.
Your options are to either disable byte code instrumentation or ask for a new qr.android.chart library with the dontusemixedcaseclassnames option activated.
If you are working on macOS, I've found an ugly workaround for this. Create a case sensitive disk image and copy the project there, so firebase perf plugin can handle the case sensitive files.
How to create the disk image here: https://documentation.spryker.com/tutorials/howtos/ht-case-sensitive-file-system-mac.htm
For my project I needed a 5gb image.

Android 4.4 port compile error

I've been working on an android 4.4 kitkat port to D2ATT and I keep getting this build error:
including ./hardware/qcom/display/Android.mk ...
build/core/copy_headers.mk:15: warning: overriding commands for target out/target/product/d2att/obj/include/qcom/display/copybit.h'
build/core/copy_headers.mk:15: warning: ignoring old commands for targetout/target/product/d2att/obj/include/qcom/display/copybit.h'
build/core/copy_headers.mk:15: warning: overriding commands for target out/target/product/d2att/obj/include/qcom/display/copybit_priv.h'
build/core/copy_headers.mk:15: warning: ignoring old commands for targetout/target/product/d2att/obj/include/qcom/display/copybit_priv.h'
build/core/base_rules.mk:134: *** hardware/qcom/display/msm8960/liblight: MODULE.TARGET.SHARED_LIBRARIES.lights.msm8960 already defined by device/samsung/d2-common/liblights. Stop.
Does anyone know how to fix this or what it means? Thanks!
This means MODULE.TARGET.SHARED_LIBRARIES.lights.msm8960 is defined by both hardware/qcom/display/msm8960/liblight and device/samsung/d2-common/liblights files, so you either remove one of them from the linking -if you don't have source code- or comment this definition in one of them.

Trying to create Email Client in Android, but got many warnings and emulator fails to launch

I am trying to create an email client on android, I am new to android so, I tried different sample codes but I'm getting many warning two of which are given below and android emulator fails to lauch...Can email client application run on emulator?(I used following links:
http://www.jondev.net/articles/Sending_Emails_without_User_Intervention_%28no_Intents%29_in_Android
Sending Email in Android using JavaMail API without using the default/built-in app
)
[2012-07-24 13:01:56 - test] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class
(javax.activation.DataHandler$1) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
solution is to recompile the class from source, using an up-to-date compiler
and without specifying any "-target" type options. The consequence of ignoring
this warning is that reflective operations on this class will incorrectly
indicate that it is not an inner class.
[2012-07-24 13:01:56 - test] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class
(javax.mail.Session$2) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
solution is to recompile the class from source, using an up-to-date compiler
and without specifying any "-target" type options. The consequence of ignoring
this warning is that reflective operations on this class will incorrectly
indicate that it is not an inner class.
Answer is "No", E-mail client will not works in emulator because the emulator doesn't include any email application
Sync your mail account into your actual device and then try in actual device it will work.

How work with wsdl service in android contained in Azure

1).I generated Web Service Client from WSDL (use Axis2 1.5 carnel, wsdl2java,Tomcat 7.0);
2). Accessing a JAX-WS web service from Android use KSoap2-android library (I tested this lib on service http://www.webservicex.net/ConvertWeight.asmx and it works ok). But work with http://xxx.svc?wsdl I can't connect to the service. When I generated the Web Service Client from Android Progect I get this error :
"IWAB0399E Error in generating Java from WSDL: java.io.IOException: Emitter failure. There is an undefined binding (BasicHttpBinding_ICustomerService) in the WSDL document. Hint: make sure is fully qualified."
3). From Web Service Client I make service.jar, which used on Android Progect how lib, but not working.
4). When I used ksoap2 I get this error:
[2012-06-26 17:25:33 - TranscribeMe_2.2] Dx 1 error; aborting
[2012-06-26 17:25:33 - TranscribeMe_2.2] Conversion to Dalvik format failed with error 1
[2012-06-26 17:26:32 - TMP] Dx warning: Ignoring InnerClasses attribute for an anonymous inner class
(org.ksoap2.transport.KeepAliveHttpsTransportSE$1) that doesn't come with an
associated EnclosingMethod attribute. This class was probably produced by a
compiler that did not target the modern .class file format. The recommended
solution is to recompile the class from source, using an up-to-date compiler
and without specifying any "-target" type options. The consequence of ignoring
this warning is that reflective operations on this class will incorrectly
indicate that it is not an inner class.
[2012-06-26 17:26:33 - TMP] Dx
trouble processing "javax/xml/ws/Dispatch.class":
Ill-advised or mistaken usage of a core class (java.* or javax.*)
when not building a core library.
This is often due to inadvertently including a core library file
in your application's project, when using an IDE (such as
Eclipse). If you are sure you're not intentionally defining a
core class, then this is the most likely explanation of what's
going on.
However, you might actually be trying to define a class in a core
namespace, the source of which you may have taken, for example,
from a non-Android virtual machine project. This will most
assuredly not work. At a minimum, it jeopardizes the
compatibility of your app with future versions of the platform.
It is also often of questionable legality.
If you really intend to build a core library -- which is only
appropriate as part of creating a full virtual machine
distribution, as opposed to compiling an application -- then use
the "--core-library" option to suppress this error message.
If you go ahead and use "--core-library" but are in fact
building an application, then be forewarned that your application
will still fail to build or run, at some point. Please be
prepared for angry customers who find, for example, that your
application ceases to function once they upgrade their operating
system. You will be to blame for this problem.
If you are legitimately using some code that happens to be in a
core package, then the easiest safe alternative you have is to
repackage that code. That is, move the classes in question into
your own package namespace. This means that they will never be in
conflict with core system classes. JarJar is a tool that may help
you in this endeavor. If you find that you cannot do this, then
that is an indication that the path you are on will ultimately
lead to pain, suffering, grief, and lamentation.
[2012-06-26 17:26:33 - TMP] Dx 1 error; aborting
[2012-06-26 17:26:33 - TMP] Conversion to Dalvik format failed with error 1
Please, help me...
IF you will search StackOverFlow for Axis and WCF/WSDL issues you will find a lot without any answer or suggestion so there is not a lot you would be able to
About your following error:
There is an undefined binding (BasicHttpBinding_ICustomerService) in the WSDL document.
Hint: make sure is fully qualified."
I can say that the problem probably related with how you ICustomerService bindings are defined. As you have chosen BasicHttpBinding, please make sure all the parameters are correct . If you check your Axis generated WSDL, you will be able to verify it easily.
Also in some cases you might hit namespace issues and which could cause Axis WSDL to genatate service.svc?wsdl=wsdl0 and service.svc?wsdl=wsdl1. If that is the case, you can resolve namespace issues by adding namespace attribute for your each data contract along with message header, body and added bindingnamespace attribute in web service end point.
My first suggestion will be to create a simple C# client application and connect to your Windows Azure WCF service to and verify you could connect using BasicHttpBindings without any problem and then use Java app to do the same. If you see the problem, compare the network traffic between two to see the different which might help you to figure out the root cause and for very specific problem ask questions at SO and you will get proper help. Good Luck!!

Odd compiler error, Davlik error 1 from java.net.DatagramPacket.class

I suddenly started getting an unusual compiler error and is it making impossible to do any testing, I am running Eclipse with the plugin and compiling on the 2.1 version.
[2010-08-11 00:29:38 - PeriodTrackerv2]
trouble processing "java/net/DatagramPacket.class":
[2010-08-11 00:29:38 - PeriodTrackerv2]
Attempt to include a core class (java.* or javax.*) in something other
...
[2010-08-11 00:29:38 - PeriodTrackerv2] 1 error; aborting
[2010-08-11 00:29:38 - PeriodTrackerv2] Conversion to Dalvik format failed with error 1
I verified that this class does exist in the standard Android2.1 jar file, so I find it highly unusual a class in the actual base Jar file would be problematic. I am not using this class in any fashion in my program.
I updated to version 2.2 and still get same error, this completely baffles me and just appeared tonight after zero issues for months.
Any ideas on how to fix this?
Cheers,
Tom
Alright!
I reviewed the build path and somehow the Android.jar was added twice. Problem solved.

Categories

Resources