ReVanced / revanced-patches

🧩 Patches for ReVanced
https://revanced.app
GNU General Public License v3.0
2.13k stars 245 forks source link

bug: General-ads fingerprint is broken #1683

Closed FineFindus closed 1 year ago

FineFindus commented 1 year ago

Type

Error while patching

Bug description

The general-ads patch fails since the fingerprint cannot be resolved.

Steps to reproduce

  1. Patch YouTube with general-ads included

Relevant log output

INFO: Reading dex files 
INFO: Decoding AndroidManifest.xml only, because resources are not needed 
INFO: Merging integrations.apk 
WARNING: Skipping unlock-pro, reason: incompatible with com.google.android.youtube. This patch is only compatible with co.windyapp.android 
WARNING: Skipping promo-code-unlock, reason: incompatible with com.google.android.youtube. This patch is only compatible with de.dwd.warnapp 
WARNING: Skipping monochrome-icon, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.twitter.android 
WARNING: Skipping dynamic-color, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.twitter.android 
WARNING: Skipping timeline-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.twitter.android 
WARNING: Skipping settings, reason: incompatible with com.google.android.youtube. This patch is only compatible with tv.twitch.android.app 
INFO: Skipping debug-mode, reason: excluded by default 
WARNING: Skipping show-deleted-messages, reason: incompatible with com.google.android.youtube. This patch is only compatible with tv.twitch.android.app 
WARNING: Skipping block-video-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with tv.twitch.android.app 
WARNING: Skipping block-audio-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with tv.twitch.android.app 
INFO: Skipping sim-spoof, reason: excluded by default 
WARNING: Skipping settings, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping fix-google-login, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping disable-login-requirement, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping playback-speed, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping show-seekbar, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping downloads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping feed-filter, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping hide-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ss.android.ugc.trill, com.zhiliaoapp.musically 
WARNING: Skipping unlock-themes, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.ticktick.task 
WARNING: Skipping hide-premium-navbar, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.spotify.music 
WARNING: Skipping spotify-theme, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.spotify.music 
WARNING: Skipping disable-capture-restriction, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.spotify.music 
WARNING: Skipping premium-icon-reddit, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.reddit.frontpage 
WARNING: Skipping general-reddit-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.reddit.frontpage 
WARNING: Skipping unlock-pro, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.awedea.nyx 
WARNING: Skipping unlock-pro, reason: incompatible with com.google.android.youtube. This patch is only compatible with org.totschnig.myexpenses 
WARNING: Skipping background-play, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping music-microg-support, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping upgrade-button-remover, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping tasteBuilder-remover, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping hide-get-premium, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping minimized-playback-music, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
INFO: Skipping compact-header, reason: excluded by default 
WARNING: Skipping custom-branding-music, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping exclusive-audio-playback, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping codecs-unlock, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping music-video-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.google.android.apps.youtube.music 
WARNING: Skipping unlock-pro, reason: incompatible with com.google.android.youtube. This patch is only compatible with ginlemon.iconpackstudio 
WARNING: Skipping disable-ads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.myprog.hexedit 
WARNING: Skipping pflotsh-ecmwf-subscription-unlock, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.garzotto.pflotsh.ecmwf_a 
WARNING: Skipping enable-downloads, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.crunchyroll.crunchyroid 
WARNING: Skipping premium-unlock, reason: incompatible with com.google.android.youtube. This patch is only compatible with org.citra.citra_emu 
WARNING: Skipping pro-unlock, reason: incompatible with com.google.android.youtube. This patch is only compatible with com.backdrops.wallpapers 
INFO: Deleting existing resource cache directory 
INFO: Decoding resources 
INFO: disable-zoom-haptics succeeded 
INFO: custom-video-buffer succeeded 
INFO: custom-video-speed succeeded 
INFO: remember-video-quality succeeded 
INFO: settings succeeded 
INFO: open-links-directly succeeded 
INFO: minimized-playback succeeded 
INFO: microg-support succeeded 
INFO: hdr-auto-brightness succeeded 
INFO: debugging succeeded 
INFO: client-spoof succeeded 
INFO: always-autorepeat succeeded 
INFO: enable-wide-searchbar succeeded 
INFO: hide-watermark succeeded 
INFO: hide-watch-in-vr succeeded 
INFO: theme succeeded 
INFO: tablet-mini-player succeeded 
INFO: disable-startup-shorts-player succeeded 
INFO: sponsorblock succeeded 
INFO: return-youtube-dislike succeeded 
INFO: disable-auto-player-popup-panels succeeded 
INFO: remove-player-button-background succeeded 
INFO: hide-shorts-button succeeded 
INFO: hide-create-button succeeded 
INFO: hide-email-address succeeded 
INFO: old-quality-layout succeeded 
INFO: hide-time-and-seekbar succeeded 
INFO: hide-my-mix succeeded 
INFO: hide-info-cards succeeded 
INFO: hide-endscreen-cards succeeded 
INFO: hide-crowdfunding-box succeeded 
INFO: hide-captions-button succeeded 
INFO: hide-artist-card succeeded 
INFO: hide-album-cards succeeded 
INFO: disable-fullscreen-panels succeeded 
INFO: comments succeeded 
INFO: hide-cast-button succeeded 
INFO: hide-video-buttons succeeded 
INFO: custom-branding succeeded 
INFO: premium-heading succeeded 
INFO: hide-autoplay-button succeeded 
INFO: disable-auto-captions succeeded 
INFO: swipe-controls succeeded 
INFO: seekbar-tapping succeeded 
INFO: downloads succeeded 
INFO: video-ads succeeded 
SEVERE: general-ads failed: 
app.revanced.patcher.patch.PatchResultError: Could not resolve fingerprint
    at app.revanced.patches.youtube.ad.general.bytecode.patch.GeneralAdsPatch.execute(GeneralAdsPatch.kt:75)
    at app.revanced.patches.youtube.ad.general.bytecode.patch.GeneralAdsPatch.execute(GeneralAdsPatch.kt:26)
    at app.revanced.patcher.Patcher.executePatches$executePatch(Patcher.kt:342)
    at app.revanced.patcher.Patcher.access$executePatches$executePatch(Patcher.kt:37)
    at app.revanced.patcher.Patcher$executePatches$1.invokeSuspend(Patcher.kt:362)
    at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:33)
    at kotlin.sequences.SequenceBuilderIterator.hasNext(SequenceBuilder.kt:127)
    at app.revanced.utils.patcher.PatcherKt.applyPatchesVerbose(Patcher.kt:92)
    at app.revanced.cli.patcher.Patcher.start$revanced_cli(Patcher.kt:27)
    at app.revanced.cli.command.MainCommand.run(MainCommand.kt:157)
    at picocli.CommandLine.executeUserObject(CommandLine.java:1939)
    at picocli.CommandLine.access$1300(CommandLine.java:145)
    at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2358)
    at picocli.CommandLine$RunLast.handle(CommandLine.java:2352)
    at picocli.CommandLine$RunLast.handle(CommandLine.java:2314)
    at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2179)
    at picocli.CommandLine$RunLast.execute(CommandLine.java:2316)
    at picocli.CommandLine.execute(CommandLine.java:2078)
    at app.revanced.cli.main.MainKt.main(Main.kt:7)
INFO: Compiling resources 
INFO: Writing modified dex files 
INFO: Writing dex file classes.dex 
INFO: Writing dex file classes2.dex 
INFO: Writing dex file classes3.dex 
INFO: Writing dex file classes4.dex 
INFO: Writing dex file classes5.dex 
INFO: Writing dex file classes8.dex 
INFO: Writing dex file classes7.dex 
INFO: Writing dex file classes6.dex 
INFO: Writing resources... 
INFO: Aligning output_raw.apk to output_aligned.apk 
INFO: Signing output_aligned.apk to output_signed.apk 
INFO: Found existing keystore: output.keystore 
INFO: Copying output_signed.apk to output.apk 
INFO: Cleaned up cache directory 
INFO: Finished

Screenshots or videos

No response

Solution

A possible workaround is to exclude the general-ads patch.

Additional context

Affects 17.41.37, 17.43.36 and 17.45.36

Acknowledgements

oSumAtrIX commented 1 year ago

Try with the CLI.

FineFindus commented 1 year ago

I did, I always use the CLI.

oSumAtrIX commented 1 year ago

The fingerprint isn't likely to break:

https://github.com/revanced/revanced-patches/blob/main/src/main/kotlin/app/revanced/patches/youtube/ad/general/bytecode/fingerprints/ReelConstructorFingerprint.kt

I am also not able to reproduce this issue. Please review if you are using the latest patches and CLI.

FineFindus commented 1 year ago

I was indeed not using the latest CLI. Thanks!