Changes between Version 203 and Version 204 of WikiStart


Ignore:
Timestamp:
11/30/2011 03:46:41 PM (7 years ago)
Author:
Jonathan Jacobs
Comment:

Make the HelloResource copy-pasteable into a REPL and add a newline to the GET response

Legend:

Unmodified
Added
Removed
Modified
  • WikiStart

    v203 v204  
    163163    isLeaf = True
    164164    numberRequests = 0
    165 
     165   
    166166    def render_GET(self, request):
    167167        self.numberRequests += 1
    168168        request.setHeader("content-type", "text/plain")
    169         return "I am request #" + str(self.numberRequests)
     169        return "I am request #" + str(self.numberRequests) + "\n"
    170170
    171171reactor.listenTCP(8080, server.Site(HelloResource()))