-
Notifications
You must be signed in to change notification settings - Fork 797
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
java.lang.VerifyError while using @DebugLog anywhere in my app #9
Comments
Same here 👍
|
Provide more info. Method signature, android version, etc. |
Android ver : 4.3 Added debuglog in,
however error seems to be in importFromGoogleAuth, which doesn't have annotation
|
Are you able to reproduce this in a different, simple file? Something that plays more like an example that you'd be comfortable sharing. And then can you send both the java and the compiled class file over? It's hard to see what's really going on with the generated code unless I have a class file to inspect. |
I'm unable to reproduce the issue in simple classes, always reproduced in few classes, I will try to reproduce and send you the logs, |
Thanks!
|
@JakeWharton In testing to boil down my class into an example I found I understand less and less about what is going on with this issue. I was able however to provide a simple example to reproduce it. |
We just hit an app internally that does this as well. I'll try to look If any eager souls out there want to give it a shot it'll start with Jake Wharton On Tue, Dec 10, 2013 at 10:16 AM, Daniel Huckaby
|
@DHuckaby I just ran your code and couldn't find any issue:
I'm running this code on my Nexus 4 with API 19 (Android 4.4) with hugo 1.0.1. |
I have a compiled version of a class file that exhibits this behavior that I need to do inspect later. @DHuckaby Can you post the compiled class file of the example above when it fails for you? |
OK great we ran into this yesterday. +1 |
Can anybody share a bit of code that reproduces this issue? |
Not without giving away alot of internal code, but whats odd is its unrelated, it caused VerifyErrors on code which wasn't tagged with |
The class was not tagged at all? Be aware that line numbers might be incorrect. |
A calling parent method was, but was a method down the execution chain which threw the VerifyError. Sorry I can't be more helpful.. I'll see if I can pull out the offending code later. |
Oh and this might of already been established, but its is only an issue on Java7, change back to 1.6 and all is smooth sailing. |
@danielkutik Did you compile it against java 7? @JakeWharton What exactly do you want? The .class file? |
Also compiled using java 7 |
Yes. The class file. Preferably in the smallest possible file you can get
|
Excellent. Can you paste the verify logs that correspond to this file too? |
@JakeWharton I added it to the gist https://gist.github.com/DHuckaby/08258c12ab311d5374c2 |
@DHuckaby Are you able to get a class file that was compiled with Java 6 that does not exhibit the failure. |
@JakeWharton Here you go, it works fine with Java 6. http://cloud.tweedleapp.com/3U122y0Z413S |
My best guess thus far is the |
Actually |
@JakeWharton It crashes on 4.4 also, tested on a stock Moto X. |
@JakeWharton same, HTC One GE 4.4.1 Java7 VerifyError. On 11 December 2013 17:57, Daniel Huckaby notifications@github.com wrote:
|
I so far have never experienced this issue... I compiled https://gist.github.com/DHuckaby/08258c12ab311d5374c2 with java7 and android sdk 19 running it on my nexus 4 (4.4) (not 4.4.1!?).
I don't want to blame it simply on other projects :) but let's find a reproducible issue (environment + sourcecode)... Please try to run the failing apk also on emulated environments (same OS version as well as different ones) |
@danielkutik From your comment it doesn't sound like you tested it using Dalvik. ART is an experimental runtime, I wouldn't use it for debugging anything at this point if it bombs out on the default runtime. Here is a full example project importing the very simple example, and it still crashes: |
Actually, now that I'm trying to reproduce it with
causes it to crash. Then of course, if you make all your methods non-private after that, it will run fine.... |
I'm getting this same issue. Haven't seen it work yet. Seems to blow up when I instantiate a fragment in a private internal class (internal FragmentStatePagerAdapter). I'm also using
|
#9 (comment) and #9 (comment) describe exactly how I get this error: Java 7 + private method accessed from a inner class |
In a weird way, this has happened to me several times and seemed to be related to ternary expressions |
Just to add, i also experienced this bug when using JavaVersion.VERSION_1_7, switching to 1.6 does not cause the bug. |
I'm seeing the same thing as vinc3m1, I have a method that when marked private it causes this issue. Change it to package protected, no problem. Any suggestions on where I can look to help figure out what is causing this? |
Same issue here after setting source and target compatibility to 1.7; The behavior I'm seeing (VerifyError when accessing private methods from inner classes) and the workaround (making everything either public or protected) match up with what @vinc3m1 found |
In my case: This gives a VerifyError: final int value = 5 + (flag ? 4 : 7); Switching to this works just fine ( no other changes ): final int value = (flag ? 4 : 7) + 5; Putting that code in a minimal class for SSCCE didn't trigger the error. :( The code above is NOT in a @debuglog method. The VerifyError points to another method in the same class ( also not a @debuglog method ). But if I remove all @debuglog from that particular class, everything works fine... ( Using JDK 7 javac ) |
I am not sure if this is related, I am using AspectJ in a different project, and I noticed if I use sdk buildtools 19 (19.1.0), then I get VerifyError when running advised code. If I e.g. switch to 21 (21.1.1) then it works. |
The issue seems to have been resolved by upgrading to the latest build tools.
The issue seems to have been resolved by upgrading to the latest build tools.
I was able to reproduce this issue by adding the empty When I upgraded to the latest set of build tools, the issue goes away. |
The issue seems to have been resolved by upgrading to the latest build tools.
The issue seems to have been resolved by upgrading to the latest build tools.
The issue seems to have been resolved by upgrading to the latest build tools.
The issue seems to have been resolved by upgrading to the latest build tools.
The issue seems to have been resolved by upgrading to the latest build tools.
Fixed by #62. |
java.lang.VerifyError while using |
@msdx The latest Hugo version is 1.2.1, you should try with that one first as it should contain a fix for this issue. |
@reisub The new version 1.2.1 has the same result.
|
+1. latest hugo, gradle tools 2.0.0. Interestingly it only happens on older android I use for testing. No problems on 5.1, but old 4.1.2 phone crashes on any method annotated with @debuglog. |
+1 same problem as tentypwtk, crash with device 4.4, but not newer android os version |
2 similar comments
+1 same problem as tentypwtk, crash with device 4.4, but not newer android os version |
+1 same problem as tentypwtk, crash with device 4.4, but not newer android os version |
+1. I can confirm the appearance of this issue. Tested on Nexus 7 (2012 edition) with Android 4.2. Hugo version is the latest. Gradle version is 2.1.2. On newer android versions all is working just fine. |
+1 Using Hugo version 1.2.1 and Gradle version 2.1.0 Works when minsdk = 20 but not when minsdk = 19 |
The text was updated successfully, but these errors were encountered: