-
Notifications
You must be signed in to change notification settings - Fork 451
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError raised in latest Socksify when initializing Dalli client with version 3.2.7+ #996
Comments
I don't like this approach, too brittle, but maybe somebody has a smarter approach to deciding "is Socksify going to cause a problem"? Updated conditions used within this method def self.create_socket_with_timeout(host, port, options)
new_takes_kwargs = true if RUBY_VERSION >= '3.0' &&
!::TCPSocket.private_instance_methods.include?(:original_resolv_initialize)
new_takes_kwargs = false if defined?(Socksify)
if new_takes_kwargs
sock = new(host, port, connect_timeout: options[:socket_timeout])
yield(sock)
else
Timeout.timeout(options[:socket_timeout]) do
sock = new(host, port)
yield(sock)
end
end
end |
i face the same issue with: Dalli 3.2.8 |
1 task
Chiming in to just to say we're also facing this issue and it's blocking us from upgrading to the latest Dalli version. The approach in #999 looks good to me. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Dalli 3.2.7 and 3.2.8 cause a TypeError in Socksify. 3.2.6 works OK.
Ruby version 3.0.6.
Reproduction script, passes with socksify 1.7.1 and dalli 3.2.6 installed, fails with dalli from 3.2.7.
Backtrace:
The text was updated successfully, but these errors were encountered: