http://goran.krampe.se/blog/Squeak - Oct 25, 2010 11:56:14 AM - Dec 3, 2004 10:09:58 PM
06 Sep 10
Skype interview with Dan Ingalls
Before the summer I had the opportunity to do a Skype interview with Dan Ingalls, the "Guido/Larry/Linus" of Smalltalk.The interview was part of a guest lecture I did at DSV for the DYPL course (dynamic programming languages) held by Beatrice Akerblom. In the end I only used a smaller quote because most of the topics in the interview ended up being more interesting to "true believers" than to Smalltalk newcomers.
I admit to not having planned the interview in perfect detail so rather quickly it degenerated into an informal discussion, with my daughter interrupting at random places. :) So I did some "post production work" and edited it into approximately 22 minutes of Q&A. For technical woes, see my earlier post.
Since the ESUG 2010 soon is here (can’t attend unfortunately) this is my small contribution, enjoy (10Mb).
regards, Goran
21 May 10
Setting up a Squeak+Seaside+CouchDB dev environment
This is a little log from my attempts to set up a fresh development environment for the eBlankett.org project. eBlankett is a web system that presents wizard like web forms to the user given a declarative high level definition of this wizard in JSON.Trip to Pharo land
First I picked up Pharo-1.0 from the Pharo site and installed Seaside-3.0 using Metacello. That takes… quite a bit of time to run. :) But hey, Pharo is meant to be the development platform for Seaside so it seems a reasonable choice.
Next component needed for eBlankett is a library to access CouchDB, because eBlankett uses CouchDB to store the form definitions. In the Squeak world there are currently two options for that:
- The CouchDB project from Danie Roux that uses the Curl plugin.
- The SCouchDB project from Igor Stasenko that works directly on top of SocketStream, not even using a HTTP layer between.
Since eBlankett so far uses only the utmost trivial CouchDB operations it doesn’t really matter which one we use. At the start of the project we used the former but lately we switched to SCouchDB to get rid of the Curl dependency (sorry Daniel, Curl rocks but…). Igor is also working actively on SCouchDB and Igor is my friend, so that also made it a nice choice :)
SCouchDB has an installation snippet in a separate class in a separate MC package that looks like this:
Installer mantis ensureFix: '7446: [BUG][FIX] SocketStream>>peek'. (Installer repository: 'http://www.squeaksource.com/SCouchDB') install: 'JSON'; install: 'SCouchDB-Core'; install: 'SCouchDB-Tests'.Note though that Pharo does not have Installer so the bug fix line will not work. After scrutinizing the bug I realized that this bug is indeed NOT fixed in Pharo 1.0. But it was a trivial fix to make by hand.
Ok, a speed bump, but let’s push forward. Pharooners use Gofer instead of Installer - it is very similar, but only operates on Monticello repositories (and probably knows how to do lots of other cool stuff of course). Since the above script is trivial we can convert it to Gofer:
(Gofer new squeaksource: 'SCouchDB'; package: 'JSON'; package: 'SCouchDB-Core'; package: 'SCouchDB-Tests'.Aha! A bug in Gofer is discovered, it doesn’t like MC snapshots with more than 2 periods in their names so it loaded the wrong snapshots. Since Igor used a developer initial like ‘Igor.Stasenko’ Gofer gets confused! So ok, open up the repo and load the latest snapshots manually.
Finally we want to install the eBlankett code which is hosted on an ftp repository with a password but Gofer of course deals with that nicely:
(Gofer new url: 'ftp://krampe.se' username: 'secret' password: 'secret') package: 'Blankett'; loadTime to fire it up and see if it works, we make sure we have a CouchDB running on localhost:5984 too, but I am on Ubuntu which already has that.
WAKom startOn: 8080…ok, so a while later I realize that Pharo 1.0 is also missing Date class>>readFrom:pattern: (actually a contribution of mine) … and at this point I decide to run back home to Squeak trunk and try all this again! From the start. Sorry Pharo, perhaps some other time. It would have been easy to add #readFrom:pattern: but I just ran out of gasoline.
Running home to trunk
After fumbling around a while due to missing instructions and misleading filenames (this should be on www.squeak.org darnit!) I come up with this procedure to get an image running that tracks trunk:
- Download Squeak-4.1.zip.
- Open preferences, search for Monticello. Set the default update URL to "/trunk". This was not easy to find out, although trivial once found. There is one more way to find this out, go to Help->Extending the system and read there. But that was NOT obvious for me to find.
- Load Updates. This gives us a "bleading edge" image instead of 4.1. Probably not needed, but hey… we like the edge.
Then we execute the following:
(Installer ss project: 'MetacelloRepository') install: 'ConfigurationOfSeaside30'. (Smalltalk at: #ConfigurationOfSeaside30) load. (Installer repository: 'http://www.squeaksource.com/SCouchDB') install: 'JSON'; install: 'SCouchDB-Core'; install: 'SCouchDB-Tests'. (Gofer new url: 'ftp://krampe.se' username: 'blankett' password: 'ett') package: 'Blankett'; load…and finally open->Seaside Control Panel, add a Comanche adaptor, start it. Surf to localhost:8080/eBlankett and tada! We are up. Ehm, ok, so encoding ended up as iso-8859-1, but wait, no problem, just use the menu in the Seaside Control Panel, easily fixed to utf8.
Ok, so trunk it will be for now. Pharo is cool and Pharo is good, no doubt. But I will try to stay in trunk for this project.
/Goran
June, 2010
November, 2009
06 Sep 09
DeltaStreams boost in Brest
Here at ESUG in Brest DeltaStreams has gotten a real "boost". Igor Stasenko has joined the effort and is busy whipping up a user interface using the Toolbuilder API so that it will work in most Squeak flavours (and perhaps other Smalltalks too) and I have been busy getting the rest of the code in a better shape.The presentation I gave was very well received (I think), although it collided with the Seaside tutorial which meant that a lot of people I would have liked to see it was busy on the other track. But interest is high, and not only from Squeakers but also from developers using Smalltalk/X and VisualWorks!
The immediate results from Brest are:
- Tirade has been fully hooked into Deltas which means that Deltas now have a file format and can be serialized/deserialized using that.
- DeltaStreams now load very easily into latest Squeak "trunk" using an Installer based script, instructions below.
- Igor is building a Toolbuilder based user interface similar to the changesorter tools. After just a few hours he has something "up and running" and I suspect it will gain features over the next weeks rather quickly. NOTE: Matthew Fulmer made the first UI for Deltas but Igor and I wanted to build something different.
- We have been talking to Pharo people about what kind of APIs will be available in Pharo that we can depend on for Deltastreams and AFAICT Toolbuilder and SystemEditor are meant to be available in Pharo.
- Lots of tests cleaned up, we are almost in the full green with over 300 tests.
- Handling of DoIts has been added. A tricky problem.
Below follows an instruction for getting started HACKING on the DeltaStreams package for Squeak. If you are into meta programming, advanced source code management and Squeak, it might be interesting. Thus it is not an instruction for users (it is not really usable yet anyway) nor for Squeak beginners.
Step 1
Grab an image, 3.10.2-7179 should be fine but we are now working in trunk. It might be nice if you picked some other important target for DeltaStreams, like say Croquet, Cuis or Pharo. :)
Step 2
Add the repo for DeltaStreams on SqueakSource:
MCHttpRepository location: 'http://www.squeaksource.com/DeltaStreams' user: '' password: ''Step 3
Open the repository and load the latest version of the package called DeltaStreams-Installer. Then execute the class side script by executing DSInstaller install. If all was loaded you will get a nice greeting!
NOTE: Several packages in the repository are not loaded by this installer script. Some lines of development has not been pursued further by me (Primarily ICS, the first browser UI and some more things) but that does not mean that Matthew or someone else can port that code forward and make it work again :)
Step 4
Run some tests. Currently there are some tests failing. We do not like this "state" so I am in the process of cleaning up, fixing what I can fix and throwing out red tests I can’t understand. We should always be green, otherwise we don’t know if we broke something. These are the results in my image today:
Prerequisites:
SystemEditor-Tests: 11 failures (have not looked at it, was the same in 3.10.2-7179) Tirade-Tests: green SystemChangeNotifications-Tests: greenDeltaStreams:
DSDeltaApplyTest: green DSDeltaCreationTest: green DSDeltaAntiTest: green DSDeltaCopyTest: green DSDeltaTiradeFileOutTest: green DSDeltaLoggingTest: green DSDeltaRevertTest: 6 failures (related to dangling method categories, these we should fix!) DSDeltaTiradeTest: green DSDeltaTiradeTest: green DSDeltaValidationTest: red, red, red!!! (I need to read up on validation, Matthew made it) DSDeltaValidationTestSystemEditor: red, red, red!!! (same here)Step 5
Read some class comments and code. Start with DSDelta and the DSChange hierarchy.
Step 7
Grab a big cup of coffee, save your image from time to time (although the code generally does not make it crash…). Ask us whatever you like.
regards, Goran & Igor