model-writtenrun 2869 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Alexander Lakhin reported that dropping an access method used by a partitioned table succeeded and left an orphaned reference, causing subsequent partition creation to fail #1.
- Kirill Reshke proposed including partitioned tables in RELKIND_HAS_TABLE_AM, then expanded the patch after Alexander reported regression failures; the revised approach fixed the reproducer but still failed regression tests #2 #3.
- Michael Paquier explained that the macro describes relations with rd_tableam and therefore must exclude partitioned tables, replacing Kirill's approach with a focused dependency fix in heap_create_with_catalog() and a regression test inspecting pg_depend #4.
- Alexander confirmed Michael's patch worked and questioned why default_table_access_method did not set the partitioned parent's access method; Junwang Zhao defended choosing the default when creating each partition and supplied an optional inline change illustrating the alternative #5 #6.
- Michael confirmed that an unset parent access method intentionally lets new partitions use the current default, preserving backward compatibility, so the suggested change to default handling was left out #7.
- Michael committed 49a23441ca from #4, adding a validity check for unset access methods and simplifying the test transaction handling, then announced that the fix had also been backpatched to PostgreSQL 17, completing the reported bug fix #8.