vrchat-community / creator-companion

The Entry Point for Making Things in VRChat
https://vrchat.com/home/download
60 stars 424 forks source link

[BUG] Fresh install Memory Leak and unused variable in root SDK #457

Open POCI6996 opened 5 months ago

POCI6996 commented 5 months ago

Describe the bug

Ever since the most recent SDK update, I started getting these Warnings that would compound into Errors and abnormal behaviors such as an Abnormal Player Loop call reclusively by a specific SDK settings build target script that I will include below. The console always stated it was caused by a custom script but I suspected something else. So I uninstalled Unity Hub All the Editors, and Creator companion. Deleted the left over files in Program files and restarted my PC. Reinstalled creator companion, Unity Hub and then allowed Creator Companion to reinstall the Editor. I started a fresh project and these are the issues I ran into on build AbnormalError is the PlayerLoop Called Reclusively which manifested on all projects containing the assets that are currently not working properly. Unfortunately the base file is too big to upload so you will probably be working with properly serialized scripts and base. Unless you are going to have the initial memory leak you will not be able to duplicate this particular issue. it seems to be rooted in the VRCSdkControlPanelWorldBuilder.cs or at least that is where a lot of my errors are popping. I wish I could attach the entire project so you can be working with the serialization and build that I am but the files are too large and setting it up to test may be impossible without a lot of instruction. so I will explain what appears to be happening with as much detail as possible.

It's a singer queue list that has an int decoder for networking that is handled by the master. This abnormality only seems to affect things visually on the list but functions otherwise regardless of the display inaccuracies. They only start occurring if the master leaves and ownership of the list is transferred to the next master. From then on out nothing is updated correctly for late joiners and only display the names of anyone who joined the list prior to their arrival. The list continues to function normally. but the late joiner will just see the list of added individuals who joined the list after they were loaded in and deserialized. because the owner of the list handles the updates it still retains the accurate list but the display issue is causing the event guests some frustration in thinking they are not in the position they think they are in.

Like I stated before it was working just fine even when the master would lose connection before but now it's happened across all projects where this queue list exists if an update has been pushed. Sadly an update has been pushed for every instance it exists in so now me and my friend have been trying to troubleshoot this root issue for a week now. I've traced it back to an on build issue and no matter what I do to try and clear a completely fresh builds issues I have not yet succeeded. Please if anyone can I need to get this back to operational before Friday if possible. Thank you and hope there is an easy and simple fix for this seemingly unique issue.

AbnormalError FreshEmtyProjectError01 FreshEmtyProjectError02 FreshEmtyProjectError03-ObjectPool FreshEmtyProjectError04-ObjectPool FreshEmtyProjectError05-ObjectPool FreshEmtyProjectError06-KaraokeImport FreshEmtyProjectError07-KaraokeImport FreshEmtyProjectError08-BuildUpload-Android FreshEmtyProjectError09-BuildUpload-Windows

To Reproduce

build a fresh project (should produce memory leak) add custom package Simple Object Pool (should state Untiy has broken and resolver has fixed.) Add in singer Queue prefab that was too large to add to the project but even a clean build with nothing added should cause some odd errors.

Expected behavior

Even if the master gets disconnected the ownership should transfer and then the master updates the list. It states in the console that it is happening and have tried various methods to possibly get a work around even with more Networking heavy options. but for some reason late joiners can't seem to retrieve any data from before they joined. even if the master updates it. It's so weird.

Screenshots

FreshEmtyProjectError08-BuildUpload-Android FreshEmtyProjectError09-BuildUpload-Windows AbnormalError FreshEmtyProjectError01 FreshEmtyProjectError02 FreshEmtyProjectError03-ObjectPool FreshEmtyProjectError04-ObjectPool FreshEmtyProjectError05-ObjectPool FreshEmtyProjectError06-KaraokeImport FreshEmtyProjectError07-KaraokeImport

Related Product

VCC (VRChat Creator Companion)

Product Version

0.1.28

OS

Windows 11

Additional context

Affected both builds in VRChat.