gpt4 book ai didi

python - 使用 SimpleHTTPServer 的音频/视频流式传输失败

转载 作者:技术小花猫 更新时间:2023-10-29 10:38:13 26 4
gpt4 key购买 nike

<分区>

我通过使用 python -m SimpleHTTPServer 调用服务器将文件夹中的文件共享到其他设备。

我只是尝试将视频/音频(标准 mp4 和 mp3,均在 20MB 以下)流式传输到另一台计算机,使用它 WORKS(但通过在终端中抛出错误(列出)) .

不知何故,视频/音频无法在 iPhone/iPad 中使用 Safari 播放(除了非常小的 mp3 文件)。它绝对与媒体文件无关,因为我在 iPhone 中使用 Apache 成功地流式传输了它们。

知道为什么会这样吗?

Exception happened during processing of request from ('192.168.1.2', 51775)
Traceback (most recent call last):
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SocketServer.py", line 284, in _handle_request_noblock
self.process_request(request, client_address)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SocketServer.py", line 310, in process_request
self.finish_request(request, client_address)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SocketServer.py", line 323, in finish_request
self.RequestHandlerClass(request, client_address, self)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SocketServer.py", line 641, in __init__
self.finish()
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SocketServer.py", line 694, in finish
self.wfile.flush()
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/socket.py", line 303, in flush
self._sock.sendall(view[write_offset:write_offset+buffer_size])
error: [Errno 32] Broken pipe

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com