fix: use started_at (not created_at) in RLS test session INSERT
sessions table has started_at as the timestamp column, not created_at. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -328,16 +328,16 @@ async def session_row_ids(admin_conn):
|
||||
ai_session_a_id = str(uuid.uuid4())
|
||||
ai_session_b_id = str(uuid.uuid4())
|
||||
|
||||
# Insert sessions rows
|
||||
# Insert sessions rows (sessions uses started_at not created_at)
|
||||
await admin_conn.execute(f"""
|
||||
INSERT INTO sessions (
|
||||
id, tree_id, user_id, account_id, tree_snapshot,
|
||||
path_taken, decisions, custom_steps, created_at, updated_at
|
||||
path_taken, decisions, custom_steps, started_at
|
||||
) VALUES
|
||||
('{session_a_id}', '{tree_a_id}', '{user_a_id}', '{ACCOUNT_A_ID}',
|
||||
'[]'::jsonb, '[]'::jsonb, '[]'::jsonb, '[]'::jsonb, NOW(), NOW()),
|
||||
'[]'::jsonb, '[]'::jsonb, '[]'::jsonb, '[]'::jsonb, NOW()),
|
||||
('{session_b_id}', '{tree_b_id}', '{user_b_id}', '{ACCOUNT_B_ID}',
|
||||
'[]'::jsonb, '[]'::jsonb, '[]'::jsonb, '[]'::jsonb, NOW(), NOW())
|
||||
'[]'::jsonb, '[]'::jsonb, '[]'::jsonb, '[]'::jsonb, NOW())
|
||||
""")
|
||||
|
||||
# Insert ai_sessions rows
|
||||
|
||||
Reference in New Issue
Block a user