# FMOD Studio 2.01.07 Profiler Connects to Unity, but Events Aren't Recorded

**URL:** https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078
**Category:** FMOD Studio
**Created:** [April 20, 2021, 7:10pm UTC](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078 "2021-04-20T19:10:49Z")
**Posts on this page:** 5
**Page:** 2

<div class="post-metadata">

### Author: ![okaybenji](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/okaybenji/32/1346_2.png) [@okaybenji](https://qa.fmod.com/u/okaybenji)
#### Post date: [June 15, 2021, 10:46pm UTC](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078/21 "2021-06-15T22:46:50Z")

</div>

I have verified that the issue has nothing to do with the .gitattributes or .gitignore. I created a new branch, removed all FMOD-related items from each, committed, branched off this, removed FMOD, reinstalled it (with several failures as described before, and having to repreat the process multiple times), and got Live Update working again.

It’s also not failing upon switching branches as I had thought before, at least not immediately. While Unity and FMOD Studio were running, I merged the second branch into the first, and Live Update continued to function fine. It didn’t fail until I closed and reopened Unity. Here’s a full account of events:

1. Created a new branch `fmod-fix-a`, removed all FMOD references from .gitignore and .gitattributes, and committed.
2. Branched `fmod-fix-b` off this, removed FMOD, committed, reinstalled FMOD (this took several tries before FMOD’s Wizard actually worked/wasn’t broken) and got Live Update working again.
3. Merged the new branch `fmod-fix-b` into `fmod-fix-a`. _At this point, the FMOD Studio Project was no longer linked for some reason._
4. Relinked the FMOD Studio Project. Live Update automatically reconnected to the game and resumed working.
5. Exited Play Mode and started it up again. Live Update still worked.
6. Exited Play Mode, disconnected FMOD Studio from Live Update (Stop Reconnecting). Attempted to connect again and saw error in FMOD Studio titled “Error Connecting to Game”. ‘Studio was unable to connect to “127.0.0.1:9264” as a connection error occurred: Socket Error. Please check that the IP address is correct, the game is running and live update is enabled.’ I selected the “Retry in background” option, then entered Play Mode again. Live Update resumed working. So far, everything seems to be working as expected.
7. Closed and reopened Unity. Entered Play Mode again. This is where it broke. FMOD Studio showed “Live Update On” in green, but I was no longer getting any levels from the mixer. The Wizard still reported that the FMOD Project was linked. `[FMOD] FMOD_OS_Net_Listen : Cannot listen for connections, port 9264 is currently in use.` logged (but only once this time.)
8. Told FMOD Studio to disconnect from the game, then reconnected. “Live Update On” came back, but Live Update was still not working.

---

<div class="post-metadata">

### Author: ![okaybenji](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/okaybenji/32/1346_2.png) [@okaybenji](https://qa.fmod.com/u/okaybenji)
#### Post date: [June 22, 2021, 1:19am UTC](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078/22 "2021-06-22T01:19:53Z")

</div>

After more testing, simply restarting Unity on macOS breaks Live Update. git has nothing to do with it.

Any ideas about how to fix this?

---

<div class="post-metadata">

### Author: ![joseph](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/joseph/32/264_2.png) [@joseph](https://qa.fmod.com/u/joseph)
#### Post date: [July 20, 2021, 1:27am UTC](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078/23 "2021-07-20T01:27:17Z")

</div>

Despite testing, I still haven’t been able to reproduce this issue: Restarting Unity has no effect on FMOD Studio’s ability to connect via live update and profile the output of Unity Play In Editor.

All I can think of is that there must be some feature of your Unity project that is not present in my test cases. Are you able to upload a Unity project that exhibits this issue to the uploads tab of your profile page?

---

<div class="post-metadata">

### Author: ![okaybenji](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/okaybenji/32/1346_2.png) [@okaybenji](https://qa.fmod.com/u/okaybenji)
#### Post date: [July 20, 2021, 5:30pm UTC](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078/24 "2021-07-20T17:30:39Z")

</div>

Hey, thank you for the reply. Yes, actually such a project is already uploaded to my profile. It’s called live-update-issue.zip.

---

<div class="post-metadata">

### Author: ![joseph](https://yyz2.discourse-cdn.com/flex036/user_avatar/qa.fmod.com/joseph/32/264_2.png) [@joseph](https://qa.fmod.com/u/joseph)
#### Post date: [August 9, 2021, 1:34am UTC](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078/25 "2021-08-09T01:34:33Z")

</div>

We’ve been able to reproduce this issue.

It’s caused by combination of using the `ExecuteAlways` attribute to run some FMOD code (which creates an FMOD system) in Unity edit mode, and disabling the domain reload that Unity ususally does when entering play mode. This causes the FMOD system to not be cleaned up properly.

We’re working on a fix, which will be included in an upcoming version of FMOD Studio. In the mean time, you should be able to work around this issue by removing `ExecuteAlways` from any classes/functions that touch the FMOD RuntimeManager, or by re-enabling the domain reload.

[Previous page](https://qa.fmod.com/t/fmod-studio-2-01-07-profiler-connects-to-unity-but-events-arent-recorded/17078.md?page=1)
