On Fri, 8 Mar 2024 at 15:51, Peter Eisentraut <pe...@eisentraut.org> wrote: > What is the relationship of these changes with the recently added > backtrace_on_internal_error?
I think that's a reasonable question. And the follow up ones too. I think it all depends on how close we consider backtrace_on_internal_error and backtrace_functions. While they obviously have similar functionality, I feel like backtrace_on_internal_error is probably a function that we'd want to turn on by default in the future. While backtrace_functions seems like it's mostly useful for developers. (i.e. the current grouping of backtrace_on_internal_error under DEVELOPER_OPTIONS seems wrong to me) > shouldn't backtrace_functions_min_level also affect > backtrace_on_internal_error? I guess that depends on the default behaviour that we want. Would we want warnings with ERRCODE_INTERNAL_ERROR to be backtraced by default or not. There is at least one example of such a warning in the codebase: ereport(WARNING, errcode(ERRCODE_INTERNAL_ERROR), errmsg_internal("could not parse XML declaration in stored value"), errdetail_for_xml_code(res_code)); > Btw., your code/documentation sometimes writes "stack trace". Let's > stick to backtrace for consistency. Fixed that in the latest patset in the email I sent right before this one.