Skip to content

feat(config): add explicit validation for required configuration fields#2078

Open
Sourish-07 wants to merge 5 commits into
microsoft:mainfrom
Sourish-07:improve-config-validation
Open

feat(config): add explicit validation for required configuration fields#2078
Sourish-07 wants to merge 5 commits into
microsoft:mainfrom
Sourish-07:improve-config-validation

Conversation

@Sourish-07
Copy link
Copy Markdown

What changed

This PR adds explicit validation to the Config class to surface missing required configuration fields early, with clear error messages.

Why

Currently, missing core fields such as provider_uri or region can lead to unclear runtime errors later in the execution flow. This change fails fast and makes misconfiguration easier to diagnose.

What’s included

  • A new Config.validate() method that checks required fields
  • A focused unit test validating the behavior for missing provider_uri

Notes

Some tests depend on optional development packages (e.g. tqdm), so local test collection may fail on a minimal setup. CI should be used to verify test results.

@Sourish-07
Copy link
Copy Markdown
Author

@microsoft-github-policy-service agree

@SunsetWolf
Copy link
Copy Markdown
Collaborator

Hi, @Sourish-07 , Thanks for the contribution! The CI checks are currently failing due to code formatting issues.
Could you please adjust the formatting and update the PR so that all CI checks pass?

@Sourish-07 Sourish-07 force-pushed the improve-config-validation branch from 76a14bc to 3dc0db7 Compare January 8, 2026 21:22
@Sourish-07
Copy link
Copy Markdown
Author

Hi, I’ve rebased the branch onto the latest upstream main, cleaned up the formatting issues, and updated the validation logic to respect skip_register. The changes are now pushed to the PR. Please let me know if there are any other changes required.

@Sourish-07 Sourish-07 force-pushed the improve-config-validation branch from 3dc0db7 to c43be31 Compare January 25, 2026 23:42
@Sourish-07
Copy link
Copy Markdown
Author

Hi @SunsetWolf, CI is passing and the requested changes are in. Could you take a quick look and merge if it looks good?
Thanks you.

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