From: Bagas Sanjaya Date: Tue, 19 Sep 2023 04:44:14 GMT Subject: Re: [REGRESSION] uninitialized value $address in git send-email Message-ID: In-Reply-To: <8fcd6d2a-2c16-adf9-da1f-6b9d6fdcc87a@amd.com> On Mon, Sep 18, 2023 at 04:26:44PM -0400, Michael Strawbridge wrote: > Hi, > > Author of a8022c5f7b67 (send-email: expose header information to > git-send-email's sendemail-validate hook, 2023-04-19) here. > > On 2023-09-18 08:56, Bagas Sanjaya wrote: > > I triggered this issue on patch series with cover letter. To reproduce: > > > > 1. Clone git.git repo, then branch off: > > > > ``` > > $ git clone https://github.com/git/git.git && cd git > > $ git checkout -b test > > ``` > > > > 2. Make two dummy signed-off commits: > > > > ``` > > $ echo test > test && git add test && git commit -s -m "test" > > $ echo "test test" >> test && git commit -a -s -m "test test" > > ``` > > > > 3. Generate patch series: > > > > ``` > > $ mkdir /tmp/test > > $ git format-patch -o /tmp/test --cover-letter main > > ``` > > > > 4. Send the series to dummy address: > > > > ``` > > $ git send-email --to="pi " /tmp/test/*.patch > > ``` > > I tried to repro this today on my side.  I can repro the error when > using the address "pi " but that's not a valid email address and > so one would expect it to fail in the extract_valid_address_or_die > function with the error that you mention.  As soon as I make the address > valid like "pi ", git send-email no longer complains. > > In your original case, are you trying to send email to an invalid email > address?  Is it an alias by chance? I triggered this regression when I passed multiple addresses separated by comma (like `--to="foo ,bar "`, but somehow I managed to reduce the trigger to one address only (in this case, "pi "). As for multiple addresses part, let me know if I should post another regression report. -- An old man doll... just what I always wanted! - Clara