Skip to content

Commit 684e5f6

Browse files
authored
Update responses.md
Missing time import for sleep() function. Corrected "resp.status" to "response.status"
1 parent da295cd commit 684e5f6

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

articles/ai-services/openai/how-to/responses.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -929,6 +929,7 @@ curl GET https://YOUR-RESOURCE-NAME.openai.azure.com/openai/v1/responses/resp_12
929929
```python
930930
from openai import AzureOpenAI
931931
from azure.identity import DefaultAzureCredential, get_bearer_token_provider
932+
from time import sleep
932933

933934
token_provider = get_bearer_token_provider(
934935
DefaultAzureCredential(), "https://cognitiveservices.azure.com/.default"
@@ -947,7 +948,7 @@ response = client.responses.create(
947948
)
948949

949950
while response.status in {"queued", "in_progress"}:
950-
print(f"Current status: {resp.status}")
951+
print(f"Current status: {response.status}")
951952
sleep(2)
952953
response = client.responses.retrieve(response.id)
953954

@@ -1293,4 +1294,4 @@ For examples of how to use reasoning models with the responses API see the [reas
12931294

12941295
## Computer use
12951296

1296-
Computer use with Playwright has moved to the [dedicated computer use model guide](./computer-use.md#playwright-integration)
1297+
Computer use with Playwright has moved to the [dedicated computer use model guide](./computer-use.md#playwright-integration)

0 commit comments

Comments
 (0)