Skip to content

feat(api): stop calling references outside the caller's visibility dangling - #287

Open
yordis wants to merge 1 commit into
yordis/feat-read-path-truncationfrom
yordis/feat-ref-outside-visible-scope
Open

yordis wants to merge 1 commit into
yordis/feat-read-path-truncationfrom
yordis/feat-ref-outside-visible-scope

Conversation

@yordis

@yordis yordis commented Oct 31, 2026

Copy link
Copy Markdown
Member
  • A caller whose visibility omits a namespace validates against a snapshot without it, so every reference into that namespace was reported as dangling even when the target exists.
  • Those false errors pushed callers toward repairing references that were correct, and the error itself hinted at what the caller could not see.
  • Default chosen for review: a reference is classified as outside the visible scope by its target namespace alone, never by checking whether the target exists, so the finding reveals nothing about namespaces the caller cannot read.
  • Default chosen for review: the new finding is Info severity, so it neither blocks nor counts as a defect, and a caller with full visibility still sees the reference as dangling.

@coderabbitai

coderabbitai Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 55 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 433b7918-e976-4e82-adb9-6c7fe93ed09e
Commits

Reviewing files that changed from the base of the PR and between d14bcec and 5e4648a.

Files selected for processing: 4

  • docs/explanation/validation-coverage.md
  • docs/how-to/repair-validation-findings.md
  • rsworkspace/crates/trogon-atlas-server/src/service.rs
  • rsworkspace/crates/trogon-atlas-server/src/validation.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@cursor

cursor Bot commented Oct 31, 2026 •

Copy link
Copy Markdown

PR Summary

Medium Risk
Changes validation semantics for visibility-scoped callers across core validate paths, though behavior is constrained by lens-only checks and full-visibility paths stay equivalent to before.

Overview
Validation for ValidateEventModel and ValidateProject now runs through validate_model_within / validate_model_content_within, using the caller’s visibility lens so references into namespaces the snapshot omits are no longer reported as DANGLING_REF, MEMBER_NOT_FOUND, or UI_TRANSITION_DANGLING.

Those unresolved targets emit a new Info rule REF_OUTSIDE_VISIBLE_SCOPE: the target was not resolved, and the server does not probe whether it exists (only the target namespace vs. admitted namespaces). Callers with full visibility keep the previous dangling/missing behavior.

Docs cover the coverage story and tell repair workflows not to “fix” this finding by editing the reference—rerun validation with a key that can read the target namespace instead. Unit tests lock in cross-namespace vs. limited-lens classifications for members, outbound refs, and UI transitions.

Reviewed by Cursor Bugbot for commit 5e4648a. Bugbot is set up for automated code reviews on this repo. Configure here.

@cursor cursor 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.

Stale Bugbot comment from a previous run.

@cursor cursor 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.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 0423328. Configure here.

@yordis
yordis added this pull request to stack #383 November 14, 2026 12:06
Signed-off-by: Yordis Prieto <4237280+yordis@users.noreply.github.com>
@yordis
yordis force-pushed the yordis/feat-ref-outside-visible-scope branch from ffb1d1d to 5e4648a Compare November 14, 2026 13:50
@cursor

cursor Bot commented Nov 14, 2026

Copy link
Copy Markdown

Bugbot couldn't run - usage limit reached

Bugbot is counted against Cursor usage for this user or team, and this run hit a usage or spend limit.

A user or team admin can review and increase usage limits in the Cursor dashboard.

(requestId: 7facfb8c-fa5c-4a5c-9e31-954de4251b3c)

This branch has not been deployed

No deployments
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