Repository navigation
阶段 5 F1 后续调整:预览并入详情、方向控制符、截断计数、token 先存后抹(DEVLOG [33]) - #34
Merged
Merged
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.
F1(#33)评审的后续调整,不是新功能。全部改动都对应评审提出的调整项,不夹带重构。基线是 master 7f0cdcd。
评审项 → 改动
detect_encoding要读完整个文件,所以没改成只读前 N 行;改成把预览并入GET /datasets/{id}?rows=N,删掉/preview,POST /datasets的响应直接带预览,前端只发一个请求,每个文件只读一遍。详情改为直接用table_paths逐表读(表名和排序跟分析路径一致:B.csv + a.csv是 [B, a]),每张表单独 try,一张读坏不影响其他表;单表表名沿用df。updated_at:db.py加注释;左栏写明"按最近分析时间排序";补测试,确认改名不动updated_at。_BIDI_CONTROLS(含 LRM/RLM);_CONTROL_CHARS的字符集不变;预览只清方向控制符,并给出bidi_stripped计数。truncated_cells计数,在提示行写明。Query(None, ge=1, le=100),越界和非整数都返回 422。setItem,再抹地址栏;存失败时 token 只留在内存,页面不会白屏。多表概览从 summary 行移到 tab 标签上,跟 summary 来自同一次读取的同一个 DataFrame,数字口径一致。
不在本 PR
done_seen)、SSE 等,留到 F2。read_csv_with_encoding读取时 bytes、str、DataFrame 三份同时在内存,已记入 DEVLOG 未做项。验证
pytest 597 passed;vitest 21;Playwright 6;lint、tsc、build 通过。