model-writtenrun 8338 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Fujii Masao reported that max_slot_wal_keep_size could invalidate a logical replication slot's restart_lsn, causing pg_copy_logical_replication_slot() to assert, and proposed removing the obsolete assertion in #1.
- Kyotaro Horiguchi confirmed the diagnosis and questioned the missing test coverage in #2; Fujii agreed that additional coverage would help and planned to commit the fix in #3.
- Alvaro Herrera recommended ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE and considered a more specific invalidated-slot error message in #4.
- Fujii adopted the error-code change while retaining the existing error message in #5, and Alvaro approved that revision in #6.
- Fujii committed #5 unchanged apart from rebasing as a82ba066ea, with a backport to PostgreSQL 13, and confirmed the push in #7; the suggested additional tests were not included or pursued further in this thread.