Page 1 of 1

StackOverflow Error, Unable to Build Project

Posted: Thu Feb 07, 2019 5:27 pm
by erik
Hello,

I've been using ES3 a while and building my game without problems and I'm not sure what changed, but now when trying to build my game I get a StackOverflow error spamming this:

10408: [Unity] ES3ReferenceMgr:GenerateReferences() (at Assets/Plugins/Easy Save 3/Scripts/ES3ReferenceMgr.cs:44)
10409: [Unity] ES3ReferenceMgr:OnBeforeSerialize() (at Assets/Plugins/Easy Save 3/Scripts/ES3ReferenceMgr.cs:17)
10410: [Unity] UnityEditor.EditorUtility:CollectDependencies()

This just happens over and over again until the build is auto-canceled.

This is using Unity Cloud Build but I'm not able to build on my PC either and I believe it's for the same reason.

This is the last line that appears in the "Compact Log"
256: [Unity] EXCEPTION: StackOverflowException: The requested operation caused a stack overflow.

Please advise :)

Erik

Re: StackOverflow Error, Unable to Build Project

Posted: Fri Feb 08, 2019 6:33 pm
by Joel
Hi there,

I have had another report of this issue and it appears to be a bug at Unity’s end regarding their GenerateReferences method. If you have a small project which replicates this, would you be able to send it to me so I have a bit more info to send to Unity?

In the meantime, you can fix the issue by disabling automatic reference updating. You can do this by going to Window > Easy Save 3 > Settings and uncheck Auto Update References.

Note that as this disables reference updating, if you are saving any reference types you may need to press the Refresh References button on the ES3ReferenceMgr component of the Easy Save 3 Manager in your scene to get Easy Save to recognise your references.

All the best,
Joel

Re: StackOverflow Error, Unable to Build Project

Posted: Sat Feb 09, 2019 5:49 am
by erik
Hi Joel,

Thanks for the quick response. I disabled Auto Update References and refreshed references, but the same error is still happening.

Unfortunately, I'm getting this error a commercial project so I'm unable to send anything that could help you out. I made a new project and tried to replicate it but wasn't able to.

Not sure how to proceed.

Re: StackOverflow Error, Unable to Build Project

Posted: Sat Feb 09, 2019 9:14 am
by Joel
Hi there,

We've made some changes to how reference generation works at our end. If you PM me your invoice number I'll send over the update to see if this makes a difference.

Also if the StackOverflow contains a stack trace, would you also be able to send me this?

All the best,
Joel

Re: StackOverflow Error, Unable to Build Project

Posted: Sun Feb 10, 2019 1:39 am
by erik
Okay so I've installed the new version and at least my build is not timing out anymore - now I'm getting an error:

Code: Select all

161: [Unity] -----CompilerOutput:-stdout--exitcode: 1--compilationhadfailure: True--outfile: Temp/Assembly-CSharp-firstpass.dll
162: [Unity] Assets/Plugins/Easy Save 3/Scripts/Settings/ES3Settings.cs(225,1): error CS1519: Invalid token '}' in class, struct, or interface member declaration
163: [Unity] ERROR: Assets/Plugins/Easy Save 3/Scripts/Settings/ES3Settings.cs(225,1): error CS1519: Invalid token '}' in class, struct, or interface member declaration
164: [Unity] Assets/Plugins/Easy Save 3/Scripts/Settings/ES3Settings.cs(225,1): error CS1519: Invalid token '}' in class, struct, or interface member declaration

Re: StackOverflow Error, Unable to Build Project

Posted: Sun Feb 10, 2019 10:44 am
by Joel
Hi there,

I've managed to find the problem and I will PM you an update right away.

All the best,
Joel

Re: StackOverflow Error, Unable to Build Project

Posted: Sun Feb 10, 2019 7:10 pm
by erik
Project is finally building again! Thanks so much for the help Joel.

Re: StackOverflow Error, Unable to Build Project

Posted: Wed May 01, 2019 4:09 pm
by gumbomasta
FYI:

Currently, if you put the Easy Save 3 Manager object (which contains the ES3 Reference MGR component) anywhere other than the root of the scene, it will cause a stack overflow and either crash when compiling a build or spit out errors in the console.

Is having the Manager object in the root an intentional design rule for implementing ES3?

Tested on:

2018.3.7f1 on Windows 10 64-bit with the most updated version of Easy Save (3.0.3).

Re: StackOverflow Error, Unable to Build Project

Posted: Wed May 01, 2019 4:38 pm
by Joel
Thanks for the heads-up. The Easy Save 3 Manager needs to be at the root level to ensure that it is discoverable and not serialised as part of another object.

I'll try to add an error message regarding this if it's detected that the Easy Save 3 Manager is not at the root level.

All the best,
Joel

Re: StackOverflow Error, Unable to Build Project

Posted: Wed May 01, 2019 6:01 pm
by gumbomasta
Thanks for clearing this up.