Apktool icon indicating copy to clipboard operation
Apktool copied to clipboard

[BUG]The Assets folder in the assets folder is not recognized

Open TorrentialNight opened this issue 4 years ago • 4 comments
trafficstars

Information

1.Apktool Version (apktool -version) - Using Apktool 2.5.0 2.Operating System (Mac, Linux, Windows) - Windows 3.APK From? (Playstore, ROM, Other) - Other

Stacktrace/Logcat

Include stacktrace here There is an Assets folder under the assets folder in APK package. Using apktool to package cannot recognize the assets folder Before packing befor After packing after

The Asstest folder package under assets folder is removed during the packaging process of apktool

TorrentialNight avatar May 24 '21 08:05 TorrentialNight

I put up a failing test for this. It passes on linux, but fails on mac/windows. So must have something to do with our normalization. Either way - I confirm this strange issue.

https://github.com/iBotPeaches/Apktool/pull/2575

iBotPeaches avatar May 31 '21 10:05 iBotPeaches

1 I have modified the source code as shown in the figure and it can work normally. This is the code on the old version of apktool

TorrentialNight avatar Jun 07 '21 08:06 TorrentialNight

1 I have modified the source code as shown in the figure and it can work normally. This is the code on the old version of apktool

I'm struggling to understand how changing the core functionality of Apktool, breaking aapt2 completely will resolve this problem. In the future, PRs for changes are always accepted so the test suite can run on all platforms.

I'm reopening, because the bug is still here.

iBotPeaches avatar Jun 07 '21 10:06 iBotPeaches

Hello, I don't see this issue in APKTool 2.6.1. I have "assets" folder inside "assets" and they're packaged correctly by APKTool. gambar gambar

D:\Data\Development\depls_dist\love_11>java -jar \Application\apktool_2.6.1.jar b -o test.apk ls2build
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=utf-8
I: Using Apktool 2.6.1
I: Checking whether resources has changed...
I: Building apk file...
I: Copying unknown files/dir...
I: Built apk...

D:\Data\Development\depls_dist\love_11>

MikuAuahDark avatar May 30 '22 05:05 MikuAuahDark

I struggle with this ticket to understand the replication steps. I put up my own and it passed, iterated it a few times and it still passed.

So closing - https://github.com/iBotPeaches/Apktool/commit/2b8121584624f0a1b1602992a48fcdbf60c0347d

iBotPeaches avatar Jul 04 '23 17:07 iBotPeaches