Skip to content

Rà soát lần cuối: sửa ~100 lỗi kỹ thuật, lệch văn bản–mã và định dạng trên toàn giáo trình - #8

Merged
architectureman merged 5 commits into
mainfrom
fix/ra-soat-lan-cuoi
Oct 7, 2026
Merged

architectureman merged 5 commits into
mainfrom
fix/ra-soat-lan-cuoi

Conversation

@architectureman

Copy link
Copy Markdown
Contributor

Tóm tắt

Sửa toàn bộ lỗi tìm được trong lần rà soát chi tiết cuối cùng của main (sau PR #7). 82 file thay đổi, chia 5 commit theo nhóm chương.

Sai kỹ thuật (đã kiểm chứng bằng rustc 1.97)

  • ch13 divide dùng u32/NonZeroU32 (vì i32::MIN / -1 vẫn panic)
  • ch15 giải thích Fn/FnMut/FnOnce theo cách thân closure dùng giá trị (không phải chế độ bắt giữ); bỏ drop thừa trái NLL
  • ch16 fold/rfold cần phép gộp kết hợp + giao hoán; rayon không ép tính thuần túy
  • ch17 Monad = pure + bind + luật; ví dụ catch_unwind không dùng FFI; sửa lời giải Bài 1 (.len() thực sự lệch với "tiếng")
  • ch21 thông báo của assert_eq! từ Rust 1.73
  • ch30 khóa thiếu Hash trong HashMap báo E0599, không phải E0277
  • ch31 u16::try_from thay as u16 (không còn cắt cụt âm thầm) + 2 test mới
  • ch38 checked_add tránh tràn số; ch39 bẫy thật là *a = ptr::read(b); ch51 chặn shift >= 64 trong decode_varint
  • ch53 Multi-Paxos có leader ổn định; ch66 Cortex-M0 không có CAS, lập luận SPSC
  • Phụ lục A dựng lại sơ đồ phụ thuộc đúng spec Fantasy Land (thêm Traversable)

Lệch văn bản–mã

  • ch47 (cờ CLI, kiểu lỗi), ch54 (Pending), ch72 (Store/Account), ch74 (ngân sách demo)
  • Tên biến tiếng Việt sót trong comment ở ch29, 33, 58, 64, 66, 69, 76, 78, 80, 81, 85 (đổi đồng bộ cả chương lẫn crate)
  • H1 mọi chương khớp tiêu đề trong SUMMARY

Nội dung bổ sung

  • Lời giải đầy đủ (có test) cho 4 bài chỉ có gợi ý: ch56, ch58, ch61, ch62
  • ch05 lời giải đọc stdin thật; ch11 bảng so sánh Err vs panic!; ch54 Saga choreography

Định dạng / chính tả

  • Bảng lỗi ch43–47 (khối mã trong ô bảng hiển thị sai), 6 khối rỗng giữa hai --- (ch25–30), bảng GLOSSARY hỏng, chính tả và tham chiếu chương sai

Bỏ qua (tùy chọn): đổi total_amount: f64 sang u64 ở ch28, vì phải sửa nhiều chỗ.

Kiểm tra

  • cargo fmt --all --check: sạch
  • cargo clippy --workspace --all-targets -- -D warnings: 0 cảnh báo
  • cargo test --workspace: 996 passed (994 + 2 test mới ở ch31), 0 failed
  • mdbook build (v0.4.52): thành công
  • Rào mã cân bằng, không link/anchor hỏng; khối mã chính trong mọi chương vẫn khớp từng dòng với crate
  • Mọi lời giải bài tập mới hoặc đã sửa đều được biên dịch và chạy riêng

🤖 Generated with Claude Code

https://claude.ai/code/session_0111UHmpNfVqW6NWjKhiSg6X


Generated by Claude Code

claude added 5 commits October 7, 2026 11:26
…:try_from ở ch31, sơ đồ, khối rỗng)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0111UHmpNfVqW6NWjKhiSg6X
…47, bảng lỗi ch43–47, varint)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0111UHmpNfVqW6NWjKhiSg6X
… Fn/FnMut/FnOnce, cargo new, collect String)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0111UHmpNfVqW6NWjKhiSg6X
…antasy Land, tên biến sót, GLOSSARY, H1 khớp SUMMARY)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0111UHmpNfVqW6NWjKhiSg6X
… Cortex-M0, SPSC, thêm 4 lời giải bài tập)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0111UHmpNfVqW6NWjKhiSg6X
@ecc-tools

ecc-tools Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

ECC Tools / Security Evidence

Commit: 52c44e4a782522fd6a9834948b88abb7f8f9e874

Security evidence gate passed (success)

No security-sensitive scanner-evidence gap detected.

Mode: enforce

Scanned 82 changed file(s). No missing scanner-evidence signal was detected.

Check publication was denied or unavailable. An app owner must enable Checks: read and write, and the installation owner must approve the updated permission.

@ecc-tools

ecc-tools Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

ECC Tools / PR Risk Taxonomy

Commit: 52c44e4a782522fd6a9834948b88abb7f8f9e874

PR taxonomy review recommended (neutral)

Detected 1 PR taxonomy bucket(s): CI/CD Recommendation.

Scanned 82 changed file(s).

Roadmap taxonomy buckets:

CI/CD Recommendation

CI, dependency, coverage, and contract signals should be routed into follow-up checks or verification work.

Signals:

  • Regression coverage may lag behind the diff
  • 0 CI or workflow path(s) changed

Paths:

  • code/ch16_mo_rong/src/main.rs
  • code/ch31/src/main.rs
  • code/ch37/src/main.rs
  • code/ch39/src/main.rs
  • code/ch40/src/main.rs
  • code/ch58/src/main.rs
  • code/ch69/src/main.rs
  • code/ch76/src/main.rs

Check publication was denied or unavailable. An app owner must enable Checks: read and write, and the installation owner must approve the updated permission.

@ecc-tools

ecc-tools Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

ECC Tools / Reference Set Readiness

Commit: 52c44e4a782522fd6a9834948b88abb7f8f9e874

Reference set readiness gaps detected (neutral)

Reference evidence present for 0/7 areas (0%) across 82 changed file(s).

This check is based on files changed in this PR. Repository-level readiness is still reported by /ecc-tools analyze comments and generated manifests.

Area Status Evidence / Next Step
Deep analyzer corpus Missing Add analyzer fixture, golden, benchmark, or reference-set files that can catch analyzer regressions.
RAG/evaluator comparison Missing Add retrieval or evaluator reference-set comparison fixtures with expected ranking behavior.
PR salvage/review corpus Missing Add stale-PR, review-thread, reopen-flow, or salvage reference cases for queue cleanup automation.
Discussion triage corpus Missing Add public discussion triage fixtures, golden cases, or reference sets for informational, answered, and no-response classifications.
Harness compatibility Missing Add cross-harness, adapter-compliance, or harness-audit evidence for Claude, Codex, OpenCode, Zed, dmux, and agent surfaces.
Security evidence Missing Attach security evidence such as SBOMs, SARIF, audit reports, or AgentShield evidence packs.
CI failure-mode evidence Missing Add captured CI failure logs, dry-run fixtures, or troubleshooting docs for common workflow failure modes.

Check publication was denied or unavailable. An app owner must enable Checks: read and write, and the installation owner must approve the updated permission.

@ecc-tools

ecc-tools Bot commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

ECC Tools / Hosted Promotion Readiness

Commit: 52c44e4a782522fd6a9834948b88abb7f8f9e874

Hosted promotion readiness passed (success)

No hosted promotion evidence gaps detected across 82 changed file(s); 0 corpus scenarios had matching evidence.

This check compares PR file changes against the evaluator/RAG promotion corpus in src/analyzers/fixtures/evaluator-rag-corpus.ts.
Hosted output scoring inspected 0 completed cached hosted job results.

No evaluator corpus scenarios matched this PR.

Check publication was denied or unavailable. An app owner must enable Checks: read and write, and the installation owner must approve the updated permission.

@architectureman
architectureman merged commit 9ebfb61 into main Oct 7, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants