Re: Add BF member koel-like indentation checks to SanityCheck CI

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: Add BF member koel-like indentation checks to SanityCheck CI
Дата
Msg-id ZZ5C5kIqqpQqvo6w@paquier.xyz
обсуждение исходный текст
Ответ на Re: Add BF member koel-like indentation checks to SanityCheck CI  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Add BF member koel-like indentation checks to SanityCheck CI
Список pgsql-hackers
On Wed, Jan 10, 2024 at 01:25:36AM -0500, Tom Lane wrote:
> John Naylor <johncnaylorls@gmail.com> writes:
>> Off the top of my head, I like to use '//' comments as quick notes to
>> myself that stand out from normal code comments, and I'm in the habit
>> of putting debug print statements flush against the left margin so
>> they're really obvious. Both of these would be wiped out by pgindent.
>
> +1.  I do both of those things, partly because pgindent would reformat
> them so that it'd be obvious if I forgot to remove them.  (Yes, I
> look at the diffs pgindent wants to make...)

I don't do the debug stuff on the left margin even if I force my way
with custom elogs when running regression tests as it is quicker than
using a coverage report.  I also take notes while reviewing or
implementing things with the '//' comments, so seeing these gone after
a check run would be sad.

> So that leads to the conclusion that I wouldn't want an automatic
> pgindent check to happen during "make all" or "make check", because
> I want those things to succeed before I consider pgindent'ing.
> Maybe it's okay to include it as part of check-world, but I'm
> not quite sure about that either.

Another possibility would be to hide the test behind a PG_TEST_EXTRA.
--
Michael

Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Richard Guo
Дата:
Сообщение: Re: Can we rely on the ordering of paths in pathlist?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Add BF member koel-like indentation checks to SanityCheck CI