Skip to content

Conversation

@tryuan99
Copy link
Member

Resolves #196. Once a launcher has terminated all of its assigned targets, it might get reassigned by the IADS to pursue some other launcher's targets. This causes it to then start launching carrier interceptors across the map. Ideally, launchers cannot be reassigned to new targets and rely on threat assignment only to receive new targets. See #196 for an example simulation configuration.

@tryuan99 tryuan99 requested a review from daniellovell January 28, 2026 06:46
@stacklane-pr-stack-visualizer
Copy link

stacklane-pr-stack-visualizer bot commented Jan 28, 2026

🧱 Stack PR · Base of stack (2 PRs total)

Stack Structure:

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces a mechanism to prevent launchers from being reassigned by adding an IsReassignable property. The implementation is mostly correct, but a refactoring in InterceptorBase.cs has introduced a critical bug. The new RequestReassignment method incorrectly uses this instead of the appropriate interceptor context in one of its call sites, which changes the reassignment logic. I've left detailed comments and suggestions to fix this issue by parameterizing the new method and updating its call sites.

@coderabbitai
Copy link

coderabbitai bot commented Jan 28, 2026

📝 Walkthrough

Walkthrough

This PR introduces a reassignment control mechanism for the IADS interceptor system. A new IsReassignable property is added to the IInterceptor interface with a default implementation of true in InterceptorBase, allowing regular interceptors to be reassigned. LauncherBase overrides this property to return false, preventing launchers from reassignment. The reassignment logic in InterceptorBase is refactored to route through a new private RequestReassignment helper method that gates reassignment requests based on the IsReassignable property. Additionally, a parameter in IADS.cs is renamed from interceptor to launcher for semantic clarity.

Estimated Code Review Effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested Reviewers

  • daniellovell
🚥 Pre-merge checks | ✅ 4 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 12.50% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly summarizes the main change: making launchers non-reassignable after completing their assigned targets.
Description check ✅ Passed The description directly relates to the changeset, explaining the problem (launchers being reassigned to other targets) and the solution (preventing reassignment for launchers).
Linked Issues check ✅ Passed The code changes implement the required fix by adding IsReassignable property and setting it to false for launchers, preventing them from being reassigned to pursue other launchers' targets as reported in issue #196.
Out of Scope Changes check ✅ Passed All changes are scoped to the reassignment functionality: renaming parameter for clarity, adding IsReassignable property to interface and implementations, and routing reassignment requests through a gating mechanism.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

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 and usage tips.

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.

[Assignment] Debug why DDG is firing to other swarm

2 participants