[squeak-dev] Re: Winds of change

Daniel Klein danielkleinad at gmail.com
Sun Feb 8 00:12:01 UTC 2009


On Sat, Feb 7, 2009 at 6:22 PM, Aidan Gauland <wgsilkie at ihug.co.nz> wrote:

> Giuseppe Luigi Punzi <glpunzi <at> lordzealon.com> writes:
> > We have elections soon.
> >
> > I'ts time to think about the project. What we search? What new
> > developers search?
>
> For me, the biggest problem with Sqeuak at the moment is its lack of class
> and
> method comments (but not every method needs an overview comment).  I would
> like
> to say to all developers of the uncommented system classes: "Will you
> please go
> back and comment, all the methods and classes you wrote, but failed to
> document!"  And I know I'm not the only one who feels this way.  Hold back
> on
> new features for just a minute, and give what we already have a quick
> polish.
> I've wasted many hours trying to puzzle out how to use complex yet
> undocumented
> methods (some weren't even documented on the Squeak Swiki).  The basic
> collection classes, and the core system classes are well commented.
>
>  -Aidan
>
> P.S No hard feelings, just some frustration.  Sqeuak is a great development
> system, and seems to keep getting better.
>
>
What would be extremely useful (to me at least) is to provide example usage
for some of the more cryptic and difficult classes. The person writing them
has the best understanding and probably had to test things out anyway. So
why not just publish that code in the class comment? For example...

I've been struggling for 2 days trying to get a TCP client socket dialog
with a telnet server. In VisualWorks, I would do something like:

wire := (  SocketAccessor newTCPclientToHost: 'telnetHostname' port: 23 )
readAppendStream.

I can then use:

wire throughAll

and

wire nextPutAll:

among other stream methods, to handle the communication.

I do notice the SocketStream has a HTTP example, but I don't think
SocketStream is for TCP (I could be wrong, but there is no documentation
either way).

I haven't figured it out yet in Squeak. I thought I could do something like
this:

wire := SocketStream openConnectionToHostNamed: 'telnetHostname' port: 23.

and then use

wire upToAll:

and

wire nextPutAll:

but this just 'hangs' and I have to alt+. to abandon the process.

Is this even possible in Squeak? Or do I have to load something else into
the image?

Sockets are very hard to debug and I don't want to have to use the Socket
class. That is way too low level for me. The purpose of Smalltalk is to make
things easy, no? ;-)

Daniel Klein


"You do not really understand something
unless you can explain it to your grandmother."
                -- Albert Einstein.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20090207/74a1baa3/attachment.htm


More information about the Squeak-dev mailing list