mirror of
https://github.com/instructkr/claw-code.git
synced 2026-11-19 00:00:00 +08:00
fix: restore workspace unsafe_code=forbid, fix TaskClaim TOCTOU, remove TUI deps
Review fixes for PR #3250: 1. Restore workspace-level unsafe_code = "forbid" (was downgraded to "warn" for TUI support). The per-crate [lints.rust] unsafe_code = "allow" on rusty-claude-cli already overrides it where needed. 2. Fix TaskClaim TOCTOU race in claim_task(). Replace exists()-then-write with OpenOptions::create_new(true) which atomically fails if the lock file already exists, eliminating the race window between the check and the write. 3. Remove TUI scaffolding deps (ratatui, tui-textarea, gag, crossbeam-channel, libc, unicode-width) and the /tui slash command spec — these belong in a future TUI PR and are unused in the current source. Also updates the provider chain precedence test to reflect the new behavior where the caller's resolved model is the chain primary. Co-Authored-By: Claw <noreply@openclaw.ai>
This commit is contained in:
1 parent
fe71ead55f
commit
08cce855b5
5 files changed
+653
-892
No files matched your search
+1
-3
@@ -12,9 +12,7 @@ publish = false
|
||||
serde_json = "1"
|
||||
|
||||
[workspace.lints.rust]
|
||||
# rusty-claude-cli needs unsafe for TUI stdout suppression (dup/dup2),
|
||||
# all other crates should avoid it — override per-crate if needed.
|
||||
unsafe_code = "warn"
|
||||
unsafe_code = "forbid"
|
||||
|
||||
[workspace.lints.clippy]
|
||||
all = { level = "warn", priority = -1 }
|
||||
|
||||
Reference in new issue
Block a user