Skip to content

fix: updated roleDefinitionIdOrName to use GUID and fixed CodeQL issue.#963

Merged
Roopan-Microsoft merged 2 commits into
microsoft:devfrom
vishalsvs7:dev
Jun 16, 2026
Merged

fix: updated roleDefinitionIdOrName to use GUID and fixed CodeQL issue.#963
Roopan-Microsoft merged 2 commits into
microsoft:devfrom
vishalsvs7:dev

Conversation

@vishalsvs7

Copy link
Copy Markdown
Contributor

Purpose

  • Updated the roleDefinitionIdOrName field to use the role definition's GUID instead of the role name.
  • Ensures consistent and unambiguous role identification across environments.
  • Reduces dependency on role name resolution and avoids issues caused by role renames or localization.
  • Improves reliability of role assignment and authorization-related operations.

Does this introduce a breaking change?

  • Yes
  • No

Golden Path Validation

  • I have tested the primary workflows (the "golden path") to ensure they function correctly without errors.

Deployment Validation

  • I have validated the deployment process successfully and all services are running as expected with this change.

What to Check

Verify that the following are valid

  • ...

Other Information

Copilot AI 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.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Updates the chat service’s side-effect patch import and refreshes infrastructure templates, including switching Storage role assignments to fixed role definition GUIDs and regenerating the ARM JSON output.

Changes:

  • Adjusted Python patch import style and added/updated linter suppression comments in the patch module.
  • Replaced Storage RBAC role names with role definition GUIDs in Bicep templates.
  • Regenerated infra/main.json (new Bicep generator version, updated template hash, and some formatting/order-only diffs).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
src/api/services/chat_service.py Changes how the patch module is imported for side effects.
src/api/services/_patches/agent_framework_search_citations.py Updates comments/noqa annotations around patch application state.
infra/main.bicep Uses RBAC role definition GUIDs instead of role names for storage role assignments.
infra/main_custom.bicep Same RBAC role GUID update as main.bicep.
infra/main.json Regenerated ARM template output (generator version/hash, formatting, and some ordering changes).
Comments suppressed due to low confidence (2)

infra/main.json:1

  • This introduces CRLF (\\r\\n) line endings inside a JSON string where previously it was LF (\\n). That tends to create noisy cross-platform diffs and can cause unexpected downstream string comparisons. Consider regenerating with consistent LF output and/or enforcing .gitattributes (e.g., *.json text eol=lf) so generated templates remain stable across environments.
    infra/main.json:1
  • The generated template now reflects a newer Bicep compiler version. If CI/CD or dev tooling expects a pinned Bicep version for reproducible main.json generation, consider updating the pinned version/documentation (or the build pipeline) to match this change to avoid future drift and PR churn.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/api/services/chat_service.py Outdated
Comment thread src/api/services/_patches/agent_framework_search_citations.py Outdated
Comment thread src/api/services/_patches/agent_framework_search_citations.py Outdated
Comment thread infra/main.bicep
Comment thread infra/main.bicep
Comment thread infra/main.bicep
Comment thread infra/main_custom.bicep
Comment thread infra/main_custom.bicep
Comment thread infra/main_custom.bicep
@vishalsvs7 vishalsvs7 changed the title fix: updated roleDefinitionIdOrName to use GUID fix: updated roleDefinitionIdOrName to use GUID and fixed CodeQL issue. Jun 16, 2026
@vishalsvs7

Copy link
Copy Markdown
Contributor Author

@microsoft-github-policy-service agree

@Roopan-Microsoft Roopan-Microsoft merged commit eab7705 into microsoft:dev Jun 16, 2026
6 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 3.23.3 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants