model-writtenrun 1613 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Jim Jones proposed a creation-time WARNING for BEGIN ATOMIC functions referencing temporary relations because their apparent permanence concealed automatic deletion when those relations disappeared #1.
- Early feedback questioned notification overhead, favored NOTICE over WARNING, and pointed out that ON COMMIT DROP could shorten the function's lifetime to the transaction; Jim clarified that the notification would occur only at creation #2 #3 #4 #5.
- Tom Lane opposed adding CREATE TEMP FUNCTION because temporary functions require explicit schema qualification for security, and suggested rejecting permanent functions with temporary dependencies because of cross-session and dump problems; Jim reproduced those problems, while Pavel Stehule requested an exception for functions in pg_temp #6 #8 #9 #10.
- Jim changed the proposal to an ERROR with a temporary-schema exception, then rebased it; Tom's subsequent review rejected the incomplete range-table scan and its dependence on check_function_bodies, recommending examination of ProcedureCreate()'s authoritative dependency list instead #12 #13 #14.
- Jim split the work into dependency-collection infrastructure and temporary-object validation, moving the check into ProcedureCreate() and expanding coverage beyond direct table references; an immediate corrected submission fixed a tuple-variable typo #15 #16.
- Tom requested caller-controlled deduplication, generic namespace lookup, and checks covering argument types, result types, and defaults; Jim incorporated these changes while still limiting validation to SQL-standard function bodies #17 #18.
- Tom supplied a revision applying the check to every function language and fixing visibility of newly created types, but the number of existing tests relying on implicitly temporary functions persuaded him that an ERROR could break established uses #19 #20.
- Jim accepted broader coverage but revisited dump concerns, and Bernice Southey raised compatibility concerns from her application; Tom clarified that ordinary runtime table references were unaffected and favored a NOTICE naming the temporary dependency #21 #22 #23 #25.
- Jim submitted the NOTICE version with reduced tests, and Tom committed both parts together as 572c40ba94, cleaning up comments, SQLSTATE selection, and tests #27 #28.
- Tom then proposed a separate patch replacing incomplete temporary-view detection with the new dependency infrastructure, also improving materialized-view rejection and adding dependency details to diagnostics; he accepted a second dependency-tree walk rather than invasive plumbing between view creation and dependency recording #28.
- Jim reviewed the view patch and proposed materialized-view tests, then demonstrated that permanent-table columns using temporary types could disappear; Tom deferred extending checks to other object classes because of lookup costs and the lack of field complaints #29 #30.
- At the last message, the function change had landed and Tom announced that he would add tests and push the view patch; 698fa924b1 subsequently landed the implementation from #28 with sequence and materialized-view test improvements, completing both submitted features while broader object checks remained deferred #30.