Repository navigation
Conversation
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 and motivation
官方 1.12.2 中,纯数字答案可能已经进入消息内容,聊天页却只显示思考区域。最小输入为
42或 `sample42`,末尾没有换行。添加换行后可以正常输出。当前 dev 的相关实现也可复现。
原生 Markdown 解析器暂存行首数字,等待判断有序列表标记。上游流自然结束时,Kotlin 调用链没有释放这段待定内容,销毁 session 后尾部正文丢失。
改动范围 / Changes
兼容性与风险 / Compatibility and risks
保留现有 push、dispose 和上层流接口。自然结束时补齐尾部内容,取消或异常沿原有关闭路径处理。涉及 JNI 和流分组生命周期,需要 Android 构建及设备回归确认。
关联 Issue / Related issue
本 PR 自带最小复现,尚无对应 issue 编号。
验证方式 / Verification
Windows 宿主使用 MinGW g++ 6.3、C++14 和 JDK 21 JNI 头文件。
Checks=45 failures=0,覆盖 EOF、换行、未完成标记、整串/逐字、重复 finish、seed 和新后缀。git diff --check通过。python -B ci/script/check_repo_hygiene.py --base <dev-base> --candidate HEAD通过,7 个文件,0 errors / 0 warnings。C++ 检查在仓库根目录编译以下源文件,包含 JDK 的 include、include/win32 以及 app/src/main/cpp/streamnative,编译参数为
-std=c++14 -Wall -Wextra,然后运行得到的程序。Linux 可按本机 JDK 使用 include/linux,Linux 环境尚未运行。Android instrumentation、Kotlin 编译和 APK 构建尚未运行,本地未配齐该项目 Android SDK/NDK 和外部构建依赖。以 Draft 提交,方便先审查根因与修改,并由项目 CI 核 Android 兼容性。
证据 / Evidence
官方版手机对照中,原数字答案重入会话后仍不可见,完整中文句子并以句号结尾的回复正常显示。独立宿主诊断可稳定复现相同 EOF 丢字路径。手机保持官方 APK,补丁的手机效果仍待验证。
检查清单 / Checklist