hotham icon indicating copy to clipboard operation
hotham copied to clipboard

[Bug]: Hotham apps do not close correctly in the headset

Open kanerogers opened this issue 3 years ago • 3 comments
trafficstars

What happened?

Background

As per #214, @sinoth found the following:

  1. Run Simple Scene
  2. Press Oculus button and select 'Quit' from system menu
  3. Wait
  4. See error that "Simple Scene keeps stopping"
  5. Use error dialog to close the app

This is likely either an OpenXR or Android lifecycle issue.

Version

latest

In which Hotham component are you seeing the problem on?

Example

What VR System are you seeing the problem on?

Quest-2

What OS are you seeing the problem on?

No response

Relevant log output

No response

kanerogers avatar Jun 14 '22 23:06 kanerogers

I noticed there's a similar issue when exiting out of the simulator by clicking the window exit button:

[HOTHAM_SIMULATOR] !ERROR RENDERING FRAME! ERROR_OUT_OF_DATE_KHR
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: ERROR_VALIDATION_FAILURE', hotham\src\schedule_functions\end_frame.rs:18:28
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[HOTHAM_SIMULATOR] Destroy called..
[HOTHAM_SIMULATOR] All things are now destroyed
error: process didn't exit successfully: `target\release\hotham_crab_saber.exe` (exit code: 101)

louiidev avatar Jun 30 '22 12:06 louiidev

I noticed there's a similar issue when exiting out of the simulator by clicking the window exit button:

[HOTHAM_SIMULATOR] !ERROR RENDERING FRAME! ERROR_OUT_OF_DATE_KHR
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: ERROR_VALIDATION_FAILURE', hotham\src\schedule_functions\end_frame.rs:18:28
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
[HOTHAM_SIMULATOR] Destroy called..
[HOTHAM_SIMULATOR] All things are now destroyed
error: process didn't exit successfully: `target\release\haotham_crab_saber.exe` (exit code: 101)

Good point! But that one's kind of unrelated; in that instance it just comes from really sloppy handling of the swapchain in the simulator. It's technically a bug but it's not that high of a priority (though you are totally welcome to open a separate issue for that).

I've refined the issue to make it clear this is specifically about the failure case that occurs on the headset. Closing the app through the normal Oculus menus should "just work", but it isn't.

kanerogers avatar Jul 03 '22 06:07 kanerogers

May be something related to session lifecycle stuff:

https://registry.khronos.org/OpenXR/specs/1.0/html/xrspec.html#XR_OCULUS_android_session_state_enable

kanerogers avatar Dec 01 '22 04:12 kanerogers