kshitijk4poor
a557e6ede8
fix(api): let POST /api/sessions titles yield to ended empty ghosts
...
Gate r1 2c finding (same bug class as #81888 ): _handle_create_session ran
its own "SELECT id FROM sessions WHERE title = ?" and 400'd whenever any
row held the title, so creating a session named after an abandoned empty
chat still failed even though renaming to that name now succeeds.
Extract the conflict block of _set_session_title into
SessionTitlesMixin._resolve_title_conflict(conn, session_id, title) and
call it from both the rename path and the API create transaction, so the
uniqueness rule (compression ancestor transfer, retired Bot Chat, ended
empty visible ghost, otherwise ValueError) lives in one place. On
ValueError the create still deletes its just-inserted row and returns
400 invalid_title; the message is now the DB's "Title 'X' is already in
use by session Y". A brand-new session has no compression ancestors, so
that branch is a no-op on create. api_server.py net growth is 0.
2026-10-03 23:03:42 +05:30
..
2026-10-03 20:50:15 +05:30
2026-09-24 16:04:05 +05:30
2026-09-26 07:21:49 +05:30
2026-09-27 22:04:26 -07:00
2026-09-28 07:29:40 +00:00
2026-09-25 13:49:31 -05:00
2026-09-29 16:30:33 -04:00
2026-09-29 15:58:55 +05:30
2026-09-29 15:58:55 +05:30
2026-09-25 21:30:22 +05:30
2026-09-25 14:27:23 +05:30
2026-09-26 21:39:31 -05:00
2026-09-29 15:58:55 +05:30
2026-09-29 15:57:52 -05:00
2026-09-27 06:54:56 -05:00
2026-09-26 21:45:17 -04:00
2026-09-27 00:37:26 +05:30
2026-09-24 21:27:59 +05:30
2026-10-02 21:54:45 -04:00
2026-09-26 07:21:49 +05:30
2026-09-27 20:44:38 +05:30
2026-09-28 05:24:26 -07:00
2026-09-26 19:37:13 +05:30
2026-10-02 00:46:21 +05:30
2026-09-24 22:30:59 +05:30
2026-09-25 14:27:23 +05:30
2026-09-25 14:27:23 +05:30
2026-09-24 01:55:51 -04:00
2026-10-01 22:47:04 -07:00
2026-09-29 18:33:44 +05:30
2026-09-29 18:33:44 +05:30
2026-09-29 18:33:44 +05:30
2026-09-23 14:55:08 -07:00
2026-10-02 02:42:14 -07:00
2026-10-03 18:22:19 +05:30
2026-09-24 02:03:59 -04:00
2026-09-30 20:10:03 -04:00
2026-09-25 14:15:22 -04:00
2026-09-26 22:30:35 -05:00
2026-09-23 10:45:57 -07:00
2026-10-01 12:27:27 -07:00
2026-09-24 22:29:59 +05:30
2026-09-27 01:34:15 +05:30
2026-10-03 16:37:12 +05:30
2026-09-26 07:21:49 +05:30
2026-10-03 16:37:12 +05:30
2026-09-24 08:51:52 -04:00
2026-10-03 20:54:04 +05:30
2026-10-03 20:54:04 +05:30
2026-10-03 20:54:04 +05:30
2026-09-27 01:05:06 +05:30
2026-10-02 04:14:45 -07:00
2026-10-01 22:47:04 -07:00
2026-09-28 14:16:18 -07:00
2026-09-23 16:55:09 -04:00
2026-09-24 13:10:14 -04:00
2026-09-29 07:44:13 +00:00
2026-09-25 14:15:22 -04:00
2026-09-26 19:37:13 +05:30
2026-09-27 02:57:28 -07:00
2026-10-03 20:50:15 +05:30
2026-09-25 13:49:31 -05:00
2026-09-26 07:21:49 +05:30
2026-09-28 14:16:18 -07:00
2026-09-28 15:54:07 +05:30
2026-09-28 15:54:07 +05:30
2026-09-27 18:30:25 +05:30
2026-10-02 01:13:21 +05:30
2026-09-28 14:16:18 -07:00
2026-09-28 13:30:57 -07:00
2026-10-02 01:17:03 +05:30
2026-09-25 12:01:44 -05:00
2026-10-02 01:17:03 +05:30
2026-09-28 13:30:57 -07:00
2026-09-27 00:42:12 +05:30
2026-09-28 12:53:29 -05:00
2026-09-28 04:34:30 -07:00
2026-09-28 15:54:07 +05:30
2026-10-02 02:42:14 -07:00
2026-09-28 14:16:18 -07:00
2026-09-27 18:30:25 +05:30
2026-09-27 19:06:05 +05:30
2026-10-03 16:31:35 +05:30
2026-09-23 16:55:09 -04:00
2026-10-02 19:22:09 -04:00
2026-09-29 15:58:55 +05:30
2026-09-23 15:26:34 -04:00
2026-09-23 10:41:08 -07:00
2026-09-28 12:23:25 -07:00
2026-10-02 22:43:10 -05:00
2026-09-26 06:41:34 +05:30
2026-09-26 22:40:54 +05:30
2026-10-02 01:13:21 +05:30
2026-10-01 22:59:37 +05:30
2026-09-28 04:34:30 -07:00
2026-09-28 05:37:55 -07:00
2026-09-25 14:28:14 +05:30
2026-09-28 14:16:18 -07:00
2026-10-02 02:59:59 +05:30
2026-09-23 15:26:34 -04:00
2026-10-02 21:54:45 -04:00
2026-09-28 04:34:30 -07:00
2026-09-28 14:16:18 -07:00
2026-10-01 00:47:44 -05:00
2026-09-23 10:41:08 -07:00
2026-10-03 16:53:54 +05:30
2026-09-28 12:43:03 -07:00
2026-09-28 05:24:26 -07:00
2026-09-24 03:42:38 -04:00
2026-10-03 20:54:04 +05:30
2026-09-28 04:34:30 -07:00
2026-09-23 15:26:34 -04:00
2026-09-27 00:42:55 +05:30
2026-09-28 12:43:03 -07:00
2026-09-29 04:15:21 +05:30
2026-09-26 20:07:47 +05:30
2026-10-01 22:25:21 -04:00
2026-09-24 22:26:11 +05:30
2026-09-28 18:20:39 +05:30
2026-09-28 15:54:07 +05:30
2026-09-28 15:54:01 +05:30
2026-09-28 14:16:18 -07:00
2026-09-29 19:33:09 -05:00
2026-10-03 16:32:35 +05:30
2026-10-03 23:03:42 +05:30
2026-09-24 22:30:59 +05:30
2026-09-28 04:34:30 -07:00
2026-09-23 14:55:08 -07:00
2026-10-01 18:07:32 +05:30
2026-09-28 15:54:07 +05:30
2026-09-25 21:25:57 +05:30
2026-09-25 13:49:31 -05:00
2026-09-27 20:47:41 +05:30
2026-09-25 14:28:14 +05:30
2026-09-26 07:21:49 +05:30
2026-09-26 23:49:25 +05:30
2026-10-03 16:36:48 +05:30
2026-09-28 12:23:25 -07:00
2026-09-28 12:43:03 -07:00
2026-10-01 17:18:56 -07:00
2026-09-24 09:20:50 -04:00
2026-09-29 18:05:05 -05:00
2026-10-03 16:32:35 +05:30
2026-09-23 19:51:34 -04:00
2026-09-29 15:58:55 +05:30
2026-09-29 07:44:13 +00:00
2026-09-29 17:15:05 +05:30
2026-10-01 11:42:35 -04:00
2026-09-26 11:24:50 -07:00
2026-09-24 22:27:32 +05:30
2026-09-24 22:27:32 +05:30
2026-09-23 16:25:21 -07:00
2026-09-24 22:28:19 +05:30
2026-09-24 22:27:32 +05:30
2026-09-24 02:03:59 -04:00
2026-09-28 14:16:18 -07:00
2026-10-03 20:50:15 +05:30
2026-09-24 22:28:19 +05:30
2026-10-02 22:25:39 -05:00
2026-10-03 18:40:38 +05:30
2026-09-27 01:34:15 +05:30
2026-10-03 20:50:15 +05:30
2026-09-28 15:54:07 +05:30
2026-09-28 14:16:18 -07:00
2026-09-27 22:30:55 -07:00
2026-09-27 01:05:06 +05:30
2026-09-27 20:47:41 +05:30
2026-10-02 01:07:31 +05:30
2026-10-02 01:07:31 +05:30
2026-10-01 17:18:56 -07:00
2026-10-01 17:18:56 -07:00
2026-10-02 02:58:18 +05:30
2026-09-28 21:06:08 -04:00
2026-09-27 22:04:26 -07:00
2026-09-26 19:57:55 +05:30