Skip to content

chore: Setup and installer maintenance now use explicit helper names#1595

Merged
hatayama merged 3 commits into
v3-betafrom
feature/hatayama/remove-overload-violations
Jul 7, 2026
Merged

chore: Setup and installer maintenance now use explicit helper names#1595
hatayama merged 3 commits into
v3-betafrom
feature/hatayama/remove-overload-violations

Conversation

@hatayama

@hatayama hatayama commented Jul 7, 2026

Copy link
Copy Markdown
Owner

Summary

  • Clarifies setup and installer maintenance helpers by replacing targeted internal overloads with explicit method names.
  • Adds a source guard so the R2-7 overload targets do not regress.

User Impact

  • No direct runtime behavior change is intended.
  • Future setup, skills, installer, and compile maintenance changes should be easier to review because helper variants now state their scope in the method name.

Changes

  • Removed the unused no-token compile wrapper and updated the debug compile example to pass CancellationToken.None explicitly.
  • Renamed internal skill-install detection helpers by any-layout and layout-specific scope while preserving public detector method names.
  • Split native installer command builders into remote-installer and package-path variants.
  • Added a targeted StaticFacadeStateGuardTests source guard for the R2-7 overload names, including missing-target detection.

Verification

  • dist/darwin-arm64/uloop compile --project-path <PROJECT_ROOT>
  • dist/darwin-arm64/uloop run-tests --project-path <PROJECT_ROOT> --test-mode EditMode --filter-type regex --filter-value "StaticFacadeStateGuardTests|SkillInstallLayoutTests|NativeCliInstallerTests"

Remove the no-token compile wrapper and rename R2-7 overload targets so each behavior variant has a distinct method name. Add a source guard to keep the targeted overloads from returning.
@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 75073b26-9863-4660-8ce5-26a3f62722c9

📥 Commits

Reviewing files that changed from the base of the PR and between 1a0ebe6 and 7145037.

📒 Files selected for processing (10)
  • Assets/Editor/CompileCheckWindow/CompileCheckerExample.cs
  • Assets/Tests/Editor/NativeCliInstallerTests.cs
  • Assets/Tests/Editor/SkillInstallLayoutTests.cs
  • Assets/Tests/Editor/StaticFacadeStateGuardTests.cs
  • Packages/src/Editor/FirstPartyTools/Compile/CompileController.cs
  • Packages/src/Editor/Infrastructure/CLI/NativeCliInstaller.cs
  • Packages/src/Editor/Infrastructure/SkillSetup/SkillInstallLayout.cs
  • Packages/src/Editor/Infrastructure/SkillSetup/SkillInstallationDetector.cs
  • Packages/src/Editor/Infrastructure/SkillSetup/SkillTargetDetector.cs
  • Packages/src/Editor/Presentation/UnityCliLoopSettingsWindow.cs
💤 Files with no reviewable changes (1)
  • Packages/src/Editor/FirstPartyTools/Compile/CompileController.cs

📝 Walkthrough

Walkthrough

This PR performs three independent internal refactors: CompileController.TryCompileAsync now requires an explicit CancellationToken (default overload removed), NativeCliInstaller splits install command building into remote and local-package-path variants, and skill installation detection APIs are renamed into layout-specific and any-layout helpers across SkillInstallLayout, SkillInstallationDetector, SkillTargetDetector, and the settings window. A new static-analysis guard test is added.

Changes

Editor Tooling Refactors

Layer / File(s) Summary
Compile with explicit CancellationToken
Packages/src/Editor/FirstPartyTools/Compile/CompileController.cs, Assets/Editor/CompileCheckWindow/CompileCheckerExample.cs
Removes the default TryCompileAsync(bool forceRecompile = false) overload; example window now passes ct: CancellationToken.None and reorganizes error/warning logging into typed loops.
Install command builder split
Packages/src/Editor/Infrastructure/CLI/NativeCliInstaller.cs, Assets/Tests/Editor/NativeCliInstallerTests.cs
Introduces BuildRemoteInstallCommand and BuildInstallCommandWithPackagePath, replacing the shared BuildInstallCommand; tests updated to call the appropriate new builder per scenario.
Layout-specific skill detection rename
Packages/src/Editor/Infrastructure/SkillSetup/SkillInstallLayout.cs, SkillInstallationDetector.cs, SkillTargetDetector.cs, Assets/Tests/Editor/SkillInstallLayoutTests.cs
Replaces HasInstalledSkills/AreSkillsInstalled overloads with HasInstalledSkillsInAnyLayout/HasInstalledSkillsForLayout and AreSkillsInstalledInAnyLayout/AreSkillsInstalledForLayout; updates all call sites and tests.
Settings window install-state helper split
Packages/src/Editor/Presentation/UnityCliLoopSettingsWindow.cs
Splits GetSelectedTargetInstallState into GetSelectedTargetInstallStateForCurrentProject and GetSelectedTargetInstallStateAtProjectRoot, updating fast and background refresh call sites.
Static facade overload guard test
Assets/Tests/Editor/StaticFacadeStateGuardTests.cs
Adds OverloadGuardMethodsByPath mapping and a new test using FindTargetedOverloadViolations to regex-scan for disallowed overload re-declarations.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title is concise and accurately reflects the main refactor toward explicit helper names for setup and installer maintenance.
Description check ✅ Passed The description matches the changeset and summarizes the refactors, helper splits, and guard addition accurately.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ 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 feature/hatayama/remove-overload-violations

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.

@cubic-dev-ai cubic-dev-ai 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.

1 issue found across 10 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="Packages/src/Editor/Infrastructure/CLI/NativeCliInstaller.cs">

<violation number="1" location="Packages/src/Editor/Infrastructure/CLI/NativeCliInstaller.cs:39">
P3: The R2-7 overload guard in `StaticFacadeStateGuardTests.cs` still references the old method name `"BuildInstallCommand"` for `NativeCliInstaller.cs`. Since the methods were renamed to `BuildRemoteInstallCommand` and `BuildInstallCommandWithPackagePath`, the guard now silently passes without checking anything for this file — it searches for a method that no longer exists. Consider updating the guard entry to track the new method names so the test continues to protect against overload regressions.</violation>
</file>

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread Packages/src/Editor/Infrastructure/CLI/NativeCliInstaller.cs
Track the renamed R2-7 helper methods and fail the guard when a configured target disappears, preventing silent pass-through after future renames.
Keep the public SkillInstallationDetector overloads stable while retaining explicit internal helpers for the R2-7 overload cleanup.
@hatayama
hatayama merged commit a2f8778 into v3-beta Jul 7, 2026
10 checks passed
@hatayama
hatayama deleted the feature/hatayama/remove-overload-violations branch July 7, 2026 14:48
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