From 9539978a6a67fde523ef5160bce70c6027751b1b Mon Sep 17 00:00:00 2001 From: nick evans Date: Sun, 13 Nov 2022 16:29:35 -0500 Subject: [PATCH 1/2] =?UTF-8?q?=F0=9F=94=A5=20Remove=20"openssl=20extensio?= =?UTF-8?q?ns=20must=20be=20installed"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit "openssl" has been a default gem for a long time. Although some installations may still disable it, this is very rare and not important enough to document here any more. Looking at "net-http" and "net-smtp", neither of them still document the scenario where "openssl" is missing. Although it carefully avoids an implicit dependency, "net-http" doesn't try to catch any LoadError when an SSL connection is explicitly used. --- lib/net/imap.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/net/imap.rb b/lib/net/imap.rb index 56e3d833..300ddc9f 100644 --- a/lib/net/imap.rb +++ b/lib/net/imap.rb @@ -1269,9 +1269,7 @@ def idle_done # # port:: Port number (default value is 143 for imap, or 993 for imaps) # ssl:: If +options[:ssl]+ is true, then an attempt will be made - # to use SSL (now TLS) to connect to the server. For this to work - # OpenSSL [OSSL] and the Ruby OpenSSL [RSSL] extensions need to - # be installed. + # to use SSL (now TLS) to connect to the server. # If +options[:ssl]+ is a hash, it's passed to # OpenSSL::SSL::SSLContext#set_params as parameters. # open_timeout:: Seconds to wait until a connection is opened From 23c2a4f600c27af33d82f07718fff9ee76dbd74c Mon Sep 17 00:00:00 2001 From: nick evans Date: Mon, 14 Nov 2022 10:12:21 -0500 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=97=91=EF=B8=8F=20Add=20:nodoc:=20to?= =?UTF-8?q?=20RESPONSE=5FERRORS=20and=20client=5Fthread?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit RESPONSE_ERRORS is used internally and should probably be private_const. client_thread should be removed (or deprecated). --- lib/net/imap.rb | 3 +-- lib/net/imap/errors.rb | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/net/imap.rb b/lib/net/imap.rb index 300ddc9f..2a217e45 100644 --- a/lib/net/imap.rb +++ b/lib/net/imap.rb @@ -363,8 +363,7 @@ class IMAP < Protocol # Seconds to wait until an IDLE response is received. attr_reader :idle_response_timeout - # The thread to receive exceptions. - attr_accessor :client_thread + attr_accessor :client_thread # :nodoc: # Returns the debug mode. def self.debug diff --git a/lib/net/imap/errors.rb b/lib/net/imap/errors.rb index 33dd541c..b353756f 100644 --- a/lib/net/imap/errors.rb +++ b/lib/net/imap/errors.rb @@ -51,7 +51,7 @@ class ByeResponseError < ResponseError class UnknownResponseError < ResponseError end - RESPONSE_ERRORS = Hash.new(ResponseError) + RESPONSE_ERRORS = Hash.new(ResponseError) # :nodoc: RESPONSE_ERRORS["NO"] = NoResponseError RESPONSE_ERRORS["BAD"] = BadResponseError