Output from azd version
N/A — found by code inspection on main.
Describe the bug
When the azure.ai.agents extension can't resolve a Foundry project endpoint, it returns a missing_project_endpoint error whose suggestion tells the user to run:
azd ai agent project set <endpoint>
That command no longer exists. It was moved to the azure.ai.projects extension as azd ai project set. The agents extension's own code acknowledges the removal — internal/cmd/project_context_store.go:18-19 describes projectContextConfigPath as "the legacy UserConfig path used by the removed azd ai agent project set command" — but the user-facing suggestion string was never updated.
Source: cli/azd/extensions/azure.ai.agents/internal/cmd/project_endpoint.go:126-134
func noProjectEndpointError() error {
return exterrors.Dependency(
exterrors.CodeMissingProjectEndpoint,
"no Foundry project endpoint resolved",
"persist a workspace default with `azd ai agent project set <endpoint>`, "+
"or set FOUNDRY_PROJECT_ENDPOINT in the active azd environment, "+
"or export FOUNDRY_PROJECT_ENDPOINT in your shell",
)
}
This looks like a missed spot when the command moved. Every other extension emitting the same suggestion already has the correct text:
| File |
Suggested command |
azure.ai.projects/internal/cmd/project_endpoint.go:135 |
azd ai project set ✅ |
azure.ai.connections/internal/foundry/projectctx/validator.go:108 |
azd ai project set ✅ |
azure.ai.toolboxes/internal/foundry/projectctx/validator.go:108 |
azd ai project set ✅ |
azure.ai.skills/internal/cmd/endpoint.go:191 |
azd ai project set ✅ |
azure.ai.agents/internal/cmd/project_endpoint.go:130 |
azd ai agent project set ❌ |
To Reproduce
- Install the
azure.ai.agents extension.
- Make sure no project endpoint can be resolved — no
FOUNDRY_PROJECT_ENDPOINT in the active azd environment or shell, and no persisted workspace default.
- Run an agents command that resolves the project endpoint (for example
azd ai agent eval without --project-endpoint).
- Read the suggestion in the error output and run the command it names.
Expected behavior
The suggestion names a command that exists, so copy-pasting it works:
persist a workspace default with `azd ai project set <endpoint>`, or set
FOUNDRY_PROJECT_ENDPOINT in the active azd environment, or export
FOUNDRY_PROJECT_ENDPOINT in your shell
Actual behavior
The suggestion names the removed azd ai agent project set. A user who follows it hits an unknown-command error and has no working path forward from that message.
Why this matters
missing_project_endpoint is part of the largest Invalid Input bucket on azd deploy for agent services ("required project or environment configuration is missing", ~1.4% of deploys). The suggestion string is the main recovery path we give users for that failure, so pointing it at a removed command turns a recoverable error into a dead end.
Environment
N/A — affects all platforms.
Additional context
Fix is a one-line change to the suggestion string in noProjectEndpointError(), matching the wording already used by the other four extensions. project_endpoint_test.go:99-108 covers the error code and category but not the suggestion text, so a short assertion on the suggestion would keep the five copies from drifting again.
Output from
azd versionN/A — found by code inspection on
main.Describe the bug
When the
azure.ai.agentsextension can't resolve a Foundry project endpoint, it returns amissing_project_endpointerror whose suggestion tells the user to run:That command no longer exists. It was moved to the
azure.ai.projectsextension asazd ai project set. The agents extension's own code acknowledges the removal —internal/cmd/project_context_store.go:18-19describesprojectContextConfigPathas "the legacy UserConfig path used by the removedazd ai agent project setcommand" — but the user-facing suggestion string was never updated.Source:
cli/azd/extensions/azure.ai.agents/internal/cmd/project_endpoint.go:126-134This looks like a missed spot when the command moved. Every other extension emitting the same suggestion already has the correct text:
azure.ai.projects/internal/cmd/project_endpoint.go:135azd ai project set✅azure.ai.connections/internal/foundry/projectctx/validator.go:108azd ai project set✅azure.ai.toolboxes/internal/foundry/projectctx/validator.go:108azd ai project set✅azure.ai.skills/internal/cmd/endpoint.go:191azd ai project set✅azure.ai.agents/internal/cmd/project_endpoint.go:130azd ai agent project set❌To Reproduce
azure.ai.agentsextension.FOUNDRY_PROJECT_ENDPOINTin the active azd environment or shell, and no persisted workspace default.azd ai agent evalwithout--project-endpoint).Expected behavior
The suggestion names a command that exists, so copy-pasting it works:
Actual behavior
The suggestion names the removed
azd ai agent project set. A user who follows it hits an unknown-command error and has no working path forward from that message.Why this matters
missing_project_endpointis part of the largest Invalid Input bucket onazd deployfor agent services ("required project or environment configuration is missing", ~1.4% of deploys). The suggestion string is the main recovery path we give users for that failure, so pointing it at a removed command turns a recoverable error into a dead end.Environment
N/A — affects all platforms.
Additional context
Fix is a one-line change to the suggestion string in
noProjectEndpointError(), matching the wording already used by the other four extensions.project_endpoint_test.go:99-108covers the error code and category but not the suggestion text, so a short assertion on the suggestion would keep the five copies from drifting again.