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

Closure agent throws if it receives a message that it can't handle #4775

Open
rysweet opened this issue Dec 20, 2024 · 0 comments
Open

Closure agent throws if it receives a message that it can't handle #4775

rysweet opened this issue Dec 20, 2024 · 0 comments
Assignees
Milestone

Comments

@rysweet
Copy link
Collaborator

rysweet commented Dec 20, 2024

What happened?

"The issue (in 0.2) is just when you register a ClosureAgent with a given closure method and subscription, any published messages on the same sub will raise an exception if the ClosureAgent doesn't explicitly handle that message type.

https://microsoft.github.io/autogen/0.4.0.dev10/_modules/autogen_core/_closure_agent.html#ClosureAgent.on_message_impl
autogen_core._closure_agent — AutoGen

Our use case is that you have some process that completes asynchronously, so send_message isn't applicable, but you want to wait for the result of that process in a given function (vs. writing a handler for the result).

so effectively publish_and_wait

the issue with the closure agent is kind of unrelated, it's just annoying that it raises an exception on unhandled messages
"

What did you expect to happen?

politely log the message.

How can we reproduce it (as minimally and precisely as possible)?

send a message to closure agent to which it is not subscribed

AutoGen version

0.4dev2

Which package was this bug in

AgentChat

Model used

No response

Python version

No response

Operating system

No response

Any additional info you think would be helpful for fixing this bug

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants