R8 retrace worked fine here until recently. Now, it does not give correct line numbers.
First, here is how I use it:
"C:UsersfooAppDataLocalAndroidSdkcmdline-toolslatestbinretrace" E: ...mapping.txt E:...foo_stack_trace.txt
Suppose I have a stack trace as follows:
Stack trace: java.lang.NullPointerException: Attempt to invoke interface method 'java.lang.String net.my.domain.foo.T0$c.a()' on a null object reference
at net.my.domain.foo.T0.M0(SourceFile:467)
at net.my.domain.foo.T0.B0(SourceFile:102)
at net.my.domain.foo.T0.S(SourceFile:1)
at net.my.domain.foo.P0.run(SourceFile:1)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
at java.lang.Thread.run(Thread.java:1012)
R8 retrace generates the following:
Stack trace: java.lang.NullPointerException: Attempt to invoke interface method 'java.lang.String net.my.domain.foo.T0$c.a()' on a null object reference
at net.my.domain.foo.Decoder.a(SourceFile:1571)
at net.my.domain.foo.Decoder.a(SourceFile:1306)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
at java.lang.Thread.run(Thread.java:1012)
The line numbers 1571 and 1306 are certainly wrong because I know which method throws this exception. It also misses the following two lines:
at net.my.domain.foo.T0.S(SourceFile:1)
at net.my.domain.foo.P0.run(SourceFile:1)
However, the retrace is not completely wrong. It translates “T0” to “Decoder” correctly.
Does anyone else experience this R8 issue with the latest SDKs?