occ-conflict-proof-hook

Reproduce optimistic concurrency conflicts in Rust MCP handlers with a deterministic pre-write seam.

3|3|Updated Apr 13, 2026
One-click install
npx skills add https://github.com/quaid-app/quaid --skill occ-conflict-proof-hook
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: occ-conflict-proof-hook
Source: https://github.com/quaid-app/quaid/tree/main/.squad/skills/occ-conflict-proof-hook
Command: npx skills add https://github.com/quaid-app/quaid --skill occ-conflict-proof-hook

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Prove optimistic concurrency races in Rust MCP handlers with a deterministic pre-write seam.

Core Features & Use Cases

  • Deterministic pre-write hook to reproduce conflicts in MCP handlers.
  • Thin public handler that delegates to an internal implementation for testability.
  • Test utilities to inject a before_write callback and assert outcomes.

Quick Start

Run the conflict-proof hook in your MCP tests to deterministically reproduce a ConflictError and verify the final state matches the winning write.

Frequently Asked Questions about occ-conflict-proof-hook

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I deterministically reproduce optimistic concurrency conflicts in Rust MCP handlers?▼

Use a deterministic pre-write hook to inject a before_write callback in your Rust MCP handlers. This reliably triggers optimistic concurrency conflicts, allowing you to assert ConflictError outcomes and verify the winner's final state in tests.

What is a deterministic pre-write seam for race-condition testing?▼

A deterministic pre-write seam is a test-only hook injected before write operations. It controls execution timing in Rust MCP handlers to reliably reproduce race conditions without relying on non-deterministic thread scheduling.

Can I use this hook to test race conditions across different pages and versions?▼

Yes, the deterministic pre-write hook applies to Rust MCP handler tests across pages and versions, enabling reliable race-condition experiments in both unit and integration test scenarios to verify conflict resolution.

How do I verify the winning state after a ConflictError is returned in a Rust MCP test?▼

Inject a before_write callback to trigger the conflict, then assert that the handler returns a ConflictError and that the final stored state matches the winner's write, verifying your race-condition handling logic.

Why do I need a before_write callback for MCP race tests instead of standard async tests?▼

Standard async tests suffer from non-deterministic thread scheduling, making race conditions hard to reproduce. A before_write callback provides a deterministic seam to reliably trigger optimistic concurrency conflicts on every test run.