Skip to content

docs: fix stale rustdoc claims — phantom CACHEKIT_NAMESPACE, self-heal overstatement (LAB-682) - #65

Merged
27Bslash6 merged 1 commit into
mainfrom
lab-682-stale-rustdoc
Aug 8, 2026
Merged

docs: fix stale rustdoc claims — phantom CACHEKIT_NAMESPACE, self-heal overstatement (LAB-682)#65
27Bslash6 merged 1 commit into
mainfrom
lab-682-stale-rustdoc

Conversation

@27Bslash6

@27Bslash6 27Bslash6 commented Aug 8, 2026

Copy link
Copy Markdown
Contributor

Closes LAB-682. Doc-truth fix: three rustdoc surfaces in this repo claimed behaviour the code does not have (trust-bug class per LAB-388; the docs-site pages were already fixed in cachekit-io/docs#10, this PR fixes the source comments).

Changes

  1. CACHEKIT_NAMESPACE phantom env var removedCachekitConfig::from_env reads only CACHEKIT_API_KEY / API_URL / MASTER_KEY / PREVIOUS_MASTER_KEYS / DEFAULT_TTL; nothing reads CACHEKIT_NAMESPACE. Removed from:
    • crates/cachekit/src/client.rsinterop_get rustdoc # Errors section
    • crates/cachekit/src/client.rsreject_namespaced_interop error-message string (explicitly required by the issue AC; the only non-comment line touched — message content only, no logic change, and interop_get_fails_closed_on_namespaced_client asserts on the Config variant, not the text)
    • crates/cachekit-macros/src/lib.rs#[cachekit] macro rustdoc
    • README.md — interop callout (same lie, found by grep during implementation)
  2. Self-heal claim scoped (crates/cachekit-macros/src/lib.rs) — "treated as a miss and overwritten (self-healing), never an error loop" now states what the generated code does: only CachekitError::Serialization self-heals; on secure functions an AES-GCM auth failure raises CachekitError::Encryption, which propagates (fail-closed) until expiry. Wording matches cachekit-io/docs#10.
  3. 16-byte key minimum — already fixed on main (encryption_from_bytes rustdoc says ≥ 32 bytes, matching EncryptionLayer::new); nothing to change.

Verification

  • cargo fmt --all --check clean; cargo clippy clean (pre-commit hooks).
  • cargo doc --no-deps --workspace builds; the two remaining rustdoc warnings are pre-existing unresolved intra-doc links on untouched lines.
  • cargo test --workspace — all green (169 tests + doc-tests, 0 failures).
  • No runtime behaviour changes; git diff is doc comments + README + the one error-message string the AC calls out.

Summary by CodeRabbit

  • Documentation
    • Clarified interoperation guidance: clients must omit the .namespace() setting.
    • Updated configuration guidance to remove references to CACHEKIT_NAMESPACE.
    • Documented the distinction between deserialisation misses and AES-GCM authentication failures.
    • Clarified that secure authentication errors persist until the affected entry expires or is deleted.

- Drop phantom CACHEKIT_NAMESPACE env var from interop_get rustdoc, the
  reject_namespaced_interop error message, the #[cachekit] macro rustdoc,
  and the README interop callout — from_env reads only API_KEY / API_URL /
  MASTER_KEY / PREVIOUS_MASTER_KEYS / DEFAULT_TTL; nothing reads NAMESPACE,
  so the docs taught a knob that does not exist.
- Scope the macro self-heal claim to plaintext decode: only
  CachekitError::Serialization is treated as a miss and overwritten; on
  secure functions an AES-GCM auth failure raises CachekitError::Encryption,
  which propagates (fail-closed) until the entry expires — 'never an error
  loop' was an overstatement. Wording matches the docs-site fix (docs#10).

The third claim in LAB-682 (16-byte key minimum in encryption_from_bytes)
was already corrected on main — rustdoc says 32 bytes, matching
EncryptionLayer::new enforcement. No runtime behaviour changes.
@kodus-27b

kodus-27b Bot commented Aug 8, 2026

Copy link
Copy Markdown

Kody Review Complete

Great news! 🎉
No issues were found that match your current review configurations.

Keep up the excellent work! 🚀

Kody Guide: Usage and Configuration
Interacting with Kody
  • Request a Review: Ask Kody to review your PR manually by adding a comment with the @kody start-review command at the root of your PR.

  • Validate Business Logic: Ask Kody to validate your code against business rules by adding a comment with the @kody -v business-logic command.

  • Provide Feedback: Help Kody learn and improve by reacting to its comments with a 👍 for helpful suggestions or a 👎 if improvements are needed.

Current Kody Configuration
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug
Performance
Security
Business Logic

Access your configuration settings here.

@coderabbitai

coderabbitai Bot commented Aug 8, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro Plus

Run ID: de73d47e-a426-4708-bb5f-7f9f6308e7e3

📥 Commits

Reviewing files that changed from the base of the PR and between 8b9e7ac and c2777ae.

📒 Files selected for processing (3)
  • README.md
  • crates/cachekit-macros/src/lib.rs
  • crates/cachekit/src/client.rs

Walkthrough

The change updates interop-mode documentation and its namespace configuration error message. It removes CACHEKIT_NAMESPACE references, requires clients to omit .namespace(), and documents distinct handling for deserialisation misses and AES-GCM authentication failures.

Changes

Interop documentation

Layer / File(s) Summary
Align interop guidance and error behaviour
README.md, crates/cachekit-macros/src/lib.rs, crates/cachekit/src/client.rs
Interop guidance now refers to the client’s .namespace() setting. Macro documentation distinguishes deserialisation misses from AES-GCM authentication failures and documents their handling. The namespace rejection error message uses the same guidance.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Suggested reviewers: kodus-27b

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarises the documentation fixes for the obsolete CACHEKIT_NAMESPACE reference and the self-healing claim.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch lab-682-stale-rustdoc

Comment @coderabbitai help to get the list of available commands.

@27Bslash6
27Bslash6 merged commit 42697bd into main Aug 8, 2026
11 checks passed
@27Bslash6
27Bslash6 deleted the lab-682-stale-rustdoc branch August 8, 2026 12:34
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.

1 participant