Skip to content

fix(guard-core): include app/ in core scope envelope#24

Merged
cursor[bot] merged 1 commit into
mainfrom
cursor/core-app-envelope-3083
Jul 17, 2026
Merged

fix(guard-core): include app/ in core scope envelope#24
cursor[bot] merged 1 commit into
mainfrom
cursor/core-app-envelope-3083

Conversation

@kaizencycle

Copy link
Copy Markdown
Owner

Summary

Adds app/ to the EPICON core scope envelope so Next.js App Router repositories (e.g. mobius-civic-ai-terminal) do not trigger I4 divergence warnings when declaring scope: core.

Motivation

Terminal PR #627 changes app/api/vault/status/route.ts and lib/vault-v2/store.ts. The core envelope previously listed apps/ (monorepo layout) but not app/ (App Router), causing a false I4 warning on every App Router route change.

Changes

  • packages/guard-core/src/intent.mjs — add app/ prefix to core envelope
  • packages/guard-core/test/envelope.test.mjs — regression tests for App Router paths

Tests

cd packages/guard-core && npm test

All 8 tests pass.

Release note

After merge, move the v1 action tag to this commit so consumers of kaizencycle/epicon@v1 pick up the fix.

Open in Web Open in Cursor 

Next.js App Router repos use app/ rather than apps/. Without this prefix,
core-scoped intents on terminal routes trigger I4 divergence warnings.

Co-authored-by: michaeljjudan <[email protected]>
@cursor

cursor Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

@cursor
cursor Bot merged commit 4b5849f into main Jul 17, 2026
1 check failed
@cursor
cursor Bot deleted the cursor/core-app-envelope-3083 branch July 17, 2026 15:51

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 41be1f601c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

docs: ['docs/', 'README', 'DOCS.md', 'CONTRIBUTING.md', 'LICENSE', 'FOR-'],
ci: ['.github/'],
core: ['apps/', 'packages/', 'src/', 'lib/'],
core: ['app/', 'apps/', 'packages/', 'src/', 'lib/'],

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Add app/ to the default tier policy**

When changed-file analysis runs with the built-in policy, an App Router path such as app/api/vault/status/route.ts is now accepted by the core envelope here, but DEFAULT_POLICY still lacks an app/** EP-2 rule, so classifyFile(DEFAULT_POLICY, ...) falls through to Rule 5.2 as EP-3. In default-policy repositories this leaves scope: core App Router PRs deny-by-default tiered, and any intent validation error makes them fail-closed even though the divergence warning was removed.

Useful? React with 👍 / 👎.

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.

2 participants