UnityFramework load in 2019.3.11 causes Watchdog Transgression crash (0x8badf00d)

I’m sitting here refreshing the LTS page hoping to get 2019.4.17f1 available for download…This is not fun when Apple is closing shop in a few days…

This workaround will cause another problem…It will show a crash tip box when you clear your app in the background.

1 Like

So this issue has now been marked as “Wont Fix”, it previously said “Fixed in 2019.4” (but didn’t specify version). Can we get an official response regarding this? It has also been removed from “Known Issues” in 2019.4.18f1 but hasn’t been specified as fixed, what the hell?

2 Likes

@Maisey were you able to resolve the issue ? We got the builds working using the workaround. They work on Testflight but then when it goes to the Apple review process, they get a crash on launch and we get rejected. We haven’t been able to repro the issue on any device on Testflight…

Hey @artour

I was able to repro* it locally when not using the workaround (got the crash-log showing that it was indeed this bug). Using the workaround seems to eliminate the crash (at least according to our testing).
We did however in correlation with this bug have a bug with Unity Splash Screen causing freeze/extreme loading times which caused Apple to reject us a number of times. We removed Unity Splash Screen and had our own “empty” scene as a loading screen. It’s a longshot that this would work for you, but if you’re desperate…try it out, you might get lucky.

  • randomly make it occur

(It may also differ depending on what dependencies you use, in our project we had Firebase, Facebook and quite a lot of Ad SDKs)

Did you report this as a bug or do you have a link to the thread about this issue (if thread or bug report already exists)?

I made a post in this thread (my issue was slightly off topic). I did not make an official bug report because I didn’t (and still don’t) have the time to make a proper report and it’s especially demotivating when they don’t even fix the ones we do report.
Good luck Unity with the mentality of “Won’t Fix”…in a LTS-version. An official response detailing why this would be fixed in 2020 and not 2019 is too much to ask?

Just to update the thread in case others face this issue, we have now passed review. There are a few changes that we made so I’m not 100% which of them fixed it:

  1. Removed Unity VFX Graph. We didn’t use it in the project but apparently just having it in the project may cause problems.

  2. We turned off the splash screen as Maisey suggested

  3. We kept the workaround suggested here:
    Unity Issue Tracker - [iOS][UaaL] UnityFramework with 3rd party plugins triggers watchdog termination after launch

  4. Upgraded to Unity 2020.2. Note this introduces other workarounds that we had to do, specifically as noted here:
    2019.3 - validation on upload to store gives "UnityFramework.framework contains disallowed file"

Thanks everyone for all the help with this.

2 Likes

Is there a way to automize the workaround? I found PBXProject API confusing

@Martin_Gonzalez , I’m not sure what else you’re after when it comes to “automize”. Adding this script (taken from comments from issue-report) is basically automizing it (I haven’t confirmed it myself):

using System.IO;
using UnityEngine;
using UnityEditor;
using UnityEditor.Build;
using UnityEditor.Build.Reporting;
using UnityEditor.iOS.Xcode;

public class iOS_14_2_Workaround : IPostprocessBuildWithReport
{
    public int callbackOrder => 1;

    public void OnPostprocessBuild(BuildReport report)
    {
        #if UNITY_IOS
        if( report.summary.platform == BuildTarget.iOS )
        {
            Debug.Log("Applying iOS 14.2 workaround. Remove me once Unity has patched this.");
            var pathToBuiltProject = report.summary.outputPath;
            var projectPath = PBXProject.GetPBXProjectPath(pathToBuiltProject);
            var project = new PBXProject();
            project.ReadFromString(File.ReadAllText(projectPath));
            project.AddFrameworkToProject( project.GetUnityMainTargetGuid(), "UnityFramework.framework", false );
            project.WriteToFile( projectPath );
        }
        #endif
    }
}
2 Likes

Thanks! I saw it later :confused:
I would like to know more if it’s a Unity issue or Plugins issue that we need to be aware of, perhaps someone from Unity explaining a little bit (I know what is the issue but I would like to see if Unity has some action points or plugins should be aware of this)

Unity announced a change in mid-2019, forum post 1, forum post 2 , but as it looks they didn’t think about all the Plugins/SDKs and what a mess will it cause. As announced, change was introduced in Unity 2019.3.0 on 27.01.2020.

Now, you would expect a huge announcement specially made for Plugin/SDK providers so they could adjust to this but that never happened. Even a whole year later there is no public statement that would notify all Plugin/SDKs providers to make changes so this error would go away. Not even a single official response on this breaking issue on this forum, very disappointing, like it is thrown under the rug. Plugins that still didn’t adjust to this change (many still don’t know about this) will crash the app if you are not using a workaround, but a workaround by some reports above causes another crash.

Probably we users (in fact beta testers, QA) should notify Plugin/SDK providers, as we also need to find and report breaking bugs that are dragged from version to version over several months until we report them. Unity has catastrophic QA, I’m pretty sure that many things are thrown under the rug until someone makes a detailed bug report.

Correct me if any of my statements are wrong.

1 Like

I agree with you that Unity devs that are responsible for this change ( known as UaaL, or Unity as a Library, introduced in 2019.3 ) didn’t understood how critical are the side effects they introduced.
Even if they argue that the deadlocks are half made by 3rd party plugins code, those are side effects of a change they made, and in those dead locks they might play the other half locking the same resource.

But I would disagree about the QA, I think the job done by QA is well done, considering the huge amount of work it is. I have produced 100+ bug reports and almost each of them have been taken and tested seriously. It is just that sometimes, the decisions that result are not meeting our expectation, but it is another concern.

1 Like

Just want to update to let people know that Unity has now marked it as “Won’t Fix” for all Unity versions (previously it said it was fixed in Unity 2020). The mystery continues. :eyes:

I am confused why the generated Xcode project from Unity doesn’t automatically have the framework link setup to avoid this issue?

Have been working on an IOS project for a while now and we only just noticed this when we went to use Testflight, sometimes I would notice a long hang on app load in Xcode builds but it was only when the build was pushed to Testflight, IOS would flag a crash error.

For our users/the client, this meant that they would install through testflight then the app would be killed in the background when they weren’t using it, when re-opening the app, they would see a popup that the app has crashed, this would also happen if the app was ran once, closed, then opened again.

I would like to see a proper fix from Unity as this is a mess

In 2020.3.25 if I use this code I get a linker error

If I remove this class, then I get the watchdog transgression on launch. Firebase isn’t in the project.

1 Like

Hello,

I’m experiencing the same issue and even with the workaround it still persists. What’s going on is not really cristal clear to me. I wanted to know if us, as developer, can do something to delay SDK initializations ? Meaning, simply added an intermediate empty scene to ensure no SDK API calls is done would/could be enough or if those SDK already perfoms some operations in their hand which we can’t control ?

Thanks

I have this issue in 2020.3.18f1 (LTS) and I don’t have firebase. I have facebook and gameanlaytics.
Here is the related part of crash log

xception Type:  EXC_CRASH (SIGKILL)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note:  EXC_CORPSE_NOTIFY
Triggered by Thread:  0


Kernel Triage:
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get
VM - Compressor failed a blocking pager_get


Thread 0 name:
Thread 0 Crashed:
0   libsystem_kernel.dylib            0x00000001b8863f90 __psynch_cvwait + 8
1   libsystem_pthread.dylib           0x00000001f24a6254 _pthread_cond_wait + 1228 (pthread_cond.c:636)
2   UnityFramework                    0x000000010a2bd7cc il2cpp::os::posix::PosixWaitObject::Wait(unsigned int, bool) + 404 (PosixWaitObject.cpp:119)
3   UnityFramework                    0x000000010a2b5190 il2cpp::os::Event::Wait(unsigned int, bool) + 16 (Event.cpp:46)
4   UnityFramework                    0x000000010a2b5190 il2cpp::os::Thread::Join(unsigned int) + 16 (Thread.cpp:219)
5   UnityFramework                    0x000000010a2b5190 il2cpp::os::Thread::Join() + 24 (Thread.cpp:213)
6   UnityFramework                    0x000000010a2db028 il2cpp::vm::Thread::KillAllBackgroundThreadsAndWaitForForegroundThreads() + 620 (Thread.cpp:329)
7   UnityFramework                    0x000000010a2e81a8 il2cpp::vm::Runtime::Shutdown() + 140 (Runtime.cpp:405)
8   UnityFramework                    0x0000000109b9ab60 CleanupIl2Cpp() + 20 (MonoManager_Il2Cpp.cpp:297)
9   UnityFramework                    0x0000000109ab1740 PlayerCleanup(bool) + 84 (Player.cpp:646)
10  UnityFramework                    0x0000000109e7ce74 UnityCleanup + 16 (LibEntryPoint.mm:213)
11  UnityFramework                    0x00000001095b2a20 -[UnityAppController applicationWillTerminate:] + 36 (UnityAppController.mm:490)
12  UIKitCore                         0x000000018452f61c -[UIApplication _terminateWithStatus:] + 244 (UIApplication.m:6917)

and crash rate is getting serious. FYI, your appstore ranking won’t be good if you see high crash rate although it doesn’t affect users.
7884820--1003243--upload_2022-2-10_10-32-10.png

Update, fixed in the unity LTS 2021

it worked then sudently it stopped working ,weird…