New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Apps are killed immediately if executing waydroid app launch
before starting a session
#1066
Comments
waydroid app launch
before starting a sessionwaydroid app launch
before starting a session
You should be able to upload a |
Thanks for your tip! I have uploaded the fresh log. |
On Waydroid 1.4.2 on Manjaro KDE Wayland. In my case, if I start an app before starting Waydroid session, a full-screen window shows up with some telltale, then the window disappears without starting the app. I checked with ps and found the Waydroid session has indeed been started. If I start the app again, it starts. |
This line silently fails since waydroid/tools/interfaces/IPlatform.py Line 184 in 2be58d1
Adding a 1 second delay works but it's only a hack: diff --git a/tools/services/user_manager.py b/tools/services/user_manager.py
index 83a50cc..bd845a6 100644
--- a/tools/services/user_manager.py
+++ b/tools/services/user_manager.py
@@ -3,6 +3,7 @@
import logging
import os
import threading
+import time
import tools.config
import tools.helpers.net
from tools.interfaces import IUserMonitor
@@ -83,6 +84,9 @@ NoDisplay={str(hide).lower()}
makeDesktopFile(app)
multiwin = platformService.getprop("persist.waydroid.multi_windows", "false")
makeWaydroidDesktopFile(multiwin == "true")
+
+ # HACK: Applications are killed when they are started too early
+ time.sleep(1)
if unlocked_cb:
unlocked_cb()
Maybe this patch is causing "user unlock" to be returned too early: |
Describe the bug
Most apps being killed immediately if I execute
waydroid app launch <PKG_NAME>
before starting a session manually withwaydroid session start
.Have confirmed that this is a totally different problem from #474 or #702.
To be exact:
waydroid session stop
to ensure that the session had been killed;waydroid app launch com.hypergryph.arknights
;waydroid status
says:On the other hand:
waydroid session start
to ensure that the session had been started up; wait untilAndroid with user 0 is ready
printed;waydroid app launch com.hypergryph.arknights
;General information (please complete the following information):
system_datetime
/vendor_datetime
from/var/lib/waydroid/waydroid.cfg
: 1692422331 / 1692444077Desktop (please complete the following information):
Additional context
I can confirm that the application had been killed by
ActivityManager
as soon as the app initializes, which claimed that the app had started up too many empty processes without components:I compared two logcat files, and found that an exception only occurs when killing:
So I suspect that it has something to do with this patch. Seems that the app walks in before the system UI has been initialized…
I cleaned the logcat outputs by hand and these two logs should be more readable:
readable_logcat_not_killed.log
readable_logcat_killed.log
Logs (please upload as file)
/var/lib/waydroid/waydroid.prop
: waydroid.prop.txt/var/lib/waydroid/waydroid.log
: waydroid.log (Ctrl+C
was pressed down to send a SIGTERM at16:53:39
)waydroid logcat
while Waydroid is running: logcat_killed.log logcat_not_killed.logdmesg
: dmesg.logThe text was updated successfully, but these errors were encountered: