This report compares the two most comprehensive Rust Clippy lint configurations found:
- OpenAgentsInc/openagents - The "viral tweet" config from @notnotstorm (enhanced version)
- Mockapapella/tenex - Self-described "every single restriction" config
Finding: Neither config is a strict superset of the other. Each has valuable lints the other is missing. The combined "best of both" config is what rust-magic-linter provides.
| Lint Group | OpenAgentsInc | Tenex | Winner |
|---|---|---|---|
all |
not set | deny | Tenex |
pedantic |
warn | deny | Tenex |
nursery |
not set | deny | Tenex |
cargo |
not set | deny | Tenex |
Tenex wins on breadth - it enables more lint groups and at deny level.
These are critical lints for AI agents that Tenex lacks:
# === ASYNC SAFETY (Critical for modern Rust) ===
await_holding_lock = "deny" # Prevent deadlocks in async code
# This is CRITICAL - async code with locks is a common footgun
# === PROCESS/MEMORY SAFETY ===
exit = "deny" # Library code should never call exit()
mem_forget = "deny" # std::mem::forget can leak resources
# === STACK/PERFORMANCE ===
large_stack_arrays = "warn" # Catch huge stack allocations
panic_in_result_fn = "warn" # Functions returning Result shouldn't panic
# === OUTPUT CONTROL ===
print_stdout = "deny" # No println! in library code
print_stderr = "deny" # No eprintln! in library code
# These force structured logging - important for productionWhy these matter for AI agents:
await_holding_lock- AI agents write async code frequently and this is a subtle bugprint_stdout/stderr- Forces agents to use proper logging instead of debug printspanic_in_result_fn- Catches when agent writesfn foo() -> Result<...>but panics insideexit- Prevents agents from addingstd::process::exit()which breaks composability
Tenex has these that the tweet config lacks:
# === ADDITIONAL LINT GROUPS ===
all = { level = "deny", priority = -1 } # Base clippy lints
nursery = { level = "deny", priority = -1 } # Experimental lints
cargo = { level = "deny", priority = -1 } # Dependency/manifest hygiene
# === ALLOW ATTRIBUTE CONTROL ===
allow_attributes_without_reason = "deny" # If you DO allow, document whyTenex has comprehensive [lints.rust] that OpenAgentsInc lacks:
[lints.rust]
unsafe_code = "forbid" # No unsafe anywhere
warnings = "deny" # All warnings are errors
rust_2018_idioms = { level = "deny", priority = -1 }
future_incompatible = { level = "deny", priority = -1 }
nonstandard_style = { level = "deny", priority = -1 }
missing_docs = "deny" # Public items must be documented
missing_debug_implementations = "deny" # Types must impl Debug
missing_copy_implementations = "deny" # Types that can be Copy should be
non_ascii_idents = "forbid" # No unicode in identifiers
[lints.rustdoc]
all = { level = "deny", priority = -1 } # Documentation must be validOpenAgentsInc only has:
[workspace.lints.rust]
missing_docs = "allow" # Explicitly allows missing docs
unexpected_cfgs = "allow"- Async-specific guards (
await_holding_lock,exit,mem_forget) - Output control (
print_stdout,print_stderr) - Stack safety (
large_stack_arrays,panic_in_result_fn) - Curated pedantic overrides with detailed explanations
- Full lint group coverage (
all,nursery,cargoat deny level) - Comprehensive Rust lints (beyond clippy)
- Documentation enforcement (
missing_docs,missing_debug_implementations) - Stricter overall (deny vs warn)
For maximum AI guardrails, prioritize these categories:
unwrap_used = "deny" # No hidden panics
expect_used = "deny" # No hidden panics
panic = "deny" # No explicit panics
allow_attributes = "deny" # Can't silence warnings
todo = "deny" # No incomplete code
unimplemented = "deny" # No incomplete code
dbg_macro = "deny" # No debug leftoversawait_holding_lock = "deny" # Async deadlock prevention
panic_in_result_fn = "deny" # Logic error detection
exit = "deny" # Composability
mem_forget = "deny" # Resource leak preventionprint_stdout = "deny" # Proper logging
print_stderr = "deny" # Proper logging
nursery = "warn" # Catch more issues
missing_docs = "warn" # Force documentationrust-magic-linter's standard preset combines the best of both:
- OpenAgentsInc's async safety and output control
- Tenex's comprehensive lint groups
- Carefully curated relaxations for practical use
See skills/rust-magic-linter/assets/ for the complete configurations.