mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-11-20 21:35:59 +00:00
fix(runtime): record why a runtime install failed in the session events (#2591)
* fix(runtime): record why a runtime install failed in the session events * fix(runtime): report empty or invalid runtime catalogs in the failure event * fix(runtime): keep each install failure reason on its own job * fix(runtime): name the busy reason for rejected installs and drop the owner's listener * fix(runtime): keep each install call's failure reason on its calling thread * fix(runtime): keep the interrupted reason when a joined install finishes during the wait
This commit is contained in:
1 parent
2cb51103ac
commit
aa3a599ec6
8 files changed
+538
-53
No files matched your search
@@ -2235,11 +2235,16 @@ class SessionActivity : ComponentActivity(), SurfaceHolder.Callback, com.droidde
|
||||
|
||||
private fun installRuntime(): String? {
|
||||
val release = com.droiddeck.launcher.runtime.LinuxRuntimeInstaller.fetchRelease()
|
||||
?: return getString(R.string.session_runtime_catalog_unreachable)
|
||||
if (release == null) {
|
||||
SessionEvents.record("runtime.failed", mapOf("step" to "catalog", "reason" to com.droiddeck.launcher.runtime.LinuxRuntimeInstaller.catalogError()))
|
||||
return getString(R.string.session_runtime_catalog_unreachable)
|
||||
}
|
||||
runCatching { com.droiddeck.launcher.runtime.RuntimeInstallService.start(this, release) }
|
||||
val ok = com.droiddeck.launcher.runtime.LinuxRuntimeInstaller.install(this, release,
|
||||
progressFor(RUNTIME_LINES, release.size / 1_000_000))
|
||||
return if (ok) null else getString(R.string.session_runtime_install_failed)
|
||||
if (ok) return null
|
||||
SessionEvents.record("runtime.failed", mapOf("step" to "install", "reason" to com.droiddeck.launcher.runtime.LinuxRuntimeInstaller.installError()))
|
||||
return getString(R.string.session_runtime_install_failed)
|
||||
}
|
||||
|
||||
private fun installDesktop(): String? {
|
||||
|
||||
Reference in new issue
Block a user