git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: send-email: Net::SMTP::SSL failure

From
Junio C Hamano <gitster@pobox.com>
Date
Jun 9, 2017, 16:37 UTC
Message-ID
<xmqqvao55d8v.fsf@gitster.mtv.corp.google.com>
In-Reply-To
<CACBZZX6AKYA5PmE6Le4cxCTCOOix1ErHyT21C=L83CQBYaN=RQ@mail.gmail.com>
Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:
Show 21 quoted lines
> I have not looked deeply at this, but the error you're getting means
> "we tried to load it before and failed, and here you are trying
> again".
>
> This is almost definitely due to this line in git-send-email:
>
>         if (eval { require Net::SMTP; 1 }) {
>
> And more generally, this code is all buggy:
>
>     4 matches for "eval.*require" in buffer: git-send-email.perl
>     153:my $have_email_valid = eval { require Email::Valid; 1 };
>     154:my $have_mail_address = eval { require Mail::Address; 1 };
>    1118:        if (eval { require Net::Domain; 1 }) {
>    1129:        if (eval { require Net::SMTP; 1 }) {
>
> Well, "buggy" in the sense that we're just happy-go-lucky trying to
> load these modules, and if they have an error we don't report it, then
> when we try to load them again perl just emits a generic error saying
> you're trying to require() something that already failed somewhere
> before...

Thanks for the discussion. My short summary from reading the thread from the sideline is:

 * "eval { require module; 1 }" pattern seems to have spread by
   copying and pasting without thinking, all of which should be
   corrected not to retry;
 * The error OP encountered is not an issue in git-send-email
   per-se, but was made harder to diagnose due to the above.

I think we still lack the definite "here is the right way to fix these not to retry" patch for application, but anything else I missed?

Previous: Ævar Arnfjörð Bjarmason
Message 12 of 12 in “send-email: Net::SMTP::SSL failure”
  1. Liam BreckJun 7, 2017
  2. Liam BreckJun 7, 2017
  3. Ævar Arnfjörð BjarmasonJun 7, 2017
  4. Liam BreckJun 7, 2017
  5. Ævar Arnfjörð BjarmasonJun 7, 2017
  6. Liam BreckJun 7, 2017
  7. Ævar Arnfjörð BjarmasonJun 7, 2017
  8. Liam BreckJun 7, 2017
  9. Samuel LijinJun 8, 2017
  10. Liam BreckJun 8, 2017
  11. Ævar Arnfjörð BjarmasonJun 8, 2017
  12. Junio C HamanoJun 9, 2017

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.