async-io 1.34.0 → 1.34.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a0131359c594306a5fbe0e355a33392e6e59608f771677974aa376336ace05e4
4
- data.tar.gz: f3e3d7ebd90014cf4692a64cb39e107a95899a64d07536959ec208c45f69044e
3
+ metadata.gz: a8c1a9e5d89a2edf192c69d6fac28fa00a9c24b0de074a2f9b4e5a6666496d93
4
+ data.tar.gz: b4f9f3db305d8cbca108855076cb9ca9c8ba003082d02dabc400c4ae2ff2a05a
5
5
  SHA512:
6
- metadata.gz: 135c73883230c4c902c75b5070bec585fa5849d832eef7e6f1e70df8a456d77c8ebd43869c938ad6b7345b9c05e64f6fd423f53bf93a80cc193453a2d532b981
7
- data.tar.gz: 4b6689c582cca834d15d0358a71fd9325ff295ef6477dfd9ec3bf6e5ec84de356c2dee39ad9502fc17c8b76ad3d82d19feef1fb6d4b678eb30d3a2d5076fbd7d
6
+ metadata.gz: 631aa9c93ef096f8563ab56153c78dee3289f5ebc463c557476b7722e77ed0d76c6d49a139915579e1ad430df47d25efbadbf25fa3103d1de61246b7ce685395
7
+ data.tar.gz: 90673353c83e111b17239fbf0df847339864adb18b7501db04f58dcc543e5d57e6b8d41cc0248f308ce96ff3506abcbf4b7984b31a4056c42c883f79a0c61e38
@@ -98,7 +98,7 @@ module Async
98
98
  end
99
99
  end
100
100
 
101
- wraps ::IO, :external_encoding, :internal_encoding, :autoclose?, :autoclose=, :pid, :stat, :binmode, :flush, :set_encoding, :set_encoding_by_bom, :to_io, :to_i, :reopen, :fileno, :fsync, :fdatasync, :sync, :sync=, :tell, :seek, :rewind, :pos, :pos=, :eof, :eof?, :close_on_exec?, :close_on_exec=, :closed?, :close_read, :close_write, :isatty, :tty?, :binmode?, :sysseek, :advise, :ioctl, :fcntl, :nread, :ready?, :pread, :pwrite, :pathconf
101
+ wraps ::IO, :external_encoding, :internal_encoding, :autoclose?, :autoclose=, :pid, :stat, :binmode, :flush, :set_encoding, :set_encoding_by_bom, :to_path, :to_io, :to_i, :reopen, :fileno, :fsync, :fdatasync, :sync, :sync=, :tell, :seek, :rewind, :path, :pos, :pos=, :eof, :eof?, :close_on_exec?, :close_on_exec=, :closed?, :close_read, :close_write, :isatty, :tty?, :binmode?, :sysseek, :advise, :ioctl, :fcntl, :nread, :ready?, :pread, :pwrite, :pathconf
102
102
 
103
103
  # Read the specified number of bytes from the input stream. This is fast path.
104
104
  # @example
@@ -57,7 +57,7 @@ module Async
57
57
 
58
58
  alias connect_nonblock connect
59
59
 
60
- # @param duration [Numeric] the maximum time to wait for accepting a connection, if specified.
60
+ # @param timeout [Numeric] the maximum time to wait for accepting a connection, if specified.
61
61
  def accept(timeout: nil, task: Task.current)
62
62
  peer, address = async_send(:accept_nonblock, timeout: timeout)
63
63
  wrapper = Socket.new(peer, task.reactor)
@@ -30,7 +30,7 @@ module Async
30
30
 
31
31
  # Asynchronous TCP socket wrapper.
32
32
  class SSLSocket < Generic
33
- wraps OpenSSL::SSL::SSLSocket, :alpn_protocol, :cert, :cipher, :client_ca, :context, :finished_message, :peer_finished_message, :getsockopt, :hostname, :hostname=, :npn_protocol, :peer_cert, :peer_cert_chain, :pending, :post_connection_check, :setsockopt, :session, :session=, :session_reused?, :ssl_version, :state, :sync_close, :sync_close=, :sysclose, :verify_result, :tmp_key
33
+ wraps OpenSSL::SSL::SSLSocket, :alpn_protocol, :cert, :cipher, :client_ca, :context, :export_keying_material, :finished_message, :peer_finished_message, :getsockopt, :hostname, :hostname=, :npn_protocol, :peer_cert, :peer_cert_chain, :pending, :post_connection_check, :setsockopt, :session, :session=, :session_reused?, :ssl_version, :state, :sync_close, :sync_close=, :sysclose, :verify_result, :tmp_key
34
34
 
35
35
  wrap_blocking_method :accept, :accept_nonblock
36
36
  wrap_blocking_method :connect, :connect_nonblock
@@ -114,7 +114,9 @@ module Async
114
114
  raise exception, "encountered eof while reading data"
115
115
  end
116
116
 
117
- alias readpartial read_partial
117
+ def readpartial
118
+ read_partial or raise EOFError, "Encountered eof while reading data!"
119
+ end
118
120
 
119
121
  # Efficiently read data from the stream until encountering pattern.
120
122
  # @param pattern [String] The pattern to match.
@@ -22,6 +22,6 @@
22
22
 
23
23
  module Async
24
24
  module IO
25
- VERSION = "1.34.0"
25
+ VERSION = "1.34.2"
26
26
  end
27
27
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: async-io
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.34.0
4
+ version: 1.34.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
@@ -16,7 +16,7 @@ authors:
16
16
  autorequire:
17
17
  bindir: bin
18
18
  cert_chain: []
19
- date: 2022-08-28 00:00:00.000000000 Z
19
+ date: 2023-01-30 00:00:00.000000000 Z
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency
22
22
  name: async
@@ -170,7 +170,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
170
170
  - !ruby/object:Gem::Version
171
171
  version: '0'
172
172
  requirements: []
173
- rubygems_version: 3.3.7
173
+ rubygems_version: 3.4.1
174
174
  signing_key:
175
175
  specification_version: 4
176
176
  summary: Provides support for asynchonous TCP, UDP, UNIX and SSL sockets.