Stéphane, On 11 Jun 2010, at 23:09, Stéphane Ducasse wrote:
Hi sven
Hi,
Andreas Raab's 'new' WebClient/WebServer seems quite nice, as he says himself:
As a result, we now have what I think is a pretty decent HTTP server and client implementation for Squeak 4.1 and hopefully we can nuke HTTPSocket sometime soon. WebClient is superior in every respect.
Is this something that will / should fit seamlessly into Pharo ? Or even become preinstalled ?
could be but not at the price to have concatenation of string and numbers. So this means that somebody would have to do a pass on the code and produce a pharo version that squeakers may want or not.
I went over the code and produced a version of WebClient-Core (and WebClient-Test) that passes all units tests in Pharo 1.1 rc 2: Filename: WebClient-Core-SvenVanCaekenberghe.24.mcz Author: Sven Van Caekenberghe Timestamp: 14 June 2010 4:24:21 pm UUID: 92b7f407-8df1-4472-962b-45d99f2364b8 Ancestors: WebClient-Core-ar.23.mcz Filename: WebClient-Tests-SvenVanCaekenberghe.12.mcz Author: Sven Van Caekenberghe Timestamp: 14 June 2010 4:25 pm UUID: f495c2cd-54bb-42a9-a6d7-f380cd656f3f Ancestors: WebClient-Tests-ar.11.mcz Both at http://www.squeaksource.com/ADayAtTheBeach. The only remaining method needed from the old WebClient-Pharo package is String#squeakToUtf8 squeakToUtf8 "Convert the receiver into a UTF8-encoded string" ^self convertToWithConverter: UTF8TextConverter new. There are only 4 callers so I could change that as well, should I ? I checked the references to UTF8TextConverter and it feels as if you don't want a method like #squeakToUtf8 (apart from the name ;-)
I didn't try his ConfigurationOfWebClient since the last version was unreadable and it seemed like an experiment, while his textual explanation was easy to follow.
To load it into and to make the unit tests run in Pharo 1.0 I had to make a couple of fixes (to WebCookie#printOn: and WebServer class#serverString). Who should I sent these changes to ?
to andreas? may be ask him if he wants to have a version working also for pharo but without String#, override
I will contact Andreas directly once I know your position on the last remaining item. Sven BTW, Is there a way to make a (old school) ChangeSet (or even another 'patch' package) out of the differences between versions in Monticello ?
But even then 1 unit test failed (#testServerDestroy).
Furthermore, some the changes in his package WebClient-Pharo seem a bit dangerous, especially a modification to SocketStream#peek (and the failed test was doing a peek) and an override of String#, some others are unneccessary as far as I can see.
Sven
-- Sven Van Caekenberghe - mailto:sven@beta9.be Beta Nine - software engineering - http://www.beta9.be .Mac - svc@mac.com - http://homepage.mac.com/svc
_______________________________________________ Pharo-users mailing list Pharo-users@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-users
_______________________________________________ Pharo-users mailing list Pharo-users@lists.gforge.inria.fr http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-users