Skip to content

Commit c64ac1c

Browse files
committed
bug: fix context access in openai-agents-sdk emoji and resolve tools
RunContextWrapper.context IS the CaseyDeps instance directly — unlike Pydantic AI's RunContext which has a .deps property. The incorrect .deps access raised AttributeError silently caught by the SDK.
1 parent 9db55bb commit c64ac1c

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

openai-agents-sdk/agent/tools/emoji_reaction.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ async def add_emoji_reaction(
3333
Args:
3434
emoji_name: The Slack emoji name without colons (e.g. 'tada', 'wrench', 'pray').
3535
"""
36-
deps = wrapper.context.deps
36+
deps = wrapper.context
3737

3838
# Skip ~15% of reactions to feel more natural
3939
if random.random() < 0.15:

openai-agents-sdk/agent/tools/mark_resolved.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ async def mark_resolved(
1414
Call this once when the issue is fully resolved — e.g. password reset
1515
complete, ticket created, problem fixed.
1616
"""
17-
deps = wrapper.context.deps
17+
deps = wrapper.context
1818

1919
try:
2020
deps.client.reactions_add(

0 commit comments

Comments
 (0)