revanced-manager icon indicating copy to clipboard operation
revanced-manager copied to clipboard

bug: Manager sometimes immediately cancels installation and Export APK button stops working

Open KobeW50 opened this issue 1 year ago • 16 comments

Bug description

Sometimes when trying to install a patched app, the Manager will immediately cancel the installation. The Export APK button will also not work. The issue only occurs when the Save patched app toggle in the Manager settings is enabled.

It is difficult to reproduce this bug. Below is the simplest and most consistent method I found.

Steps to reproduce

  1. Prepare the replication environment by uninstalling YouTube ReVanced and clearing the ReVanced Manager data
  2. Open the Manager settings and enable the Allow changing patch selection option
  3. Select the suggested YouTube APK from storage
  4. Patch and install YouTube with only the GmsCore support patch applied (the bug should not occur at this point)
  5. Without closing the Manager, return to the Patcher screen and repeat step 3 and 4

The bug should occur when repeating step 4 for the second time. (You may need to try again)

Demonstration:

https://github.com/user-attachments/assets/5a5ca50d-dd6f-42f1-9236-34bacc239999

Version of ReVanced Manager and version & name of app you are patching

1.22.0 YouTube

Installation method

Regular

ReVanced Manager logs

revanced-manager_logcat_20240923114749497367.log.txt

Patch logs

- Device Info
ReVanced Manager: 1.22.0
Model: SM-S906U1
Android version: 14
Supported architectures: arm64-v8a, armeabi-v7a, armeabi
Root permissions: No

- Patch Info
App: com.google.android.youtube v19.16.39 (Suggested: 19.16.39)
Patches version: v4.15.0
Patches added: Default
Patches removed: Hide ads, Video ads, Copy video URL, Remove viewer discretion dialog, Downloads, Disable precise seeking gesture, Seekbar tapping, Swipe controls, Disable auto captions, Hide video action buttons, Hide autoplay button, Hide captions button, Hide cast button, Navigation buttons, Hide player buttons, Hide album cards, Comments, Hide crowdfunding box, Hide endscreen cards, Hide filter bar, Hide floating microphone button, Disable fullscreen ambient mode, Hide layout components, Hide info cards, Player flyout menu, Disable rolling number animations, Hide seekbar, Hide Shorts components, Disable suggested video end screen, Hide timestamp, Miniplayer, Disable player popup panels, Custom player overlay opacity, Return YouTube Dislike, Wide searchbar, Restore old seekbar thumbnails, SponsorBlock, Spoof app version, Change start page, Disable resuming Shorts on startup, Enable tablet layout, Theme, Alternative thumbnails, Bypass image region restrictions, Announcements, Always repeat, Remove background playback restrictions, Enable debugging, Spoof device dimensions, Check watch history domain name resolution, Spoof video streams, Bypass URL redirects, Remove tracking query parameter, Disable zoom haptics, Remember video quality, Playback speed, Restore old video quality menu, Open links externally
Default patch options changed: None

- Settings
Allow changing patch selection: true
Version compatibility check: true
Show universal patches: false
Patches source: revanced/revanced-patches
Integration source: revanced/revanced-integrations

- Logs
Reading APK
Decoding app manifest
Loading patches
Merging integrations
Deleting existing temporary files directory
Decoding resources
Executing patches
Applied 2 patches
Compiling patched dex files
Compiled 8 dex files
Compiling modified resources
Aligning APK
Signing APK
Patched APK
Installing patched app
Installation canceled

Acknowledgements

  • [X] I have checked all open and closed bug reports and this is not a duplicate.
  • [X] I have chosen an appropriate title.
  • [X] All requested information has been provided properly.
  • [X] The bug is only related to ReVanced Manager.

KobeW50 avatar Sep 23 '24 16:09 KobeW50

I also used logcat to record logs of the entire device. LMK if that is needed (and what to grep for)

KobeW50 avatar Sep 23 '24 16:09 KobeW50

The logs only mention a NPE, which is caused by this issue. No more relevant logs apart from that.

oSumAtrIX avatar Sep 23 '24 18:09 oSumAtrIX

Disable Play Protect and see if you can reproduce.

oSumAtrIX avatar Sep 23 '24 18:09 oSumAtrIX

Disable Play Protect and see if you can reproduce.

The issue still occurs.

SmartSelect_20240923_142012_Google Play Store

revanced-manager_logcat_20240923142020502224.log.txt

KobeW50 avatar Sep 23 '24 18:09 KobeW50

After some more testing, I was unable to reproduce the issue when the Save patched app toggle in the Manager settings is disabled.

(Also, I was able to reproduce the issue with the Reddit app, even without changing it's package name.)

KobeW50 avatar Sep 23 '24 21:09 KobeW50

Enable Play Protect again and reproduce it.

oSumAtrIX avatar Sep 24 '24 16:09 oSumAtrIX

Enable Play Protect again and reproduce it.

The issue continues to occur (tested with YouTube, with the Save patched app toggle enabled)

revanced-manager_logcat_20240924195347171913.log.txt

KobeW50 avatar Sep 24 '24 23:09 KobeW50

So it is related to Play Protect somehow getting rid of the file. What if you disable save patched app.

oSumAtrIX avatar Sep 25 '24 00:09 oSumAtrIX

What if you disable save patched app.

The issue doesn't occur (tested with play protect enabled). revanced-manager_logcat_20240924203015351253.log.txt

https://github.com/user-attachments/assets/419c4355-85cb-4b1b-a567-12b5bcaf2b5b

KobeW50 avatar Sep 25 '24 00:09 KobeW50

@BenjaminHalko maybe you know about this, since it's related to saving the last patched app

oSumAtrIX avatar Sep 25 '24 00:09 oSumAtrIX

I can try to take a look at it tmr

BenjaminHalko avatar Sep 25 '24 00:09 BenjaminHalko

Second definitely trying teach thinking can get used techno 5f card/

Bighead9971 avatar Oct 17 '24 14:10 Bighead9971

I experienced this issue today. It would immediately cancel after clicking Install, and the save button did nothing.

When I repeated the patching process, it worked the second time.

The only noticable difference was on the second attempt I didn't get the modal that gives the summary of which patches were removed and new.

ghost avatar Nov 11 '24 22:11 ghost

It happened with me as well. Export button fails to work and the log says Installation cancelled. However, it worked the second time.

ngudbhav avatar Nov 12 '24 04:11 ngudbhav

But I didn't had any issue while the process for the first time, it worked fine for me. BTW I'm using the latest versions. Patch version: 5.0.1 Version: 1.23.1 Model: SM-A305F Android Version: 11 Supported Archs: arm64-v8a, armeabi-v7a, armeabi

BabyOilJohnson avatar Nov 12 '24 06:11 BabyOilJohnson

Yup. Me too. Using the latest version on Galaxy S23, Android 14, October Security patch, Play Protect enabled. Both the patches and the manager are on the latest version. This looks flaky.

One more observation, I saw that some logs got missed when the issue occurred. It looks like the same observation is valid in the video posted by OP.

ngudbhav avatar Nov 12 '24 07:11 ngudbhav