TNG / ArchUnit

A Java architecture test library, to specify and assert architecture rules in plain Java
http://archunit.org
Apache License 2.0
3.17k stars 287 forks source link

question about calling line numbers #1257

Closed heyuxiang1996 closed 5 months ago

heyuxiang1996 commented 5 months ago

I use the dex2jar tool to convert APK to a jar package,then use archunit to scan the calls in the converted jar package, All line numbers for calls are 69 such as: Constructor <com.android.settings.ActivityPicker.<init>()> calls constructor <com.android.internal.app.AlertActivity.<init>()> in (ActivityPicker.java:69) I want to know the reasons behind this and whether there is a solution to it

heyuxiang1996 commented 5 months ago

vendor.zip This is an example jar package

hankem commented 5 months ago

ArchUnit can only use the information available in the byte code, but dex2jar might have issues with line numbers, cf. pxb1988/dex2jar#84 / pxb1988/dex2jar#165 / pxb1988/dex2jar#562. Sorry; I fear that ArchUnit cannot solve this "problem".

heyuxiang1996 commented 5 months ago

ArchUnit can only use the information available in the byte code, but dex2jar might have issues with line numbers, cf. pxb1988/dex2jar#84 / pxb1988/dex2jar#165 / pxb1988/dex2jar#562. Sorry; I fear that ArchUnit cannot solve this "problem".

thank you very much