From: Junio C Hamano <gitster@pobox.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: git@vger.kernel.org, Josh Steadmon <steadmon@google.com>,
Calvin Wan <calvinwan@google.com>,
Emily Shaffer <emilyshaffer@google.com>,
Glen Choo <chooglen@google.com>, John Cai <johncai86@gmail.com>
Subject: Re: [RFC PATCH 1/3] test-tool: don't fake up BUG() exits as code 99
Date: Fri, 03 Jun 2022 14:05:49 -0700 [thread overview]
Message-ID: <xmqqczfpe9ua.fsf@gitster.g> (raw)
In-Reply-To: <xmqqv8theehf.fsf@gitster.g> (Junio C. Hamano's message of "Fri, 03 Jun 2022 12:25:32 -0700")
Junio C Hamano <gitster@pobox.com> writes:
>> However, in doing so we've been fooling ourselves when it comes to
>> what trace2 events we log. The events tested for in
>> 0a9dde4a04c (usage: trace2 BUG() invocations, 2021-02-05) are not the
>> real ones, but those that we emit only from the "test-tool".
>
> I can fully agree with the above reasoning, i.e. let's test what we
> do use in production, instead of something nobody uses for real, if
> we were adding a test for BUG() in vacuum, but why did we have to
> "fake" it in the first place?
> ...
> Are we sure that the reason no longer applies? How do we know? We
> would want to explain that to future developers in the proposed log
> message, I would think.
We can flip it the other way around.
I do not think I ever saw anybody asked anybody on this list who got
a BUG() message to use the coredump to do something useful. Don't
modern distros ship with "ulimit -c 0" these days?
It might be possible that a better direction is to introduce
GIT_ABORT_ON_BUG environment or core.abortOnBUG configuration that
chooses between abort() and exit(99), or something like that, and
then we switch to use the latter by default over time?
next prev parent reply other threads:[~2022-06-03 21:05 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-26 0:30 [RFC PATCH 0/3] trace2: log "signal" end events if we invoke BUG() Ævar Arnfjörð Bjarmason
2022-05-26 0:30 ` [RFC PATCH 1/3] test-tool: don't fake up BUG() exits as code 99 Ævar Arnfjörð Bjarmason
2022-06-03 19:25 ` Junio C Hamano
2022-06-03 21:05 ` Junio C Hamano [this message]
2022-06-03 23:05 ` Ævar Arnfjörð Bjarmason
2022-06-08 19:17 ` Jeff King
2022-06-08 21:03 ` Junio C Hamano
2022-06-09 8:09 ` Ævar Arnfjörð Bjarmason
2022-06-09 15:23 ` Jeff King
2022-06-03 23:03 ` Ævar Arnfjörð Bjarmason
2022-05-26 0:30 ` [RFC PATCH 2/3] refs API: rename "abort" callback to avoid macro clash Ævar Arnfjörð Bjarmason
2022-05-26 0:30 ` [RFC PATCH 3/3] trace2: emit "signal" events after calling BUG() Ævar Arnfjörð Bjarmason
2022-05-26 3:04 ` Bagas Sanjaya
2022-05-31 18:16 ` Josh Steadmon
2022-05-26 1:20 ` [RFC PATCH 0/3] trace2: log "signal" end events if we invoke BUG() Junio C Hamano
2022-05-31 17:59 ` Josh Steadmon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqqczfpe9ua.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=avarab@gmail.com \
--cc=calvinwan@google.com \
--cc=chooglen@google.com \
--cc=emilyshaffer@google.com \
--cc=git@vger.kernel.org \
--cc=johncai86@gmail.com \
--cc=steadmon@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).