Request BLE permission before waiting to advertise
When NFC handover includes any BLE method on Android 12+ and the BLUETOOTH_* runtime permissions have not already been granted, model.start(true) leaves the presentation model in CHECK_PERMISSIONS. Because the UI launch/request is disabled here, and listenOnMethods() waits for the state to leave CHECK_PERMISSIONS before advertising transports, no code ever calls setPermissionState() or requests permission, so an external NFC presentation hangs after handover instead of progressing.
Originally posted by @chatgpt-codex-connector[bot] in #416 (comment)
When NFC handover includes any BLE method on Android 12+ and the
BLUETOOTH_*runtime permissions have not already been granted,model.start(true)leaves the presentation model inCHECK_PERMISSIONS. Because the UI launch/request is disabled here, andlistenOnMethods()waits for the state to leaveCHECK_PERMISSIONSbefore advertising transports, no code ever callssetPermissionState()or requests permission, so an external NFC presentation hangs after handover instead of progressing.Originally posted by @chatgpt-codex-connector[bot] in #416 (comment)