OpenXR requires restarting SteamVR between each play mode in the editor

I’m having an issue where I have to restart SteamVR each time I reenter play mode in the editor. If I don’t, then the game never loads into VR. Just has the endless steam little popup in the home screen of it loading. Any ideas how to resolve this? This didn’t happen before I updated to 2020.3 to switch to OpenXR.

I switched to Oculus as the default OpenXR provider, and still running into the same kind of issues. It’s frequently making me have to restart Unity as well, and Unity starts so much slower in 2020.3 than it did in 2019.4. This is going to affect my productivity majorly :confused:

EDIT:
And now Unity is also crashing often when trying to reenter play mode. Any ideas on how to resolve all these issues?

I had similar issues, for some reason OpenXR + SteamVR as runtime loses connection to Unity whenever the headset is asleep, this would even happen during scene loads if it lags out for a few seconds, it would just never return. The solution was to periodically poll if the device is active and then restart the XR manager.
https://www.reddit.com/r/learnVRdev/comments/netvkz/how_to_restart_xrloader_vive_headset_tracking/

void Update(){
if (timeoutcheck <= 0) {
            if (!XRSettings.isDeviceActive) {
                StartCoroutine(RestartXRCoroutine());
            }
            timeoutcheck = 2f;
        }
        timeoutcheck -= Time.deltaTime;
}

public IEnumerator RestartXRCoroutine() {
        StopXR();
        Debug.Log("Initializing XR...");
        yield return XRGeneralSettings.Instance.Manager.InitializeLoader();

        if (XRGeneralSettings.Instance.Manager.activeLoader == null) {
            Debug.LogError("Initializing XR Failed. Check Editor or Player log for details.");
        } else {
            XRGeneralSettings.Instance.Manager.StartSubsystems();
            Debug.Log($"Starting XR...{XRGeneralSettings.Instance.Manager.activeLoader.name} - {XRGeneralSettings.Instance.Manager.isInitializationComplete}");
        }
    }

    void StopXR() {
        Debug.Log("Stopping XR...");

        XRGeneralSettings.Instance.Manager.StopSubsystems();
        XRGeneralSettings.Instance.Manager.DeinitializeLoader();
        Debug.Log("XR stopped completely.");
    }

Not sure if this is an issue with OpenXR, SteamVR or Unity, but I hope they fix this cause this is janky AF.

That fixed it, thank you so much! It was driving me crazy

This appears to be fixed in OpenXR Plugin v1.2.2
https://docs.unity3d.com/Packages/com.unity.xr.openxr@1.2/changelog/CHANGELOG.html
“Fixed a bug when using SteamVR runtime that would cause the view to stop rendering and input to stop tracking if the main thread stalled for too long.”

Awesome, thank you!