Skip to content
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

ConnectionError: Video stream is disconnected为何连接失败?? #5729

Open
bingxuebojue opened this issue Jan 3, 2025 · 2 comments
Open

Comments

@bingxuebojue
Copy link

[AdbDevice(serial=AVRK023C30047187)] <scrcpy.core.Client object at 0x000002AECE4A7F10>
Exception in thread Thread-1:
Traceback (most recent call last):
File "D:\program-installation\anaconda3\envs\my_first_env\lib\threading.py", line 980, in _bootstrap_inner
self.run()
File "D:\program-installation\anaconda3\envs\my_first_env\lib\threading.py", line 917, in run
self._target(*self._args, **self._kwargs)
File "D:\program-installation\anaconda3\envs\my_first_env\lib\site-packages\scrcpy\core.py", line 253, in __stream_loop
raise e
File "D:\program-installation\anaconda3\envs\my_first_env\lib\site-packages\scrcpy\core.py", line 234, in __stream_loop
raise ConnectionError("Video stream is disconnected")
ConnectionError: Video stream is disconnected
为何连接失败!!

01-04 01:06:14.885 23756 23756 E AndroidRuntime: at com.genymobile.scrcpy.wrappers.SurfaceControl.createDisplay(SurfaceControl.java:81)
01-04 01:07:07.580 24241 24241 W ziparchive: Unable to open '/data/local/tmp/scrcpy-server.dm': No such file or directory
01-04 01:07:07.618 24241 24241 D AndroidRuntime: Calling main entry com.genymobile.scrcpy.Server
01-04 01:07:07.619 24241 24241 I scrcpy : Device: HONOR BVL-AN16 (Android 15)
01-04 01:07:07.622 2373 2373 E adbd : failed to connect to socket 'localabstract:scrcpy': could not connect to localabstract address 'localabstract:scrcpy'
01-04 01:07:07.628 24241 24241 E scrcpy : Could not invoke method
01-04 01:07:07.628 24241 24241 E scrcpy : java.lang.NoSuchMethodException: android.content.IClipboard$Stub$Proxy.addPrimaryClipChangedListener [interface android.content.IOnPrimaryClipChangedListener, class java.lang.String, int]
01-04 01:07:07.628 24241 24241 E scrcpy : at java.lang.Class.getMethod(Class.java:2950)
01-04 01:07:07.628 24241 24241 E scrcpy : at java.lang.Class.getMethod(Class.java:2450)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.genymobile.scrcpy.wrappers.ClipboardManager.getAddPrimaryClipChangedListener(ClipboardManager.java:103)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.genymobile.scrcpy.wrappers.ClipboardManager.addPrimaryClipChangedListener(ClipboardManager.java:111)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.genymobile.scrcpy.Device.(Device.java:89)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.genymobile.scrcpy.Server.scrcpy(Server.java:24)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.genymobile.scrcpy.Server.main(Server.java:255)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
01-04 01:07:07.628 24241 24241 E scrcpy : at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:424)
01-04 01:07:07.895 24251 24251 W ziparchive: Unable to open '/data/local/tmp/scrcpy-server.dm': No such file or directory
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.wrappers.SurfaceControl.createDisplay(SurfaceControl.java:83)
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.ScreenEncoder.createDisplay(ScreenEncoder.java:229)
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.ScreenEncoder.internalStreamScreen(ScreenEncoder.java:75)
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.ScreenEncoder.streamScreen(ScreenEncoder.java:65)
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.Server.scrcpy(Server.java:80)
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.Server.main(Server.java:255)
01-04 01:07:07.912 24241 24241 E AndroidRuntime: at com.genymobile.scrcpy.wrappers.SurfaceControl.createDisplay(SurfaceControl.java:81)
01-04 01:07:07.913 24241 24241 E scrcpy : Exception on thread Thread[main,5,main]
01-04 01:07:07.913 24241 24241 E scrcpy : java.lang.AssertionError: java.lang.NoSuchMethodException: android.view.SurfaceControl.createDisplay [class java.lang.String, boolean]
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.wrappers.SurfaceControl.createDisplay(SurfaceControl.java:83)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.ScreenEncoder.createDisplay(ScreenEncoder.java:229)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.ScreenEncoder.internalStreamScreen(ScreenEncoder.java:75)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.ScreenEncoder.streamScreen(ScreenEncoder.java:65)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.Server.scrcpy(Server.java:80)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.Server.main(Server.java:255)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:424)
01-04 01:07:07.913 24241 24241 E scrcpy : Caused by: java.lang.NoSuchMethodException: android.view.SurfaceControl.createDisplay [class java.lang.String, boolean]
01-04 01:07:07.913 24241 24241 E scrcpy : at java.lang.Class.getMethod(Class.java:2950)
01-04 01:07:07.913 24241 24241 E scrcpy : at java.lang.Class.getMethod(Class.java:2450)
01-04 01:07:07.913 24241 24241 E scrcpy : at com.genymobile.scrcpy.wrappers.SurfaceControl.createDisplay(SurfaceControl.java:81)
01-04 01:07:07.913 24241 24241 E scrcpy : ... 7 more
01-04 01:07:07.935 24251 24251 D AndroidRuntime: Calling main entry com.genymobile.scrcpy.CleanUp
01-04 01:07:07.942 24251 24251 I scrcpy : Cleaning up
^C^C
C:\Users\lenovo>adb logcat | findstr scrcpy

@rom1v
Copy link
Collaborator

rom1v commented Jan 3, 2025

Does it work with scrcpy 3.1 directly? (it seems you're using some python wrapper)

@bingxuebojue
Copy link
Author

它能直接与 scrcpy 3.1 一起使用吗?(看起来你正在使用一些 python 包装器)

我现在用的是scrcpy2.6.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants