chen3861229 / dd-danmaku

Emby danmaku extension
MIT License
82 stars 5 forks source link

[BUG]emby安卓端无法正常加载 #20

Closed minekil closed 4 days ago

minekil commented 5 days ago

Version

Describe the bug

打开视频没有弹幕加载,弹幕界面ui乱码(图2),弹幕引擎似乎无法启动

To Reproduce

1.手机通过mt管理器直接编辑emby安装包的index.html后使用v2签名并安装 2.首次打开会在登录界面加载不正常(图1),直接输入账号密码登录会闪退,直接关闭再次打开就正常了。没有安装弹幕库就没有这个问题 3.打开番剧弹幕没有加载,打开弹幕ui界面乱码(图2),打开控制台日志然后重开了 4.弹幕依旧没有加载,控制台日志获得下面的日志部分。点击打印引擎信息提示乱码+两个false 5.当主界面提示快速调试true的时候(实际上是乱码+true),打开番剧可以正常加载弹幕但是设置界面还是乱码 Screenshots 图1 Screenshot_20241108_145814 图2 Screenshot_20241108_153824

日志: [2024/11/8 15:16:01] [INFO] [❕] : 正在初始化UI [2024/11/8 15:16:01] [INFO] [❕] : 播放页不存在 video 标签,适配å¨å¤„理开始 [2024/11/8 15:16:01] [INFO] [❕] : 已创建èšæ‹Ÿ video 标签,适配å¨å¤„理正ç¡ç»“束 [2024/11/8 15:16:01] [INFO] [❕] : 正在初始化Listener [2024/11/8 15:16:01] [INFO] [❕] : Listener初始化åŒæˆ [2024/11/8 15:16:01] [INFO] [❕] : onPositionSliderEndEditing [2024/11/8 15:16:01] [INFO] [❕] : apiclient.fetchWithFailover http://192.168.0.114:8096/emby/Users/659fdb8c97cf48b8875ff4f178db03e4/Items/11197?ExcludeFields=VideoChapters%2CVideoMediaSources%2CMediaStreams&X-Emby-Client=Emby+for+Android&X-Emby-Device-Name=V2270A&X-Emby-Device-Id=ca7acc81395e89d9&X-Emby-Client-Version=3.4.11&X-Emby-Token=f12f151469fb47f8a5316c41069d4bef&X-Emby-Language=zh-cn [2024/11/8 15:16:01] [INFO] [❕] : updateTransparency: isLocalVideo:true, mediaType:Video [2024/11/8 15:16:01] [INFO] [❕] : attempting to lock orientation to: any [2024/11/8 15:16:01] [WARN] [⚠️] : seeking 79.933 0 [2024/11/8 15:16:01] [INFO] [❕] : header height : 0 [2024/11/8 15:16:01] [INFO] [❕] : validateFeature: dvr [2024/11/8 15:16:01] [INFO] [❕] : Failed to execute 'put' on 'Cache': Request scheme 'file' is unsupported [2024/11/8 15:16:02] [INFO] [❕] : waitForElement: checking element[.graphicContentContainer:not(.hide) .videoOsdBottom-maincontrols .videoOsdBottom-buttons] [2024/11/8 15:16:02] [INFO] [❕] : UI初始化åŒæˆ [2024/11/8 15:16:03] [INFO] [❕] : nowplaying event: playbackstart [2024/11/8 15:16:03] [INFO] [❕] : onPositionSliderEndEditing [2024/11/8 15:16:03] [INFO] [❕] : updateTransparency: isLocalVideo:true, mediaType:Video [2024/11/8 15:16:03] [INFO] [❕] : attempting to lock orientation to: any [2024/11/8 15:16:03] [INFO] [❕] : playbackstart [2024/11/8 15:16:03] [INFO] [❕] : header height : 0 [2024/11/8 15:16:03] [INFO] [❕] : dom getWindowSize [2024/11/8 15:16:03] [INFO] [❕] : validateFeature: dvr [2024/11/8 15:16:03] [INFO] [❕] : Failed to execute 'put' on 'Cache': Request scheme 'file' is unsupported [2024/11/8 15:16:03] [WARN] [⚠️] : unpause [2024/11/8 15:16:04] [INFO] [❕] : focusMainOsdControls [2024/11/8 15:16:06] [INFO] [❕] : onPositionSliderEndEditing [2024/11/8 15:16:07] [INFO] [❕] : 弹幕获取成功: 2510 [2024/11/8 15:16:07] [INFO] [❕] : 弹幕加载成功: 2510 [2024/11/8 15:16:07] [INFO] [❕] : Danmaku is not defined [2024/11/8 15:16:08] [INFO] [❕] : waitForElement: checking element[#dialogContainer] [2024/11/8 15:16:11] [INFO] [❕] : 点击弹出框外部取消: undefined [2024/11/8 15:16:12] [INFO] [❕] : focusMainOsdControls [2024/11/8 15:16:13] [INFO] [❕] : focusMainOsdControls [2024/11/8 15:16:13] [INFO] [❕] : onPositionSliderEndEditing [2024/11/8 15:16:13] [INFO] [❕] : waitForElement: checking element[#dialogContainer]

Additional context 直接清空应用数据可以复现2~4

ykchenc commented 4 days ago

https://github.com/9channel/dd-danmaku/pull/60#issuecomment-2309017026 可以参考下这个,你是使用哪种方式引入的

minekil commented 4 days ago

9channel#60 (comment) 可以参考下这个,你是使用哪种方式引入的

使用主页面的选项3把Cloudflare Pages 网络地址粘贴到了后面,的前面。 跟着文中指示添加charset=”utf-8″ui也正常了。初次登录的闪退算个不痛不痒的小问题,打开快速调试后弹幕也能正常加载了,也算是解决了吧

chen3861229 commented 4 days ago

更改了 CDN 响应 js 文件的字符集了,以下方式引入的,可以不用自己设置charset="utf-8"

  1. 使用 Cloudflare Pages 网络地址,等同 main 分支
    <script src="https://dd-danmaku.7o7o.cc/ede.js" defer></script>
minekil commented 4 days ago

更改了 CDN 响应 js 文件的字符集了,以下方式引入的,可以不用自己设置了charset="utf-8"

  1. 使用 Cloudflare Pages 网络地址,等同 main 分支
<script src="https://dd-danmaku.7o7o.cc/ede.js" defer></script>

速报:安卓端使用cf链接安装1.39版本导致一直卡在加载界面。因为jsdelivr链接还是1.38版本所以可以正常打开

chen3861229 commented 4 days ago

多谢提醒,不过根据测试得知,和新版本暂时无关,是Cloudflare Pages托管的js文件,被强制隐去了Content-Length响应头会导致客户端开屏闪退,还是用jsdelivr稳一点儿