Skip to content

Redis key vault auth and 3 bug fixes#767

Open
Xeelee33 wants to merge 7 commits intomicrosoft:Developmentfrom
Xeelee33:feature/redis_keyvault_auth
Open

Redis key vault auth and 3 bug fixes#767
Xeelee33 wants to merge 7 commits intomicrosoft:Developmentfrom
Xeelee33:feature/redis_keyvault_auth

Conversation

@Xeelee33
Copy link
Contributor

@Xeelee33 Xeelee33 commented Mar 4, 2026

This pull requests adds 1 new feature and 3 bug fixes.

Feature - adds key vault secret authentication option for Redis
Commit: 3368d6e
Since authenticating to Redis via managed identity is not supported in Azure Gov (Confirmed in issue #696), added a Key Vault authentication option so Gov customers can utilize Redis session caching without storing plain text access keys in Cosmos. It builds off the existing Key Vault settings in the Security tab in Admin Settings. Unlike for agents, the secret name for Redis doesn't have any specific format restrictions.

image

Bug fix 1 - Resolved visible text being cut off and no horizontal scroll bars in blocks in message responses
Commit: 9823912
Resolved issue described in issue #719. Confirmed that all drop downs and expansion windows like message metadata details still function properly.
image

Bug fix 2 - Resolved invisible icons in New Prompt editor
Commit: e4157b6
Icons were missing in Create New Prompt editor in both light and dark mode due to the SimpleMDE toolbar in the editor using Front Awesome icons that don't exist in the project. Repointed the icons to the equivalent Bootstrap icons and made necessary adjustments for dark theme.

Before
image
image

After
image
image

Bugfix 3 - Resolved conversation details not loading for legacy conversations
Commit: 5c48426
The chat_type property being called in the conversation metadata query doesn't exist in legacy conversations, so clicking on the conversation details button on legacy conversations throws an error:
image

This commit just adds a default value of 'personal' to chat_type when it's called but returns no value. This same logic was previously added to the conversation search function (code snippet below is from current main branch):

for c in conversations:
# Default to 'personal' if chat_type is not defined (legacy conversations)
chat_type = c.get('chat_type', 'personal')
if chat_type in chat_types:
filtered_in.append(c)
else:
filtered_out.append(c)

After the fix, the conversation details window populates properly for legacy conversations:
image

…sation details load properly for legacy conversations
…s in overflowing message responses to function properly
…conflict, resolved for both light and dark mode themes.
@Xeelee33 Xeelee33 changed the title Feature/redis keyvault auth Redis key vault auth and 3 bug fixes Mar 4, 2026
@paullizer
Copy link
Contributor

Great additions and bug fixes!

@paullizer
Copy link
Contributor

@Xeelee33 did you want this as draft?

@Xeelee33 Xeelee33 marked this pull request as ready for review March 5, 2026 17:50
Copilot AI review requested due to automatic review settings March 5, 2026 17:50
@paullizer paullizer self-requested a review March 5, 2026 18:14
Copy link
Contributor

@paullizer paullizer left a comment

Choose a reason for hiding this comment

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

@Xeelee33 please update release_notes.md with the improvements and fixes, this makes it easier for us to share whats changed and document the improvements.

@Xeelee33
Copy link
Contributor Author

Xeelee33 commented Mar 5, 2026

@Xeelee33 please update release_notes.md with the improvements and fixes, this makes it easier for us to share whats changed and document the improvements.

Absolutely, I'll make the update shortly.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds a Key Vault–based Redis authentication mode (for Azure Gov compatibility) and includes UI/CSS and backend fixes for chat rendering, prompt editor icons, and legacy conversation metadata.

Changes:

  • Add Redis auth type key_vault and wire it through Admin Settings UI + test-connection flow.
  • Retrieve Redis secrets from Azure Key Vault for both session configuration and app cache setup.
  • Fix chat overflow behavior, SimpleMDE toolbar icons, and legacy conversation metadata defaulting.

Reviewed changes

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

Show a summary per file
File Description
application/single_app/templates/admin_settings.html Adds “Key Vault” auth option and updates Redis key label + hint text in Admin Settings.
application/single_app/static/js/admin/admin_settings.js Toggles Redis key UI for key-vault option and includes auth_type in Redis test payload.
application/single_app/static/css/styles.css Replaces missing Font Awesome toolbar icons with Bootstrap Icons and dark theme tweaks for SimpleMDE.
application/single_app/static/css/chats.css Changes message content overflow to allow horizontal scrolling in responses.
application/single_app/route_backend_settings.py Adds Key Vault secret retrieval path for Redis connection tests.
application/single_app/route_backend_conversations.py Defaults chat_type for legacy conversations to prevent details pane errors.
application/single_app/functions_keyvault.py Introduces retrieve_secret_direct() helper to fetch arbitrary Key Vault secret names.
application/single_app/app_settings_cache.py Adds Key Vault path to initialize Redis cache client using secrets.
application/single_app/app.py Adds Key Vault path to configure Flask sessions with Redis using secrets.

Xeelee33 and others added 2 commits March 5, 2026 11:49
Updating feature/redis_keyvault_auth branch with current Development branch to baseline release_notes.md for update
…uest & updated release_notes.md and version in config.py
Copilot AI review requested due to automatic review settings March 6, 2026 00:22
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 11 out of 11 changed files in this pull request and generated 7 comments.

Comments suppressed due to low confidence (1)

application/single_app/functions_keyvault.py:581

  • key_vault_identity defaults to an empty string in settings, but this code treats any non-None value as a client id. Passing managed_identity_client_id='' can break Key Vault auth when the intent is to use the system-assigned identity. Strip and check truthiness (e.g., if key_vault_identity and key_vault_identity.strip(): ... else ...).
    key_vault_identity = settings.get("key_vault_identity", None)
    if key_vault_identity is not None:
        credential = DefaultAzureCredential(managed_identity_client_id=key_vault_identity)
    else:
        credential = DefaultAzureCredential()

@Xeelee33 Xeelee33 requested a review from paullizer March 6, 2026 19:17
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.

3 participants