Subject: Re: bug#65763: Error opening a file from a Git working directory if Git is not installed

From: Eli Zaretskii <[email-masked]>
Date: Wed, 06 Sep 2023 16:06:04 +0300

> Date: Wed, 6 Sep 2023 15:35:33 +0300
> Cc: [email-masked]
> From: Dmitry Gutov <[email-masked]>
> 
> On 06/09/2023 15:13, Eli Zaretskii wrote:
> > Well, we could then protect the execution of the problematic form "by
> > hand" by using condition-case-unless-debug.  Dmitry, WDYT?
> 
> Maybe the solution is to use the straight condition-case rather than 
> condition-case-unless-debug? Because otherwise as long as 
> condition-case-unless-debug is used, we would always have this problem.

Sorry, I forgot that debug-on-error affects
condition-case-unless-debug as well.

> Rewriting with-demoted-errors is not an option, of course, but we could 
> create a special, shorted version of it for vc.

Yes, something like that.  Shouldn't be hard, I think.

> Another option, though, is to rewrite the ERT tests in question: e.g. to 
> bind vc-handled-backends to nil, or to some other value if the presence 
> of certain VC programs is known and expected in advance.

Yes, but that needs to be done in every test...