VFY: unable to find class referenced in signature

by hefeng » Tue, 07 Jul 2009 00:06:43 GMT


Sponsored Links
 Hello,

I try to port the XMPP library to android sdk 1.5, follow the demo
ApiDemo from the sdk,  I created a directory something like below:

      smack--+AndroidManifest.xml                          ..The
manifest for the smack library

                    |
 
+src                                                     ..The source
code for the smack
                    :
                    :
                    ------
test                                              .. The test
directory for the test case
                                  |
                                 +
AndroidManifest.xml                              .. The manifest for
the test code
                                  |
                                  :
                                  :
 
+src                                                            .. The
test code for the smack library.

After I build both projects, I install them respectively on the
emulator, then I launch the test case by command:
$ adb shell am instrument -w org.jivesoftware.smack.test/
android.test.InstrumentationTestRunner

then console output following information:
$INSTRUMENTATION_RESULT: shortMsg=org.jivesoftware.smack.LoginTest
$INSTRUMENTATION_RESULT: longMsg=java.lang.VerifyError:
org.jivesoftware.smack.LoginTest
$INSTRUMENTATION_CODE: 0

I think there is something wrong with the test case then I check with
command:

$adb logcat

I found following error message in the log:
:
:
D/AndroidRuntime( 1216): --- registering native functions ---
D/ActivityManager(  564): Uninstalling process
org.jivesoftware.smack.test
I/ActivityManager(  564): Start proc org.jivesoftware.smack.test for
added application org.jivesoftware.smack.test: pid=1223 uid=10019 gids=
{}
W/dalvikvm( 1223): VFY: unable to find class referenced in signature
(Lorg/jivesoftware/smack/XMPPConnection;)
E/dalvikvm( 1223): Could not find method
org.jivesoftware.smack.XMPPConnection.connect, referenced from method
org.jivesoftware.smack.LoginTest.testInvalidLogin
W/dalvikvm( 1223): VFY: unable to resolve virtual method 176: Lorg/
jivesoftware/smack/XMPPConnection;.connect ()V
:
It seems there is something wrong for the dalvik to resolve the
connect method in the org.jivesoftware.smack package, so I type the
command

$ adb shell dexdump -d -f -h /data/dalvik-cache/
d...@app@org.jivesoftware.smack....@classes.dex | grep XMPPConnection

then, I find following information in output
    #4              : (in Lorg/jivesoftware/smack/XMPPConnection;)
013130:                                        |[013130]
org.jivesoftware.smack.XMPPConnection.connect:()V

It seems that the XMPPConnection class with its method have been
install properly already.



--~--~---------~--~----~------------~-------~--~----~



VFY: unable to find class referenced in signature

by hefeng » Tue, 07 Jul 2009 00:07:21 GMT


 Hello,

I try to port the XMPP library to android sdk 1.5, follow the demo
ApiDemo from the sdk,  I created a directory structure something like
below for two packages org.jivesoftware.smack &
org.jivesoftware.smack.test :

      smack--+AndroidManifest.xml               ..The manifest for
package org.jivesoftware.smack

                    |
 
+src                                                 ..The source code
for the smack
                    :
                    :
                    ------
test                                          .. The test directory
for the test case
                                  |
                                 + AndroidManifest.xml              ..
The manifest for the package   org.jivesoftware.smack.test
                                  |
                                  :
                                  :
 
+src                                                            .. The
test code for the smack library.

After I build both projects, I install both package respectively on
the emulator, then I try to launch the test case by command:
$ adb shell am instrument -w org.jivesoftware.smack.test/
android.test.InstrumentationTestRunner

then console output following information:
$INSTRUMENTATION_RESULT: shortMsg=org.jivesoftware.smack.LoginTest
$INSTRUMENTATION_RESULT: longMsg=java.lang.VerifyError:
org.jivesoftware.smack.LoginTest
$INSTRUMENTATION_CODE: 0

I think there is something wrong with the test case then I check with
command:

$adb logcat

I found following error message in the log:
:
:
D/AndroidRuntime( 1216): --- registering native functions ---
D/ActivityManager(  564): Uninstalling process
org.jivesoftware.smack.test
I/ActivityManager(  564): Start proc org.jivesoftware.smack.test for
added application org.jivesoftware.smack.test: pid=1223 uid=10019 gids=
{}
W/dalvikvm( 1223): VFY: unable to find class referenced in signature
(Lorg/jivesoftware/smack/XMPPConnection;)
E/dalvikvm( 1223): Could not find method
org.jivesoftware.smack.XMPPConnection.connect, referenced from method
org.jivesoftware.smack.LoginTest.testInvalidLogin
W/dalvikvm( 1223): VFY: unable to resolve virtual method 176: Lorg/
jivesoftware/smack/XMPPConnection;.connect ()V
:
It seems there is something wrong for the dalvik to resolve the
connect method in the org.jivesoftware.smack package, so I type the
command

$ adb shell dexdump -d -f -h /data/dalvik-cache/
d...@app@org.jivesoftware.smack....@classes.dex | grep XMPPConnection

then, I find following information in output
    #4              : (in Lorg/jivesoftware/smack/XMPPConnection;)
013130:                                        |[013130]
org.jivesoftware.smack.XMPPConnection.connect:()V

It seems that the XMPPConnection class with its method have been
install properly already, then I lost ideal how to finger out the
problem, please give me a hand, any comments are appreciated.

--~--~---------~--~----~------------~-------~--~----~


Sponsored Links


VFY: unable to find class referenced in signature

by fadden » Tue, 07 Jul 2009 03:41:15 GMT


 


I'd guess that the org.jivesoftware.smack.apk file is not present in
the process responding to the instrumentation test request.

--~--~---------~--~----~------------~-------~--~----~



Other Threads

1. Translate Animation unable to update Button onClick area

Hi all,

I'm having a bit of trouble getting this code to work. I set up a 
RelativeLayout menu with a couple of buttons and ,when a certain action 
is performed, this menu changes its position through a translate 
animation. the problem is that the clickable area of the buttons is not 
updated, thus the buttons don't work after the translation (if I click 
the button's old position it works though ;]). Can someone shed some 
light on this? is this the expected behaviour?

I also tried the LayoutAnimation and the result is the same.



Java code:

<...>
ViewGroup menu = findViewById(R.id.menu);
menu.setVisibility(View.VISIBLE);
menu.startAnimation(AnimationUtils.loadAnimation(this, 
R.anim.push_up_little));
<...>


The XML rotation (push_up_little.xml)

<?xml version="1.0" encoding="utf-8"?>

<set xmlns:android="http://schemas.android.com/apk/res/android"
    android:fillAfter="true">
    <translate
        android:fromYDelta="0"
        android:toYDelta="-58"
        android:duration="300"
        android:fillAfter="true"
        android:zAdjustment="top"/>
</set>



The Menu button XML

                   <RelativeLayout
                       android:id="@+id/menu"
                    android:visibility="gone"
                    android:layout_gravity="bottom"
                    android:layout_width="fill_parent"
                    android:layout_height="100dp"
                    android:layout_marginBottom="-40dp"
                    android:layout_alignParentBottom="true">

                    <Button
                        android:id="@+id/button"
                        android:layout_width="123dp"
                        android:layout_height="41dp"
                        android:layout_marginTop="11dp"
                        android:layout_marginRight="12dp"
                        android:layout_alignParentTop="true"
                        android:layout_alignParentRight="true"
                        android:paddingLeft="0dp"
                        android:paddingRight="0dp"
                        android:paddingTop="0dp"
                        android:paddingBottom="dp"
                        android:visibility="gone"
                        android:textSize="20sp"
                        android:textColor="#A111"
                        android:text="Share"
                        android:background="@+drawable/btn"/>

                <more buttons...>

                </RelativeLayout>




--~--~---------~--~----~------------~-------~--~----~

2. ImageButton layout issues

I am having a problem with how my images display.  For some reason, my
layout weights are being ignored and my set of ImageButtons in the
center of the screen are extending to the bottom of the screen,
completely removing the button beneath.  Basically, android:scaleType
is making the images fit exactly how I want, but the button area
itself is giving me headaches.

I am trying to get something that looks like this (Using LinearLayout
for each row):

ImageButton ImageButton ImageButton
|--- ImageButton ---|

The images I am currently using are being scaled down to fit the
button (Which works in the emulator, but completely breaks in the
Eclipse preview).  Should I manually shrink the images and scale them
up?  Is there something in the XML file that I am missing?  I'm really
looking for a solution involving defining the max size the button can
take up, but not finding anything that will do the job.
--~--~---------~--~----~------------~-------~--~----~

3. Application crash when instantiating ViewGroup in GridView

4. NIO Buffer position problem?

5. Hello android_beginers

6. how import org.apache.commons.httpclient ?

7. Stored data files in Android App