Skip to content
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: Youtube settings patch failed to resolve ThemeSetterAppFingerprint #2476

Closed
3 tasks done
mikk150 opened this issue Dec 21, 2022 · 25 comments
Closed
3 tasks done
Labels
Bug report Something isn't working

Comments

@mikk150
Copy link

mikk150 commented Dec 21, 2022

Type

Error while patching

Bug description

Patching youtube with patches that depend on patch settings fails with Failed to resolve ThemeSetterAppFingerprint

Steps to reproduce

  1. Download Youtube v17.49.37
  2. Select APK to patch via patcher
  3. Select General Adds
  4. Press Patch

Relevant log output

Failed to apply general-ads: 'general-ads' depends on 'GeneralAdsResourcePatch' but the following error was raised: 'GeneralAdsResourcePatch' depends on 'settings' but the following error was raised: Failed to resolve ThemeSetterAppFingerprint
Failed to apply minimized-playback: 'minimized-playback' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
Failed to apply settings: 'settings' did not succeed previously
Failed to apply video-ads: 'video-ads' depends on 'settings' but the following error was raised: 'settings' did not succeed previously

Screenshots or videos

No response

Solution

No response

Additional context

No response

Acknowledgements

  • I have searched the existing issues and this is a new and no duplicate or related to another open issue.
  • I have written a short but informative title.
  • I filled out all of the requested information in this issue properly.
@mikk150 mikk150 added the Bug report Something isn't working label Dec 21, 2022
@bigyihsuan
Copy link

bigyihsuan commented Dec 22, 2022

I can confirm I'm getting this as well. It seems quite a few patches depend on this missing settings patch.

What's stranger is that it exists in the patches.json file (as of 2.147.0), but Vanced Manager is not recognizing it.

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
Deleting existing resource cache directory
Decoding resources
Applied custom-branding
Failed to apply general-ads: 'general-ads' depends on 'GeneralAdsResourcePatch' but the following error was raised: 'GeneralAdsResourcePatch' depends on 'settings' but the following error was raised: Failed to resolve ThemeSetterAppFingerprint
Failed to apply hdr-auto-brightness: 'hdr-auto-brightness' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
Applied premium-heading
Failed to apply return-youtube-dislike: 'return-youtube-dislike' depends on 'return-youtube-dislike-resource-patch' but the following error was raised: 'return-youtube-dislike-resource-patch' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
Failed to apply settings: 'settings' did not succeed previously
Failed to apply sponsorblock: 'sponsorblock' depends on 'sponsorblock-resource-patch' but the following error was raised: 'sponsorblock-resource-patch' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
Failed to apply swipe-controls: 'swipe-controls' depends on 'swipe-controls-resource-patch' but the following error was raised: 'swipe-controls-resource-patch' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
Applied theme
Failed to apply video-ads: 'video-ads' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
Repacking patched apk
Compiling resources
Writing modified dex files
Finished!

@oSumAtrIX
Copy link
Member

oSumAtrIX commented Dec 22, 2022

It doesn't exist in the json.

@bigyihsuan
Copy link

Workaround found: uninstall and reinstall Revanced Manager, and try patching again. The only problem is that the settings doesn't show in the patches list.

@mikk150
Copy link
Author

mikk150 commented Dec 22, 2022

So, new behaviors, if I give root access to Revanced Manager, it fails to patch, if I do not, then it succeeds, but cannot install(For obvious reasons)

@FahimAnayet
Copy link

So, new behaviors, if I give root access to Revanced Manager, it fails to patch, if I do not, then it succeeds, but cannot install(For obvious reasons)

This actually helps. But I got a walkarownd to install as root. First revoke root access of ReVanced then select the patches and start patching. And after finishing patch before install enable root access and than install. Works like a charm

@oSumAtrIX
Copy link
Member

The patching process happens regardless of root. Reason why you can also patch on other devices with the CLI instead of directly on your phone.

@cpc2
Copy link

cpc2 commented Jan 5, 2023

The patching process happens regardless of root. Reason why you can also patch on other devices with the CLI instead of directly on your phone.

It should be like this but I can confirm revoking root access makes it so the patching succeeds. I tested it several times and it's definitely that.

Edit: though I still can't manage to install it successfully afterwards.

@oSumAtrIX
Copy link
Member

That would be weird because the patching process has nothing to do with root or not. Root is first used when installing/mounting.

@exzhawk
Copy link

exzhawk commented Jan 6, 2023

The patching process happens regardless of root. Reason why you can also patch on other devices with the CLI instead of directly on your phone.

It should be like this but I can confirm revoking root access makes it so the patching succeeds. I tested it several times and it's definitely that.

Edit: though I still can't manage to install it successfully afterwards.

I'm use microg patch(no need for root, but I gave revanced manager root access), and facing the same problem. Just use the workaround mikk150 and FahimAnayet mentioned above: revoke root access to make a successful patch. Though the revanced manager can not install the APK file, there is an option on the left top menu to allow the patched APK to be exported. Then I just opened a file manager to install the patched APK file. might be helpful for root patches.

@universebreaker
Copy link

universebreaker commented Feb 23, 2023

I have the same error when using revanced-cli for patching
already using latest release of cli, patches and integrations, and the error still exist
the error only occurs when patching apk of 18.06.XX (18.06.35, 18.06.39, 18.06.41 tested at the time of writing)
and doesn't happen when patching older versions
(no youtube beta version tested)

Steps to reproduce
java.exe -jar revanced-cli-2.20.0-all.jar -c -a youtube_18.06.41.apk -b revanced-patches-2.163.0.jar -m revanced-integrations-0.98.0.apk --experimental -o revanced-18.06.41.apk

Relevant log output

app.revanced.patcher.patch.PatchResultError: 'comments' depends on 'comments-resource-patch' but the following error was raised: 'comments-resource-patch' depends on 'settings' but the following error was raised: Failed to resolve ThemeSetterAppFingerprint
        at app.revanced.patcher.Patcher.executePatches$executePatch(Patcher.kt:311)
        at app.revanced.patcher.Patcher.access$executePatches$executePatch(Patcher.kt:37)
        at app.revanced.patcher.Patcher$executePatches$1.invokeSuspend(Patcher.kt:355)
        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:83)
        at app.revanced.cli.patcher.Patcher.start$revanced_cli(Patcher.kt:20)
        at app.revanced.cli.command.MainCommand.run(MainCommand.kt:152)
        at picocli.CommandLine.executeUserObject(CommandLine.java:2026)
        at picocli.CommandLine.access$1500(CommandLine.java:148)
        at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2461)
        at picocli.CommandLine$RunLast.handle(CommandLine.java:2453)
        at picocli.CommandLine$RunLast.handle(CommandLine.java:2415)
        at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2273)
        at picocli.CommandLine$RunLast.execute(CommandLine.java:2417)
        at picocli.CommandLine.execute(CommandLine.java:2170)
        at app.revanced.cli.main.MainKt.main(Main.kt:7)
嚴重: copy-video-url failed:
app.revanced.patcher.patch.PatchResultError: 'copy-video-url' depends on 'copy-video-url-resource' but the following error was raised: 'copy-video-url-resource' depends on 'settings' but the following error was raised: 'settings' did not succeed previously
        at app.revanced.patcher.Patcher.executePatches$executePatch(Patcher.kt:311)
        at app.revanced.patcher.Patcher.access$executePatches$executePatch(Patcher.kt:37)
        at app.revanced.patcher.Patcher$executePatches$1.invokeSuspend(Patcher.kt:355)
        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:83)
        at app.revanced.cli.patcher.Patcher.start$revanced_cli(Patcher.kt:20)
        at app.revanced.cli.command.MainCommand.run(MainCommand.kt:152)
        at picocli.CommandLine.executeUserObject(CommandLine.java:2026)
        at picocli.CommandLine.access$1500(CommandLine.java:148)
        at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2461)
        at picocli.CommandLine$RunLast.handle(CommandLine.java:2453)
        at picocli.CommandLine$RunLast.handle(CommandLine.java:2415)
        at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:2273)
        at picocli.CommandLine$RunLast.execute(CommandLine.java:2417)
        at picocli.CommandLine.execute(CommandLine.java:2170)
        at app.revanced.cli.main.MainKt.main(Main.kt:7)

@oSumAtrIX oSumAtrIX added the Waiting on author Further information is requested label Feb 27, 2023
@oSumAtrIX
Copy link
Member

oSumAtrIX commented Feb 27, 2023

These are not compatible versions by the patches, check the compatible versions.

@vinceingithub
Copy link

Is there any fix for this?

@oSumAtrIX
Copy link
Member

Patch compatible versions

@Martinligabue

This comment was marked as spam.

@LisoUseInAIKyrios
Copy link
Contributor

LisoUseInAIKyrios commented Mar 20, 2023

Patch compatible versions

I have the exact same error with both compatible and incompatible versions.

Using a non compatible version is unknown territory, and the expected outcome is failure.

For patching a compatible app version, try:

  • Uninstall ReVanced Manager
  • Uninstall ReVanced YouTube
  • Reinstall latest Manager
  • Patch using recommended patches

@Martinligabue
Copy link

Patch compatible versions

I have the exact same error with both compatible and incompatible versions.

Using a non compatible version is unknown territory, and the expected outcome is failure.

For patching a compatible app version, try:

  • Uninstall ReVanced Manager
  • Uninstall ReVanced YouTube
  • Reinstall latest Manager
  • Patch using recommended patches

I did that, even just applying the microg patch only with youtube at correct version and revanced stock gives the same error.
As everyone has said, that's not the problem, it's root, using root gives the error, denying root solves it.
I did that, even just applying the microg patch only with youtube at correct version and revanced stock gives the same error.
As everyone has said, that's not the problem, it's root, using root gives the error, denying root solves it.
Without root, even the incompatible versions are installed correctly with no problem, so until a fix is made to address the root issue, there is no other way but to manually deny root.
It won't be solved by "patching compatible version".
I hope that was clear enough.

@oSumAtrIX
Copy link
Member

If that is really the case it's very weird. Root or not is first required at installing the app. At no time root is required for patching applications.

@Martinligabue
Copy link

If that is really the case it's very weird. Root or not is first required at installing the app. At no time root is required for patching applications.

should we move the issue to the app repo?

@oSumAtrIX
Copy link
Member

Dunno, it kinda belongs to both.

@SeasonPhan
Copy link

SeasonPhan commented Mar 23, 2023

i can confirm this problem exist on lastest 0.0.57 with patch 2.166.0
revoking root access fixes the problem (no need for reinstalling, clearing Manager data/cache , just purely revoking root access from magisk and restart Manager)

edit: im running android 13

@rbyrnedugan
Copy link

I was facing this issue today (non-rooted Pixel 7 Pro on Android 13) when trying to patch the 18.05.40 version of YouTube. After upgrading my stock YouTube app from 17.x to 18.05.40, the issue went away and patching worked properly.

@Martinligabue

This comment was marked as spam.

@VDavid003

This comment was marked as spam.

@hollowstrawberry

This comment was marked as spam.

@ReVanced ReVanced locked as spam and limited conversation to collaborators May 17, 2023
@oSumAtrIX
Copy link
Member

If this is still a problem, please open a new issue.

@oSumAtrIX oSumAtrIX closed this as not planned Won't fix, can't repro, duplicate, stale Oct 1, 2023
@oSumAtrIX oSumAtrIX reopened this Dec 16, 2023
@ReVanced ReVanced unlocked this conversation Dec 16, 2023
@oSumAtrIX oSumAtrIX transferred this issue from ReVanced/revanced-patches-template Dec 16, 2023
@ReVanced ReVanced locked and limited conversation to collaborators Dec 16, 2023
@LisoUseInAIKyrios LisoUseInAIKyrios removed the Waiting on author Further information is requested label Dec 27, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug report Something isn't working
Projects
None yet
Development

No branches or pull requests