Skip to content

Commit

Permalink
revert session changes
Browse files Browse the repository at this point in the history
  • Loading branch information
areibman committed Oct 29, 2024
1 parent e1253cd commit b03c83e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions agentops/session.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,16 @@ def __init__(
"errors": 0,
"apis": 0,
}
self.is_running = False
active_sessions.append(self)
self.stop_flag = threading.Event()
self.thread = threading.Thread(target=self._run, args=(callback,))
self.thread.daemon = True
self.thread.start()

self.is_running = self._start_session()
if self.is_running == False:
self.stop_flag.set()
self.thread.join(timeout=1)

def set_video(self, video: str) -> None:
"""
Sets a url to the video recording of the session.
Expand Down

0 comments on commit b03c83e

Please sign in to comment.