File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed
contributing/samples/memory Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change 16
16
from datetime import datetime
17
17
from datetime import timedelta
18
18
from typing import cast
19
- import warnings
20
19
21
20
import agent
22
21
from dotenv import load_dotenv
26
25
from google .genai import types
27
26
28
27
load_dotenv (override = True )
29
- warnings .filterwarnings ('ignore' , category = UserWarning )
30
28
logs .log_to_tmp_folder ()
31
29
32
30
@@ -67,12 +65,12 @@ async def run_prompt(session: Session, new_message: str) -> Session:
67
65
68
66
return cast (
69
67
Session ,
70
- runner .session_service .get_session (
68
+ await runner .session_service .get_session (
71
69
app_name = app_name , user_id = user_id_1 , session_id = session .id
72
70
),
73
71
)
74
72
75
- session_1 = runner .session_service .create_session (
73
+ session_1 = await runner .session_service .create_session (
76
74
app_name = app_name , user_id = user_id_1
77
75
)
78
76
@@ -93,7 +91,7 @@ async def run_prompt(session: Session, new_message: str) -> Session:
93
91
await runner .memory_service .add_session_to_memory (session_1 )
94
92
print ('-------------------------------------------------------------------' )
95
93
96
- session_2 = runner .session_service .create_session (
94
+ session_2 = await runner .session_service .create_session (
97
95
app_name = app_name , user_id = user_id_1
98
96
)
99
97
print (f'----Session to use memory: { session_2 .id } ----------------------' )
You can’t perform that action at this time.
0 commit comments