workspace-package-not-found-run-pnpm-install

workspace-package-not-found-run-pnpm-install is a cursor rule for Cursor from prisma/orm. It costs 254 tokens per session, scanned A, original, Apache-2.0.

A troubleshooting rule for missing internal workspace packages in a pnpm monorepo. A monorepo is one repository containing multiple related packages, and pnpm links those packages separately for each consumer.

In plain words
What is it for?
It is for diagnosing missing @internal packages after dependency changes, merges, rebases, pulls, or stale build output.
Why use it?
It separates installation or stale-build problems from actual code bugs and gives the correct order for checking links, rebuilding, or reinstalling.

Cursor rule for Cursor ✓ vendor

Written for Cursor: a Cursor rule (.mdc). Also seen: installed under .agents/ (shared by several agents).

Good fit It is for diagnosing missing @internal packages after dependency changes, merges, rebases, pulls, or stale build output.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/prisma/orm/workspace-package-not-found-run-pnpm-install
About the project

Prisma ORM is a Node.js and TypeScript database toolkit that lets applications work with databases through a programming interface instead of writing every query directly in SQL. Developers use it with databases including PostgreSQL, MySQL, MariaDB, SQL Server, SQLite, MongoDB, and CockroachDB. The catalogue add-ons provide agent rules, skills, hooks, agents, and other workflows for using Prisma.

prisma/orm · 47,608 stars · on GitHub · prisma.io

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/prisma/orm

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for workspace-package-not-found-run-pnpm-install

README.md
[![agentmods](https://agentmods.dev/badge/rules/prisma/orm/workspace-package-not-found-run-pnpm-install.svg)](https://agentmods.dev/rules/prisma/orm/workspace-package-not-found-run-pnpm-install)
Your own site
<a href="https://agentmods.dev/rules/prisma/orm/workspace-package-not-found-run-pnpm-install"><img src="https://agentmods.dev/badge/rules/prisma/orm/workspace-package-not-found-run-pnpm-install.svg" alt="Measured on agentmods" height="20"></a>
Per session 254 This file is loaded in full into every session.
When invoked 254 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00254 $0.00254
Opus 5 $0.00127 $0.00127
Sonnet 5 $0.00051 $0.00051
Haiku 4.5 $0.00025 $0.00025

Measured 4d ago against content hash 23beddb5c50b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

workspace-package-not-found-run-pnpm-install scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.agents/rules/workspace-package-not-found-run-pnpm-install.mdc · 16 lines

What it actually says

A missing @internal/* package is a build/install state issue, not a code bug

Don't chase it as an import/tsconfig/deps bug.

  1. Verify — a repo-root check lies. pnpm links workspace packages into the consumer's node_modules: node -e "require.resolve('@internal/<pkg>', { paths: ['packages/<consumer-dir>'] })".
  2. Resolves but still fails → stale dist (tsdown packages export dist/): run pnpm build.
  3. Unresolved → new dep: run pnpm install (commit the lockfile; never hand-edit it).

After any git merge/rebase/pull, run pnpm install && pnpm build before calling a "module not found" or test failure a real regression.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 4d ago First seen · 16 lines · 254 tokens per session scan A 23beddb5c50b

Subscribe to this mod's changes

workspace-package-not-found-run-pnpm-install is a cursor rule published in the GitHub repository prisma/orm (47,608 stars, last pushed 5d ago), licensed Apache-2.0. It adds 254 tokens to every session, about $0.0013 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.