An attempt was made to use an object that is not, or is no longer, usable

Shows this as error “An attempt was made to use an object that is not, or is no longer, usable.” when clicking Enter VR
Chrome, window without addons, simple scene, Unity 2021.3.3f1, Windows 11, Quest 2. It was working for a bit several days ago.
In Edge shows the same. This is followed by:
“Failed to execute ‘requestSession’ on ‘XRSystem’: There is already an active, immersive XRSession.”
“TypeError: Cannot read properties of null (reading ‘cancelAnimationFrame’)”
I can spin the scene with the mouse
No errors in Unity console

Original Post on Discord

by user 393555151903916042

Hello, is chrome by any chance in fullscreen when this happens? Ive only seen the fail to execute requestSession when trying to enter XR while being in fullscreen (when set from Javascript)

Which chrome version are you using?

Not full screen. 108.0.5359.99

by user 393555151903916042

Console from developer tools in chrome
message.txt

by user 393555151903916042

Might be easier to read like this

by user 393555151903916042

I have made a new project and again just minimal scene and that one works fine. The first one was also just a test so I don’t need to make it work

by user 393555151903916042

Do you think you could send me the scene/project that didnt work?

You can easily create a zip via help/needle engine/zip scene and dm it :slightly_smiling_face: id like to try if it fails here too and if so figure out whats causing that

I have just sent it. This is the new scene that I said was working fine yesterday

by user 393555151903916042

Hello @heretic can you still reproduce this? I tried reproducing using Air Link - that worked as expected. Anything else I should try?

Oh wait the scene you sent is the one that works^^? So I assume the one that didnt work was basically the same but you dont have it anymore?

This one doesn’t work but did the day before. I’ve just sent this one because it was simpler but gave the same error. Are you saying it works on your side?

by user 393555151903916042

Yes worked on my side. Only thing i noticed (but unrelated) is that the project isnt set to Linear colorspace so the skybox looks wrong

Do you suspect Unity, Chrome or something else. I only restarted computer and reconnected the Quest between those two days where it worked and when it stopped, I didn’t even use laptop for anything else

by user 393555151903916042

Its not Unity. Maybe chrome (which version are you using?) or something that goes wrong the the Oculus app (I just updated before trying your scene).

Do you use airlink or cable? I tried using airlink here.

Im on chrome 108.0.5359.100 right now

Maybe also something with a wrong threejs version installed? Unlikely but who knows? :thinking:

Cable. I’ve updated to 108.0.5359.125 (Official Build) (64-bit) to be sure it wasn’t it

by user 393555151903916042

Is threejs installed with needle or was that somehing I chose - sorry, I don’t remeber

by user 393555151903916042