microsoft-foundry / microsoft-foundry/foundry-samples

FilePurpose not imported in Python Quick Start

Open
#375 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Bicep
Stars
445
Forks
494
Avg merge
11h 35m
Merged PRs (30d)
38

Description

Hello all,

Issue:
I noticed FilePurpose module is not imported here and hence the script fails.

Resolution:
Import FilePurpose here like below.

from azure.ai.agents.models import ListSortOrder, FileSearchTool, FilePurpose

Regards,
Shibily

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open samples/microsoft/python/mslearn-resources/quickstart/quickstart.py and inspect the imports around line 70 and the FilePurpose usage near line 78. Add the missing import, then run the Python quickstart to confirm the script no longer fails with an undefined FilePurpose error.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure, python
Domain
api
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.