Skip to content

fix: accept managed identity App Insights connections - #420

Merged
Paulo Lacerda (placerda) merged 1 commit into
developfrom
placerda-fix-foundry-preflight
Aug 14, 2026
Merged

fix: accept managed identity App Insights connections#420
Paulo Lacerda (placerda) merged 1 commit into
developfrom
placerda-fix-foundry-preflight

Conversation

@placerda

@placerda Paulo Lacerda (placerda) commented Aug 14, 2026

Copy link
Copy Markdown
Contributor

Summary

  • validate Microsoft Foundry project reachability without requesting connected-resource credentials
  • accept Application Insights connections that use ProjectManagedIdentity instead of API Key credentials
  • preserve explicit APPLICATIONINSIGHTS_CONNECTION_STRING precedence and accurate missing-connection diagnostics

Root cause

The Foundry pre-flight used AIProjectClient.telemetry.get_application_insights_connection_string() as its project reachability probe. That SDK helper intentionally raises ValueError("Application Insights connection does not use API Key credentials.") for a valid ProjectManagedIdentity connection, so AgentOps incorrectly reported the Foundry project as a warning.

Validation

  • python -m pytest tests\unit\test_foundry_discovery.py tests\unit\test_preflight.py -q (32 passed)
  • python -m pytest tests\ -x -q (1317 passed, 1 skipped)
  • python -m ruff check src\ tests\
  • python -m mypy src\agentops\ --ignore-missing-imports
  • python scripts\check_changelog.py check-pr --base origin/develop

Separate Foundry project reachability from Application Insights connection-string discovery so ProjectManagedIdentity connections do not produce false preflight warnings. Preserve explicit connection-string precedence and classify missing telemetry connections accurately.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@placerda
Paulo Lacerda (placerda) force-pushed the placerda-fix-foundry-preflight branch from 63b8bec to beadf68 Compare August 14, 2026 00:26
@placerda
Paulo Lacerda (placerda) merged commit 16825d0 into develop Aug 14, 2026
13 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.

1 participant