fix(qqbot): persist listener state before service stop and allow IPC timeout - #1142
Open
3316891527 wants to merge 1 commit into
Open
fix(qqbot): persist listener state before service stop and allow IPC timeout#11423316891527 wants to merge 1 commit into
3316891527 wants to merge 1 commit into
Conversation
…timeout Keep ToolPkg.ipc.call compatible with existing 7-argument native calls. Plugins may pass optional timeoutMs; omitted calls still default to 15s. QQ Bot writes listenerEnabled before start/stop and shortens leftover process scans so a killed-app restart cannot deadlock the settings toggle.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
变更说明 / Description
背景与动机 / Context
QQ Bot 设置页通过
ToolPkg.ipc.call把监听开关转发到 main runtime。宿主原先把 IPC 执行超时写死为 15 秒。杀后台后再次进入设置页关监听时,停机会串行探测残留进程,容易超过 15 秒;而listenerEnabled=false又写在停机成功之后,超时后配置仍为 true,application_on_create会再次自动拉起,开关随后全部超时,只能重装。改动内容 / Changes
ToolPkg.ipc.call的options增加可选timeoutMs;不传时仍走原 7 参数invokeToolPkgIpcAsync,现有插件调用不变;qqbot_service_start/qqbot_service_stop先写入listenerEnabled,再启动或停止网关;/proc;验证方式与结果 / Verification
tsc编译;Android Build在4285f1a已通过:https://github.com/3316891527/Operit/actions/runs/34181195962Android Tests仍红在上游存量DeepseekProviderMediaRoleTest/XaiProviderReasoningTest编译错误,与本次 IPC / QQ Bot 改动无关。关联 Issue / Related Issues
Fixes #1138
检查清单 / Checklist
ToolPkg.ipc.call调用保持兼容(不传 timeoutMs 仍为 15 秒)