Skip to content

fix(cli): preserve Relayfile subscription path filters - #1486

Merged
khaliqgant merged 1 commit into
mainfrom
fix/1479-integration-subscribe-path-glob
Aug 12, 2026
Merged

fix(cli): preserve Relayfile subscription path filters#1486
khaliqgant merged 1 commit into
mainfrom
fix/1479-integration-subscribe-path-glob

Conversation

@khaliqgant

@khaliqgant khaliqgant commented Aug 11, 2026

Copy link
Copy Markdown
Member

Summary

  • serialize the Relayfile inbound target filter as path_glob, matching the Relaycast server contract
  • add a request-body regression test that rejects the previous camelCase field
  • document the scoped-delivery fix in the changelog

Verification

  • npm run typecheck
  • npm exec -- vitest run packages/cli/src/cli/commands/integration-subscribe.test.ts packages/cli/src/cli/commands/relaycast-groups.test.ts (78 passed)
  • focused ESLint (0 errors; existing warnings only)
  • Prettier check and git diff --check

Fixes #1479

Review in cubic

@cursor

cursor Bot commented Aug 11, 2026

Copy link
Copy Markdown

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.

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The integration subscribe payload now sends Relayfile path filters as path_glob. A regression test verifies the snake_case field and rejects the previous pathGlob key. The changelog records the fix.

Changes

Integration subscribe path filtering

Layer / File(s) Summary
Path filter wire contract
packages/cli/src/cli/commands/integration.ts, packages/cli/src/cli/commands/integration-subscribe.test.ts, CHANGELOG.md
The inbound-target request now uses path_glob. The integration subscribe test verifies the resolved resource path and confirms that pathGlob is absent. The changelog records the correction.

Estimated code review effort: 2 (Simple) | ~5 minutes

Possibly related PRs

Suggested reviewers: willwashburn

Poem

I’m a rabbit with a relay to send,
path_glob keeps filters on the mend.
No camelCase slips through the door,
Events stay within the requested shore.
Hop, test, and ship once more!

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and concisely describes the Relayfile subscription path-filter fix.
Description check ✅ Passed The description explains the fix and verification steps; the Verification section provides the required test-plan information.
Linked Issues check ✅ Passed The PR changes pathGlob to path_glob and adds a regression test, satisfying issue #1479.
Out of Scope Changes check ✅ Passed The code change, regression test, and changelog entry directly support the linked issue objectives.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/1479-integration-subscribe-path-glob

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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@CHANGELOG.md`:
- Line 18: Rename the changelog section heading from “## [Unreleased - Minor]”
to the required “## [Unreleased]”, leaving the existing entry unchanged.
🪄 Autofix

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: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 338cf22f-6b3e-4ced-90b5-0ff7773f2712

📥 Commits

Reviewing files that changed from the base of the PR and between ed8144c and d101b66.

📒 Files selected for processing (3)
  • CHANGELOG.md
  • packages/cli/src/cli/commands/integration-subscribe.test.ts
  • packages/cli/src/cli/commands/integration.ts

Comment thread CHANGELOG.md

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 3 files

Re-trigger cubic

@khaliqgant

Copy link
Copy Markdown
Member Author

Local CLI + production bridge E2E evidence (2026-08-11)

Using the CLI built from this branch:

  • integration subscribe github --resource AgentWorkforce/cloud-e2e-sandbox --to #relay1479-e2e-20260811 succeeded and persisted /github/repos/AgentWorkforce/cloud-e2e-sandbox/** with Relay webhook wh_213036829674524672 and Relayfile subscription whsub_f7b5ffd8-4d8d-42b8-b63a-9e9d00cb3474.
  • Relaycast re-resolved that exact target as path_glob=/github/repos/AgentWorkforce/cloud-e2e-sandbox/**.
  • A correctly signed in-scope event for /github/repos/AgentWorkforce/cloud-e2e-sandbox/issues/13/comments/5258739832.json returned 201 and created Relay message 213039894303350784.
  • A correctly signed out-of-scope event for /github/repos/AgentWorkforce/relay/issues/1479/comments/outside.json returned 200 with skipped=path_mismatch; the channel count remained unchanged.
  • A second /e2e/relay1479/** target independently produced message 213038828147421184, and its /e2e/relay1479-outside/** negative control was filtered.

The real GitHub comment canary did not enter Relayfile because the production GitHub provider feed is independently stale (lastEventAt=2026-08-03T07:26:26.334Z); the test comment and remote canary file were deleted.

Provisioning also exposed two prerequisite fixes:

All checks on this PR are green; review is the remaining GitHub gate.

@khaliqgant
khaliqgant merged commit b4a1a93 into main Aug 12, 2026
41 checks passed
@khaliqgant
khaliqgant deleted the fix/1479-integration-subscribe-path-glob branch August 12, 2026 06:30
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.

agent-relay integration subscribe sends pathGlob (camelCase) but server expects path_glob (snake_case)

1 participant