Skip to content

Add Shipworthy production engineering guardrails cursorrules#217

Open
Vimalk0703 wants to merge 2 commits intoPatrickJS:mainfrom
Vimalk0703:add-shipworthy
Open

Add Shipworthy production engineering guardrails cursorrules#217
Vimalk0703 wants to merge 2 commits intoPatrickJS:mainfrom
Vimalk0703:add-shipworthy

Conversation

@Vimalk0703
Copy link
Copy Markdown

@Vimalk0703 Vimalk0703 commented Mar 31, 2026

Adds a .cursorrules file with production engineering guardrails from Shipworthy.

Covers: TDD workflow, input validation (Zod/Pydantic), structured logging, proper HTTP status codes, real databases, security checks, intent-to-spec generation, project diagnosis, and quality gates.

Added to the Other section alphabetically.

Summary by CodeRabbit

  • Documentation
    • Added a Production Guardrails guide outlining enforced development standards: test-driven development, input validation, structured logging, proper HTTP status codes, persistent databases, secret handling/startup validation, secure password hashing, client-safe error messages, required linting and coverage, an "intent-to-spec" step for non-trivial features, session checklist, routing instructions for work types, and quality gate verification.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 31, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: e43d505c-3cd3-40c9-a243-795ffb93b90e

📥 Commits

Reviewing files that changed from the base of the PR and between b397f88 and 6b57b8a.

📒 Files selected for processing (2)
  • README.md
  • rules/shipworthy-production-guardrails/.cursorrules
✅ Files skipped from review due to trivial changes (2)
  • README.md
  • rules/shipworthy-production-guardrails/.cursorrules

📝 Walkthrough

Walkthrough

Added a new "Shipworthy Production Guardrails" Cursor rules entry in the README and a new rules file that codifies production engineering requirements: TDD, input validation, structured logging, HTTP status conventions, enforced persistence, secret handling, linting, type-safety, testing, and verification steps.

Changes

Cohort / File(s) Summary
Documentation
README.md
Inserted a new "Shipworthy Production Guardrails" entry under the "Other" rules list linking to the new rules file.
Guardrails rules
rules/shipworthy-production-guardrails/.cursorrules
Added new Cursor rules defining production guardrails: testing and coverage requirements, mandatory input validation (Zod for TS), prohibition of console.log and any, linting, structured logging, HTTP status conventions, database persistence requirement, secret validation, secure password hashing, client-safe errors, intent-to-spec process, session checklist, skill routing, and verification proof steps.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

Suggested reviewers

  • PatrickJS

Poem

🐇 I hop through code with careful paws,

I stitch the rules and mind the laws,
Tests and checks, no secrets kept,
Production dreams are safely prepped,
A rabbit's nod — the guardrails set.

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title directly and accurately summarizes the main change: adding a new Cursor rules file for production engineering guardrails from the Shipworthy project.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
rules/shipworthy-production-guardrails/.cursorrules (1)

15-15: Consider clarifying the scope of the database requirement.

The rule "ALWAYS use a database — never in-memory arrays. SQLite minimum" is quite strict and may not apply to all scenarios (e.g., in-memory caching layers, certain microservices, prototypes). While appropriate for production data persistence, you might consider adding a brief qualifier like "for persistent data" to clarify when this rule applies.

💡 Optional clarification
-7. **ALWAYS use a database** — never in-memory arrays. SQLite minimum.
+7. **ALWAYS use a database for persistent data** — never in-memory arrays. SQLite minimum.

This clarifies that the rule applies to data that needs to persist, while not preventing legitimate in-memory caching or ephemeral data structures.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@rules/shipworthy-production-guardrails/.cursorrules` at line 15, Update the
rule text that currently reads "ALWAYS use a database — never in-memory arrays.
SQLite minimum." to add a scope qualifier such as "for persistent data" (e.g.,
"ALWAYS use a database for persistent data — never in-memory arrays; SQLite
minimum.") so the rule applies to persistence only and does not block legitimate
in-memory caches or ephemeral structures; locate and edit the rule string
"ALWAYS use a database — never in-memory arrays. SQLite minimum." in
.cursorrules and replace it with the clarified phrasing.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@README.md`:
- Line 272: The README's "Shipworthy Production Guardrails" entry in the "Other"
category is out of alphabetical order; move the markdown list item "-
[Shipworthy Production
Guardrails](./rules/shipworthy-production-guardrails/.cursorrules)" so it
appears after the "Next.js (Type LLM)" entry and before the "Unity (C#)" entry
within the "Other" category, and remove its original occurrence between "Code
Guidelines" and "Code Style Consistency" so the category remains alphabetically
sorted.

---

Nitpick comments:
In `@rules/shipworthy-production-guardrails/.cursorrules`:
- Line 15: Update the rule text that currently reads "ALWAYS use a database —
never in-memory arrays. SQLite minimum." to add a scope qualifier such as "for
persistent data" (e.g., "ALWAYS use a database for persistent data — never
in-memory arrays; SQLite minimum.") so the rule applies to persistence only and
does not block legitimate in-memory caches or ephemeral structures; locate and
edit the rule string "ALWAYS use a database — never in-memory arrays. SQLite
minimum." in .cursorrules and replace it with the clarified phrasing.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 8d77555c-c405-46d1-b02e-aa6ae1f35b12

📥 Commits

Reviewing files that changed from the base of the PR and between fc2ce04 and b397f88.

📒 Files selected for processing (2)
  • README.md
  • rules/shipworthy-production-guardrails/.cursorrules

- Move Shipworthy entry to correct alphabetical position (after Next.js Type LLM, before Unity)
- Clarify database rule to scope it to persistent data only

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Vimalk0703
Copy link
Copy Markdown
Author

Thanks for the review @coderabbitai! Both items have been fixed:

  1. Alphabetical ordering — Moved the Shipworthy entry to the correct position (after "Next.js (Type LLM)", before "Unity (C#)")
  2. Database rule clarification — Updated to "ALWAYS use a database for persistent data" to avoid blocking legitimate in-memory caching

See commit 6b57b8a.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 31, 2026

Tip

For best results, initiate chat on the files or code changes.

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check alphabetical ordering around the Shipworthy entry in README.md
grep -n -i "shipworthy\|next.js (type llm)\|unity (c#)" README.md

echo "---"

# Check the database rule in the .cursorrules file
grep -n -i "database\|always use" rules/shipworthy-production-guardrails/.cursorrules

Length of output: 953


@Vimalk0703 Both fixes are confirmed in the current state of the branch! ✅

  1. Alphabetical ordering — The entry sits correctly between Next.js (Type LLM) (line 276) and Unity (C#) (line 278). ✓
  2. Database rule clarification — Line 15 of the .cursorrules file now reads "ALWAYS use a database for persistent data — never in-memory arrays. SQLite minimum."

Thanks for addressing these promptly!


If you found this review helpful, would you consider giving us a shout-out on X?

Thank you for using CodeRabbit!

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