Skip to content

Conversation

areibman
Copy link
Contributor

📥 Pull Request

📘 Description
Resolves an AttributeError that occurred when agentops.trace was incorrectly used as a context manager. This PR clarifies the distinction between agentops.trace (a decorator) and agentops.start_trace() (the function to use for context manager functionality).

Includes:

  • A new AGENTOPS_TRACE_USAGE_GUIDE.md explaining the correct usage of AgentOps tracing methods.
  • A fixed_example.py demonstrating all valid ways to use AgentOps tracing, including start_trace() as a context manager.

🧪 Testing
The fixed_example.py was created and executed successfully, demonstrating that agentops.start_trace() correctly functions as a context manager and that other tracing methods (manual start/end, decorators) work as intended without errors.


Open in Cursor Open in Web

Copy link

cursor bot commented Aug 15, 2025

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

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

Successfully merging this pull request may close these issues.

2 participants