-
-
Notifications
You must be signed in to change notification settings - Fork 360
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
bug: TikTok: Failed to apply patches: Dependency errors with 'Settings' causing multiple failures #525
Comments
I get the same error I've tried a couple different versions of TikTok |
Are you patching with Manager, or with command line tools? Edit: the stack trace shows it's Flutter, so it's patched with Manager. |
Manager I've never succeeded in patching TikTok before, even with older Manager/TikTok versions, but today i decided to open the issue. |
File a bug report in Manager repository, it might be an issue with Manager not allocating enough memory to the patcher. Or there's a chance it's something going haywire during the patcher decoding and it's blowing out the device memory limit. For now you can patch using command line tools, but you'll probably also have to include the |
I saw this comment there, so prolly not a Manager issue if that person is right. |
yea it don't work with manager android13- pixel5 6gb ram , have to use the cli with revanced-patches jar and revanced-integrations apk instead, make sure to use an other java version (i'm using openjdk-18) if you see the error
while signing the apk with the cli |
Hi, I solved it by using the CLI, you can read this Reddit thread for a guide |
I'm a Manager user. |
This issue should be moved to Manager repository. This issue only shows up when patching with Manager. Manager already has But perhaps the Flutter/Dart settings can be adjusted? I've never used Flutter or Dart so I can't comment on this much. |
I don't think anything can be done. The problem is caused by the Android runtime not giving us enough java heap memory. Dart memory allocations don't contribute to that limit if I understand things correctly. People who run into this have to use the CLI in Termux instead, which does not have this memory limit. |
The OOM stack trace here shows the max heap is set to a modest 512MB (some users have shown OOM at 256MB), which seems small if the maxheap flag is being applied to the patching process. If Dart does not contribute to the heap memory of the android app, then it must be running on its own process/service or some other memory isolation. That means it might be possible to increase the max memory of that process/service. If this truly cannot be fixed, then maybe the OOM can be caught and the user informed that Manager won't work and CLI is required. |
|
There is no such thing as "Disabling" patches. TikTok can be patched on ReVanced Manager if you have enough memory, but the issue is inherently large memory usage due to dexlib2. ReVanced Manager can fix it by increasing max memory usage. |
Fixed in Manager v1.7.0 |
Not sure how it was fixed when 1.7.0 has no patcher or memory related changes, but oh well 🤷🏼♂️ |
We already did and its still not enough for some devices |
I have tried the exact same process i tried with the previous Manager and i got no issues now, i have also tested with the version of TikTok where this issue appeared and i got no memory errors, It's fair to say Manager v1.7.0 fixed the memory issue. |
When patching using Termux, it doesn't have these memory limitations. And it's a regular android app, and it even has the memory overhead of running a full Linux system (which surely uses more memory than the ReVanced Manager UI). Yet Termux has no OOM problems. For reference, Java command line in Termux shows a max heap memory of 1.8GB. Meanwhile the patcher in Flutter Manager is blowing out at 256 or 512MB. |
Termux does not run an entire operating system. It just launches linux processes. Only dalvik code running in ART is subjected to the problematic java heap limit. It does not apply when running the JRE in Termux. |
I believe i spoke a bit too soon. When i tried an older version of TikTok, i encountered a different error unrelated to memory issues. The suggested version of Tiktok for patching should not be set as "All," as some versions work just fine, like Initializing installer
Creating working directory
Copying original apk
Unpacking input apk
Reading dex files
Decoding AndroidManifest.xml only, because resources are not needed
Merging integrations
Executing patches
Failed to apply Downloads: 'Downloads' depends on 'Settings' but the following error was raised: Failed to resolve SettingsEntryFingerprint
Failed to apply Feed filter: 'Feed filter' depends on 'Settings' but the following error was raised: 'Settings' did not succeed previously
Applied Hide ads
Failed to apply Playback speed: NullPointerException
Failed to apply Settings: 'Settings' did not succeed previously
Failed to apply Sim spoof: 'Sim spoof' depends on 'Settings' but the following error was raised: 'Settings' did not succeed previously
Repacking patched apk
Not compiling resources because resource patching is not required
Writing modified dex files
Finished! |
This is not a patch issue. There is simply not enough RAM provided to patch the app on your end. |
So enough RAM is only provided to certain TikTok apks but not others, is that what you are trying to say? In the last error, how can you tell if enough RAM was not provided? |
Enough RAM is needed to patch TikTok. The last error is a product of patching an old version. |
Forget the memory issue now, it has been addressed in Manager v1.7.0. and i tested and got no memory errors. The last issue is not related to memory and the suggested version of Tiktok for patching is set to"All," so i don't understand why you mention "old version"? read my posts once again, you seem like you have a hard time distinguishing between a memory issue and something else, please re-open this issue. @Axelen123 Can you confirm if this is a Manager issue or not? |
Long answer: Short answer: I would say this is a manager issue, but we cannot do anything about it. If you are having another problem then you need to open a new issue so it can be tracked properly. |
Patching large applications (e.g. TikTok) on Android with multithreading simply doesn't work on multicore devices where the amount of memory given to the manager (regardless of the system RAM) is not sufficient. It's more important that patching succeeds for all available use cases than for only some patching to succeed with faster performance. A UI option can be added later, but the multithreading option should be opt-out by default rather than opt-in. Closes ReVanced/revanced-documentation#35 Closes ReVanced#1454 Closes ReVanced#1571 Closes ReVanced#1595 Closes ReVanced#1659 Closes ReVanced#1661 Closes ReVanced#1684 Closes ReVanced#1759 Closes ReVanced#1802 Closes ReVanced#1817 Closes ReVanced/revanced-manager#2885 Closes ReVanced#592 Closes ReVanced/revanced-patcher#193 Closes ReVanced/revanced-patches#1533 Closes ReVanced/revanced-patches#1608 Closes ReVanced/revanced-patches#1613 Closes ReVanced/revanced-patches#1630 Closes ReVanced/revanced-patches#190 Closes ReVanced/revanced-patches#2511 Closes ReVanced/revanced-patches#525
Patching large applications (e.g. TikTok) on Android with multithreading simply doesn't work on multicore devices where the amount of memory given to the manager (regardless of the system RAM) is not sufficient. It's more important that patching succeeds for all available use cases than for only some patching to succeed with faster performance. A UI option can be added later, but the multithreading option should be opt-out by default rather than opt-in. Closes ReVanced/revanced-documentation#35 Closes ReVanced#1454 Closes ReVanced#1571 Closes ReVanced#1595 Closes ReVanced#1659 Closes ReVanced#1661 Closes ReVanced#1684 Closes ReVanced#1759 Closes ReVanced#1802 Closes ReVanced#1817 Closes ReVanced/revanced-patches#2885 Closes ReVanced#592 Closes ReVanced/revanced-patcher#193 Closes ReVanced/revanced-patches#1533 Closes ReVanced/revanced-patches#1608 Closes ReVanced/revanced-patches#1613 Closes ReVanced/revanced-patches#1630 Closes ReVanced/revanced-patches#190 Closes ReVanced/revanced-patches#2511 Closes ReVanced/revanced-patches#525
Patching large applications (e.g. TikTok) on Android with multithreading simply doesn't work on multicore devices where the amount of memory given to the manager (regardless of the system RAM) is not sufficient. It's more important that patching succeeds for all available use cases than for only some patching to succeed with faster performance. A UI option can be added later, but the multithreading option should be opt-out by default rather than opt-in. Closes ReVanced/revanced-documentation#35 Closes ReVanced#1454 Closes ReVanced#1571 Closes ReVanced#1595 Closes ReVanced#1659 Closes ReVanced#1661 Closes ReVanced#1684 Closes ReVanced#1759 Closes ReVanced#1802 Closes ReVanced#1817 Closes ReVanced/revanced-patches#2885 Closes ReVanced#592 Closes ReVanced/revanced-patcher#193 Closes ReVanced/revanced-patches#1533 Closes ReVanced/revanced-patches#1608 Closes ReVanced/revanced-patches#1613 Closes ReVanced/revanced-patches#1630 Closes ReVanced/revanced-patches#190 Closes ReVanced/revanced-patches#2511 Closes ReVanced/revanced-patches#525
Type
Error while patching
Bug description
Getting this error while patching TikTok 30.7.2
Steps to reproduce
Just try to patch TikTok as any other app.
Relevant log output
Screenshots or videos
N/A
Solution
N/A
Additional context
No special context.
Invalidly closing the issue is not acceptable.
Acknowledgements
The text was updated successfully, but these errors were encountered: