Azure / Azure/azure-sdk-for-python

mismatch of documentation and published SDK

Aperta
#44,659 1 commento 0 reazioni 1 assegnatario Rivendicata da @trrwilson Vedi su GitHub
AI Projects customer-reported needs-team-attention question Service Attention
Lingua principale
Python
Stelle
5.6k
Fork
3.4k
Merge medio
2g
PR unite (30g)
217

Descrizione

### Type of issue

Code doesn't work

### Description
Your default code generated by foundry playground:
```
from azure.ai.projects import AIProjectClient
from azure.identity import DefaultAzureCredential
from azure.ai.agents.models import ListSortOrder

project = AIProjectClient(
credential=DefaultAzureCredential(),
endpoint="XXXX"
)

agent = project.agents.get_agent("XXXX")
```

**does not work!**

your online documentation says it should, because the class should contain `agents` based on class `AgentsClient`, which should contain `get_agent()` but in reality

```
azure-ai-projects 2.0.0b3

.../azure/ai/projects/_client.py
```

```
class AIProjectClient: # pylint: disable=too-many-instance-attributes
"""AIProjectClient.

:ivar agents: AgentsOperations operations
:vartype agents: azure.ai.projects.operations.AgentsOperations
```

the `agents` is is type `AgentsOperations`!!!

**Publish SDK that you describe by documentation!**

### Page URL

https://learn.microsoft.com/en-us/python/api/azure-ai-agents/azure.ai.agents.agentsclient?view=azure-python

### Content source URL

https://github.com/MicrosoftDocs/azure-docs-sdk-python/blob/main/docs-ref-autogen/azure-ai-agents/azure.ai.agents.AgentsClient.yml

### Document Version Independent Id

219d0677-5c39-bff0-2d7c-73fb0644f32d

### Platform Id

d4f7ae69-d141-a3c6-cebd-91e3fbfc874e

### Article author

@lmazuel

### Metadata

* ID: 006496b9-3b86-c11a-7122-a0ef34a154b8
* PlatformId: d4f7ae69-d141-a3c6-cebd-91e3fbfc874e

Guida per i contributori

Apri la guida per i contributori

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.