<div>Hi Sven,</div><div><br></div><div>I&#39;ve enjoyed reading your tutorial, good work !</div><div><br></div><div>** I&#39;ve tried to add a link on <a href="http://caretaker.wolf359.be:8080/reddit">http://caretaker.wolf359.be:8080/reddit</a>, it always throw this error:</div>

<div><br></div><meta http-equiv="content-type" content="text/html; charset=utf-8"><meta http-equiv="content-type" content="text/html; charset=utf-8">GlorpDatabaseReadError: ERROR: relation &quot;reddit_links_id_seq&quot; does not exist at character 16<br>

<br>Your request could not be completed. An exception occurred.<br><div><br></div><div><br></div><div>** About code formatting, could you put the class name in front of methods ? Like this:</div><div><br></div>RedditLink&gt;&gt;initialize<br>

    self points: 0; created: TimeStamp now<br><div><br></div><div>or </div><div><br></div><div>RedditDatabaseResource class&gt;&gt;login    </div><div>    DefaultLogin ifNil: [ DefaultLogin := self createLogin ].<br>    ^ DefaultLogin</div>

<div><br></div><div><br></div><div>Sometimes I&#39;ve been lost....</div><div><br></div><div><br></div>** from Common Lisp to Phyton. -&gt; Python<div><br></div><div>I&#39;ve never used GLORP so it was the hard part for me. Indeed I&#39;m not sure about this sort of code:</div>

<div><br></div>WAReddit&gt;&gt;voteUp: link   <br>    self session glorpSession inUnitOfWorkDo: [ :session |<br>        session register: link.<br>        link voteUp ]<div><br></div><div>Can WAReddit be independent from persistence solution ? In ActiveRecord way I would expect something like:</div>

<div><br></div><div>WAReddit&gt;&gt;voteUp: link</div><div>    link voteUp; save.</div><div><br></div><div><div><br></div><div>Anyway I will try to code it and see, it&#39;s a good opportunity for a screencast :)</div><div>

<br></div><div><br></div><div>Cheers,</div><div><br></div><div><div>Laurent Laffont<br><br><a href="http://pharocasts.blogspot.com/">http://pharocasts.blogspot.com/</a><br><a href="http://magaloma.blogspot.com/">http://magaloma.blogspot.com/</a><br>

</div><div><br></div><br>On Fri, Jul 30, 2010 at 3:05 PM, Sven Van Caekenberghe <span dir="ltr">&lt;<a href="mailto:sven@beta9.be">sven@beta9.be</a>&gt;</span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

Reddit.st - In 10 elegant Smalltalk classes<br>
<br>
Implementing a Reddit style web application in Smalltalk<br>
<br>
Using Seaside, Glorp and PostgreSQL<br>
<br>
<a href="http://homepage.mac.com/svc/Reddit.st" target="_blank">http://homepage.mac.com/svc/Reddit.st</a><br>
<br>
This is a tutorial showing how to implement a small but non-trivial web application in Smalltalk using Seaside, Glorp and PostgreSQL. Reddit, is web application where users can post interesting links that get voted up or down. The idea is that the &#39;best&#39; links end up with the most points automatically. Many other websites exist in the area of social bookmarking, like Delicious, Digg and Hacker News.<br>


<br>
In 2005 Reddit switched their implementation from Common Lisp to Phyton. As a reaction I published a Lisp Movie (screen cast) called Episode 2: (Re)writing Reddit in Lisp in 20 minutes and 100 lines also known as Reddit.lisp - In less than 100 lines of elegant code. Although the title was provocative, to get attention and for fun, and this was lost on some people, the key message was just to show that it is perfectly possible to write nice web applications in Lisp and to give an example of how to do so. The reasons for their switch were social, not technical.<br>


<br>
Reddit.st is yet another variant of this example, reimplementing the example in Smalltalk. It adds persistency in a relational database, unit tests as well as web application components to the mix.<br>
<br>
The 10 main sections of this article follow the development of the 10 classes making up the application. The focus of the Smalltalk version is not so much on the small size or the high developer productivity, but more on the fact that we can cover so much ground using such powerful frameworks, as well as the natural development flow from model over tests and persistence to web GUI.<br>


<br>
Reddit.st is running live at <a href="http://caretaker.wolf359.be:8080/reddit" target="_blank">http://caretaker.wolf359.be:8080/reddit</a><br>
<br>
Source code is in the Reddit package of <a href="http://www.squeaksource.com/ADayAtTheBeach.html" target="_blank">http://www.squeaksource.com/ADayAtTheBeach.html</a><br>
<br>
Feedback and remarks are welcome. </blockquote><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
Enjoy,<br>
<br>
Sven_______________________________________________<br>
seaside mailing list<br>
<a href="mailto:seaside@lists.squeakfoundation.org">seaside@lists.squeakfoundation.org</a><br>
<a href="http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside" target="_blank">http://lists.squeakfoundation.org/cgi-bin/mailman/listinfo/seaside</a><br>
</blockquote></div><br></div></div>