Skip to content

DO NOT MERGE: #865 test#867

Closed
rekmarks wants to merge 4 commits intomainfrom
temp/constraints-test
Closed

DO NOT MERGE: #865 test#867
rekmarks wants to merge 4 commits intomainfrom
temp/constraints-test

Conversation

@rekmarks
Copy link
Member

@rekmarks rekmarks commented Mar 4, 2026

No description provided.

rekmarks and others added 4 commits March 3, 2026 16:08
…ction deps

Add a yarn constraint that errors when a published (`@metamask/`) package
lists a private (`@ocap/`) workspace package in production dependencies
(`dependencies` or `peerDependencies`) via the `workspace:` protocol.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
github-merge-queue bot pushed a commit that referenced this pull request Mar 4, 2026
…ction deps (#865)

## Summary
- Add a yarn constraint that prevents published (`@metamask/`) packages
from listing private (i.e., practically speaking, `@ocap/`) workspace
packages in production dependencies (`dependencies` or
`peerDependencies`) via the `workspace:` protocol
- No current violations exist; this is a guardrail against future
mistakes

## Test plan
- [x] `yarn constraints` passes with no errors
- [x] Temporarily add a private `@ocap/` package to a public package's
`dependencies` with `workspace:^` and verify the constraint catches it:
see #867

🤖 Generated with [Claude Code](https://claude.com/claude-code)


<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Low Risk**
> Low risk: adds a Yarn constraints guardrail only, and it triggers only
on invalid dependency declarations for published packages.
> 
> **Overview**
> Adds a new Yarn constraint that **fails `yarn constraints`** when a
non-private (published) workspace declares a `workspace:` protocol
dependency on a private workspace in production dependency sections
(anything other than `devDependencies`, e.g.
`dependencies`/`peerDependencies`).
> 
> Implements `expectNoPrivateWorkspaceProductionDependencies` and runs
it for all non-private child workspaces, emitting a clear error message
naming the offending package and dependency type.
> 
> <sup>Written by [Cursor
Bugbot](https://cursor.com/dashboard?tab=bugbot) for commit
782e72c. This will update automatically
on new commits. Configure
[here](https://cursor.com/dashboard?tab=bugbot).</sup>
<!-- /CURSOR_SUMMARY -->

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
@rekmarks rekmarks closed this Mar 4, 2026
@rekmarks rekmarks deleted the temp/constraints-test branch March 4, 2026 01:36
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