Fga: Service stops on friend support select screen when custom supports are preferred.

Created on 27 Jul 2020  路  12Comments  路  Source: Fate-Grand-Automata/FGA

I have been running FGA on my Bluestacks for a week or three now without issues. However, I recently downloaded the latest release (I updated from 1.15.0) and ran into a bug. Whenever I have a skill setup with one or more custom preferred servants or CEs set, the service will stop itself on the support select screen. Everything else works fine, even the custom image maker, or the support select screen when my preferred servant or CE is one of the built-in ones (as demonstrated in the video below). All of the fine tune settings are at their defaults (I even set the swipes and updates to their default values just in case).

If I try to enable the service again after the second crash, it tells me to enable accessibility (also demonstrated). Turning it off and on again fixes that.

I made a video to demonstrate the bug: https://streamable.com/habsqe
The custom support image was a new one I generated specifically for the test.

(After having typed this up I tried a full reinstall of the app, just in case. Didn't help)

Edited to change 'Friend select' to 'support select'.

bug

All 12 comments

Do a few things, please:

  1. Install https://androidmtk.com/download-minimal-adb-and-fastboot-tool
  2. Follow this guide https://stackoverflow.com/a/55804751/5971497
  3. After adb connect, run adb logcat *:E > C:\logcat.log
  4. Look at the log entries around the time the app crashes and see if you can find anything about an exception being thrown

The best I can find is an error:

07-27 02:03:51.788 4355 4435 E cv::error(): OpenCV(4.4.0) Error: Unspecified error (> Invalid number of channels in input image:
07-27 02:03:51.788 4355 4435 E cv::error(): > 'VScn::contains(scn)'
07-27 02:03:51.788 4355 4435 E cv::error(): > where
07-27 02:03:51.788 4355 4435 E cv::error(): > 'scn' is 1
07-27 02:03:51.788 4355 4435 E cv::error(): ) in cv::impl::(anonymous namespace)::CvtHelper, cv::impl::(anonymous namespace)::Set<1, -1, -1>, cv::impl::(anonymous namespace)::Set<0, 2, 5>, cv::impl::(anonymous namespace)::NONE>::CvtHelper(cv::InputArray, cv::OutputArray, int) [VScn = cv::impl::(anonymous namespace)::Set<3, 4, -1>, VDcn = cv::impl::(anonymous namespace)::Set<1, -1, -1>, VDepth = cv::impl::(anonymous namespace)::Set<0, 2, 5>, sizePolicy = cv::impl::(anonymous namespace)::NONE], file /build/master_pack-android/opencv/modules/imgproc/src/color.simd_helpers.hpp, line 92

Followed by this exception

No pending exception expected: java.lang.ClassNotFoundException: Didn't find class "org.opencv.core.CvException" on path: DexPathList[[zip file "/data/app/com.mathewsachin.fategrandautomata-2/base.apk"],nativeLibraryDirectories=[/data/app/com.mathewsachin.fategrandautomata-2/lib/arm, /data/app/com.mathewsachin.fategrandautomata-2/base.apk!/lib/armeabi-v7a, /system/lib, /vendor/lib, /data/downloads, /data/priv-downloads]]

The same exception is thrown again later just before it seems the whole process gets terminated.

I'll include the log itself as well, since I'm not sure what exactly I'm looking for.
logcat.log

@MathewSachin is this maybe related to the cvtColor method here? https://github.com/MathewSachin/Fate-Grand-Automata/commit/a704a511bab68b74eab08258ed4632fc6ba5b621#diff-9d6bcbd675a451c34373f6eb042c8f98R34

My guess is that matching greyscale templates doesn't work anymore.

I understood the problem from the logs. Just saw this in the middle of the night. I'll push a fix when I wake up tomorrow.

The problem should have appeared with the Story Skip fix where I kind of assumed that the loaded image will be RGBA, while images made by support image maker are gray-scale. And since I didn't use custom support images this event, I didn't notice this.

Lol, that timing.

Yeah. If you're up, can you push a fix. Just have to add an if around that line checking that number of channels is not 1.

Lying in bed trying to fall asleep

I'll wake up in 4-5 hrs and push the fix then. Lol

The thing about CvException missing in the apk seems suspicious too.

Seems like this is needed for the exception: https://developer.android.com/studio/build/multidex#keep

Yeah, I knew that a proguard keep rule would solve the CVException missing problem, but was so sleepy that didn't feel like typing it.

I've released a fix. Try v0.17.0.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

rafflesiazero picture rafflesiazero  路  8Comments

itscakebuffet picture itscakebuffet  路  8Comments

sleeping-player picture sleeping-player  路  4Comments

sleeping-player picture sleeping-player  路  5Comments

thai-ng picture thai-ng  路  5Comments