user/dev discussion of public-inbox itself
 help / color / mirror / code / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download mbox.gz: |
* [PATCH 6/9] net_reader: detect IMAP failures earlier
  2021-09-18  9:33  6% [PATCH 0/9] lei: a bunch of random stuff Eric Wong
@ 2021-09-18  9:33  7% ` Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2021-09-18  9:33 UTC (permalink / raw)
  To: meta

An Mail::IMAPClient object may be returned even on connection
failure, so use IsConnected to check for it.  This ensures
git-credential will no longer prompt for passwords when there's
no connection.
---
 lib/PublicInbox/NetReader.pm | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/PublicInbox/NetReader.pm b/lib/PublicInbox/NetReader.pm
index e703cddb..8eff847e 100644
--- a/lib/PublicInbox/NetReader.pm
+++ b/lib/PublicInbox/NetReader.pm
@@ -108,7 +108,8 @@ sub mic_for ($$$$) { # mic = Mail::IMAPClient
 	};
 	$mic_arg->{Ssl} = 1 if $uri->scheme eq 'imaps';
 	require PublicInbox::IMAPClient;
-	my $mic = mic_new($self, $mic_arg, $sec, $uri) or
+	my $mic = mic_new($self, $mic_arg, $sec, $uri);
+	($mic && $mic->IsConnected) or
 		die "E: <$uri> new: $@".onion_hint($lei, $uri);
 
 	# default to using STARTTLS if it's available, but allow

^ permalink raw reply related	[relevance 7%]

* [PATCH 0/9] lei: a bunch of random stuff
@ 2021-09-18  9:33  6% Eric Wong
  2021-09-18  9:33  7% ` [PATCH 6/9] net_reader: detect IMAP failures earlier Eric Wong
  0 siblings, 1 reply; 2+ results
From: Eric Wong @ 2021-09-18  9:33 UTC (permalink / raw)
  To: meta

The unique timers stuff will be used for "lei up" polling,
as will 9/9 to improve "lei up" usability.

The net_reader changes were noticed while getting imaps://
to work with socks5h:// (not just imap://).

There's still a lot of mail_sync stuff going on, but it's
getting closer...

Eric Wong (9):
  lei: lock worker counts
  lei_mail_sync: rely on flock(2), avoid IPC
  lei_mail_sync: set nodatacow on btrfs
  ds: support add unique timers
  net_reader: tie SocksDebug to {imap,nntp}.Debug
  net_reader: detect IMAP failures earlier
  net_reader: support imaps:// w/ socks5h:// proxy
  net_reader: set SO_KEEPALIVE on all Net::NNTP sockets
  lei up: automatically use dt: for remote externals

 Documentation/lei-up.pod              |  15 ++++
 lib/PublicInbox/DS.pm                 | 100 +++++++++++++-------------
 lib/PublicInbox/LEI.pm                |  40 +++++------
 lib/PublicInbox/LeiExportKw.pm        |  32 ++++-----
 lib/PublicInbox/LeiForgetMailSync.pm  |   6 +-
 lib/PublicInbox/LeiImport.pm          |   8 +--
 lib/PublicInbox/LeiInput.pm           |   2 +-
 lib/PublicInbox/LeiInspect.pm         |   5 +-
 lib/PublicInbox/LeiLsMailSource.pm    |   3 +-
 lib/PublicInbox/LeiLsMailSync.pm      |   3 +-
 lib/PublicInbox/LeiLsSearch.pm        |   2 +-
 lib/PublicInbox/LeiMailSync.pm        |  51 ++++++++++---
 lib/PublicInbox/LeiNoteEvent.pm       |  31 ++++----
 lib/PublicInbox/LeiRefreshMailSync.pm |  35 ++++-----
 lib/PublicInbox/LeiRm.pm              |   2 +-
 lib/PublicInbox/LeiSavedSearch.pm     |   1 +
 lib/PublicInbox/LeiStore.pm           |  39 +---------
 lib/PublicInbox/LeiTag.pm             |   3 +-
 lib/PublicInbox/LeiToMail.pm          |  10 ++-
 lib/PublicInbox/LeiUp.pm              |   2 +-
 lib/PublicInbox/LeiXSearch.pm         |  50 ++++++++++---
 lib/PublicInbox/NetReader.pm          |  26 ++++---
 t/lei-q-remote-import.t               |   4 ++
 23 files changed, 259 insertions(+), 211 deletions(-)

^ permalink raw reply	[relevance 6%]

Results 1-2 of 2 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2021-09-18  9:33  6% [PATCH 0/9] lei: a bunch of random stuff Eric Wong
2021-09-18  9:33  7% ` [PATCH 6/9] net_reader: detect IMAP failures earlier Eric Wong

Code repositories for project(s) associated with this public inbox

	https://80x24.org/public-inbox.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).