Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure AI Projects: Async function send_email_async is not called #38898

Closed
jhakulin opened this issue Dec 16, 2024 · 3 comments
Closed

Azure AI Projects: Async function send_email_async is not called #38898

jhakulin opened this issue Dec 16, 2024 · 3 comments
Assignees
Labels
AI Service Attention Workflow: This issue is responsible by Azure service team.

Comments

@jhakulin
Copy link
Member

  • Package Name: azure-ai-projects
  • Package Version: 1.0.0b3
  • Operating System: Windows
  • Python Version: 3.12.8

Describe the bug
When I run this sample https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/ai/azure-ai-projects/samples/agents/async_samples/sample_agents_stream_eventhandler_with_functions_async.py, the send_email_async is not called.

To Reproduce
Steps to reproduce the behavior:

  1. Run the sample

Expected behavior
send_email_async will be called as that is needed for user query in the sample

Screenshots
If applicable, add screenshots to help explain your problem.

Additional context
The problem can be avoided if I add following docstrings to the send_email_async method

async def send_email_async(recipient: str, subject: str, body: str) -> str:
    """
    Sends an email with the specified subject and body to the recipient.

    :param recipient (str): Email address of the recipient.
    :param subject (str): Subject of the email.
    :param body (str): Body content of the email.
    :return: Confirmation message.
    :rtype: str
    """
    await asyncio.sleep(1)
    return send_email(recipient, subject, body)

After that agent will know more details about the function and knows to call it successfully.

@github-actions github-actions bot added the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Dec 16, 2024
@pvaneck pvaneck added Service Attention Workflow: This issue is responsible by Azure service team. AI labels Dec 17, 2024
@github-actions github-actions bot removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Dec 17, 2024
Copy link

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @achauhan-scc @kingernupur @luigiw @needuv @paulshealy1 @singankit.

@jhakulin
Copy link
Member Author

This will be fixed in 1.0.0b4 version soon.

@jhakulin
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AI Service Attention Workflow: This issue is responsible by Azure service team.
Projects
None yet
Development

No branches or pull requests

3 participants