Closed pberndt closed 11 years ago
I think this might make more sense as a separate gem than part of Celluloid::IO proper
Maybe. As an alternative, do you think it would be possible to further duck extend the Celluloid::IO class (by adding open, binmode, sync=, syswrite, and even select) so that the original telnet.rb could be used by just injecting TCPSocket and IO?
Yeah, I'd definitely be down to get those bits upstream
I note that sync=
and syswrite
are now present.
@pberndt Could you open an issue with the remaining missing methods?
I wasn't sure if the open
class method was needed or not.
The open
class method should be present too
:metal:
@halorgium, is this telnet rewrite using celluloid io already available somewhere?
@halorgium, is this telnet rewrite using celluloid io already available somewhere?
@TiagoCardoso1983 not that I know of, but it might be possible to reuse Net::Telnet now
@tarcieri, what do you mean? I tried using a Celluloid IO TCPSocket as proxy for the Net::Telnet channel, and failed because it requested a subclass of IO or something like it. I tried it with ruby 1.9.3 . Are there any updates I don't know of?
@TiagoCardoso1983 if Net::Telnet is specifically asserting that a given object is an IO object, you'll have to change the code or use an alternative library that supports dependency injection
Hello Tony,
please find attached a celluloid port of the ruby-1.9.3-p374 telnet.rb
Best regards, Philipp