Skip to content

RG-T135 Fixing run error - #531

Merged
ucswift merged 1 commit into
masterfrom
develop
Sep 26, 2026
Merged

ucswift merged 1 commit into
masterfrom
develop

Conversation

@ucswift

@ucswift ucswift commented Sep 26, 2026 •

Copy link
Copy Markdown
Member

Summary

Fixed Autofac dependency injection so the Admin Assist catalog is initialized from its embedded documentation instead of being constructed with an empty document collection.

Changes

  • Made the ConfigurationCatalog(IEnumerable<string>) constructor private to prevent Autofac from selecting it automatically and supplying an empty IEnumerable<string>.
  • Added explicit validation for missing catalog documents with a clear error message.
  • Added an integration test verifying that the service container resolves an IAdminAssistCatalog containing settings from the embedded catalog documents.

Summary by CodeRabbit

  • Bug Fixes
    • Configuration validation now identifies empty configuration input as invalid before checking version consistency, making this failure easier to distinguish from version-related issues. Existing checks for nonblank versions and agreement between document versions remain unchanged.

@request-info

request-info Bot commented Sep 26, 2026

Copy link
Copy Markdown

Thanks for opening this, but we'd appreciate a little more information. Could you update it with more details?

@Resgrid-Bot

Resgrid-Bot commented Sep 26, 2026 •

Copy link
Copy Markdown

Kody Review Complete

Great news! 🎉
No issues were found that match your current review configurations.

Keep up the excellent work! 🚀

Kody Guide: Usage and Configuration
Interacting with Kody
  • Request a Review: Ask Kody to review your PR manually by adding a comment with the @kody start-review command at the root of your PR.

  • Validate Business Logic: Ask Kody to validate your code against business rules by adding a comment with the @kody -v business-logic command.

  • Provide Feedback: Help Kody learn and improve by reacting to its comments with a 👍 for helpful suggestions or a 👎 if improvements are needed.

Current Kody Configuration
Review Options

The following review options are enabled or disabled:

Options Enabled
Bug ✅
Performance ❌
Security ✅
Business Logic ❌

Access your configuration settings here.

​

@coderabbitai

coderabbitai Bot commented Sep 26, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: Resgrid/Core/.coderabbit.yaml

Review profile: CHILL

Plan: Essentials

Run ID: f692d904-da09-43ff-99af-9f4d4f3b61e9

📥 Commits

Reviewing files that changed from the base of the PR and between fb49c55 and 422711f.

⛔ Files ignored due to path filters (1)
  • Tests/Resgrid.Tests/AdminAssist/CatalogTests.cs is excluded by !**/Tests/**
📒 Files selected for processing (1)
  • Core/Resgrid.AdminAssist/ConfigurationCatalog.cs

Included review availability: This review used your included allowance. 2 included reviews remain after this review. Your included PR review attempts over the past 7 days set your current allowance at 3 reviews per hour. Your free on-demand review promotion remains active until October 9, 2026 at 6:00 PM UTC.


📝 Walkthrough

Walkthrough

The document-based ConfigurationCatalog constructor is now private. It rejects an empty document collection with InvalidDataException before validating document versions.

Changes

Configuration catalog validation

Layer / File(s) Summary
Constructor access and validation
Core/Resgrid.AdminAssist/ConfigurationCatalog.cs
The document-based constructor is private. It throws InvalidDataException for an empty collection before checking version agreement and nonblank versions.

Priority: ⬇️ Low

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

Change: Bug fix

Merge Risk: ⚪ Minimal · up to 42271

The catalog remains constructible through its public parameterless constructor and service registration, and the empty-input guard is in place. No merge-blocking risk was found.

🚥 Pre-merge checks | ✅ 3 | ❌ 1 | ❓ 1

❌ Failed checks (1 warning, 1 inconclusive)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 1 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
Title check ❓ Inconclusive The title indicates a run error fix, but it does not identify the configuration catalog or the constructor and validation changes. The title is too vague to describe the primary change clearly. Use a specific title, such as "Make ConfigurationCatalog document validation fail early".
✅ Passed checks (3 passed)
Check name Status Explanation
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.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Comment @coderabbitai help to get the list of available commands.

@ucswift
ucswift merged commit 1ffe728 into master Sep 26, 2026
19 checks passed
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