Open vpeinadolopez opened 2 years ago
error: XDG_RUNTIME_DIR not set in the environment.
This seems totally independent of the phone. :thinking:
[server] ERROR: Exception on thread Thread[main,5,main] java.lang.AssertionError: java.lang.reflect.InvocationTargetException at com.genymobile.scrcpy.wrappers.SurfaceControl.setDisplaySurface(SurfaceControl.java:75) at com.genymobile.scrcpy.ScreenEncoder.setDisplaySurface(ScreenEncoder.java:178) at com.genymobile.scrcpy.ScreenEncoder.streamScreen(ScreenEncoder.java:70) at com.genymobile.scrcpy.Server.scrcpy(Server.java:34) at com.genymobile.scrcpy.Server.main(Server.java:163) at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method) at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:355) Caused by: java.lang.reflect.InvocationTargetException at java.lang.reflect.Method.invoke(Native Method) at com.genymobile.scrcpy.wrappers.SurfaceControl.setDisplaySurface(SurfaceControl.java:73) ... 6 more Caused by: java.lang.IllegalArgumentException: displayToken must not be null at android.view.SurfaceControl$Transaction.setDisplaySurface(SurfaceControl.java:3240) at android.view.SurfaceControl.setDisplaySurface(SurfaceControl.java:2300) ... 8 more
Same problem with pixel 3 android 12
You need scrcpy >= 1.18 for Android 12. Upgrade to the latest version (currently 1.23).
This is definitely a phone problem and not with scrcpy. It's just the same with other Xiaomi devices where scrcpy broke after updating to MIUI 13 A12
Same Issue With me I'm Using Miui 13
INFO: scrcpy 1.17 https://github.com/Genymobile/scrcpy
/usr/share/scrcpy/scrcpy-server: 1 file pushed. 0.4 MB/s (34012 bytes in 0.077s)
[server] INFO: Device: Xiaomi M2007J17C (Android 12)
INFO: Renderer: opengl
INFO: OpenGL version: 4.3 (Compatibility Profile) Mesa 21.2.6
INFO: Trilinear filtering enabled
INFO: Initial texture: 1080x2400
WARN: Device disconnected
[server] ERROR: Exception on thread Thread[main,5,main]
java.lang.AssertionError: java.lang.reflect.InvocationTargetException
at com.genymobile.scrcpy.wrappers.SurfaceControl.setDisplaySurface(SurfaceControl.java:75)
at com.genymobile.scrcpy.ScreenEncoder.setDisplaySurface(ScreenEncoder.java:243)
at com.genymobile.scrcpy.ScreenEncoder.internalStreamScreen(ScreenEncoder.java:91)
at com.genymobile.scrcpy.ScreenEncoder.streamScreen(ScreenEncoder.java:60)
at com.genymobile.scrcpy.Server.scrcpy(Server.java:80)
at com.genymobile.scrcpy.Server.main(Server.java:252)
at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:363)
Caused by: java.lang.reflect.InvocationTargetException
at java.lang.reflect.Method.invoke(Native Method)
at com.genymobile.scrcpy.wrappers.SurfaceControl.setDisplaySurface(SurfaceControl.java:73)
... 7 more
Caused by: java.lang.IllegalArgumentException: displayToken must not be null
at android.view.SurfaceControl$Transaction.setDisplaySurface(SurfaceControl.java:3237)
at android.view.SurfaceControl.setDisplaySurface(SurfaceControl.java:2256)
... 9 more
WARN: Killing the server...
Same Issue With me I'm Using Miui 13 INFO: scrcpy 1.17 https://github.com/Genymobile/scrcpy
Same issue, same solution:
You need scrcpy >= 1.18 for Android 12. Upgrade to the latest version (currently 1.23).
Same Issue With me I'm Using Miui 13 INFO: scrcpy 1.17 https://github.com/Genymobile/scrcpy
Same issue, same solution:
You need scrcpy >= 1.18 for Android 12. Upgrade to the latest version (currently 1.23).
i did updated with this instructions and its working as a charm :)
You need scrcpy >= 1.18 for Android 12. Upgrade to the latest version (currently 1.23).
This finally did it for me. Apparently the scrcpy version of piKISS is not updated yet, I was running 1.17 without knowing. I uninstalled, and pulled from this repository directly. Now I even managed to make it work wirelessly. Thanks a lot.
Environment
I've been playing with scrcpy this days with no problem casting my Poco's screen. Since I uploaded to Android 12 & MIUI 13, from Android 11 & MIUI 12.5 the app doesn't run and it gives me an environment error.
error: XDG_RUNTIME_DIR not set in the environment.
I had to run it as admin for this error to pop out and otherwise no other aparent error comes out. I inmediately ran it with my friend's identical phone, but not updated, and it's still working, so nothing on the app broke. I don't know much about Linux so I have no idea what the issue could be.
Thanks! :D