<type 'exceptions.UnboundLocalError'>
Python 2.5.2: /usr/bin/python
Tue Jul 8 21:01:19 2008

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.

 /opt/phillberts.com/python/build/bdist.linux-x86_64/egg/flup/server/fcgi_base.py in run(self=<flup.server.fcgi_base.Request object at 0xbccd50>)
  556         """Runs the handler, flushes the streams, and ends the request."""
  557         try:
  558             protocolStatus, appStatus = self.server.handler(self)
  559         except:
  560             traceback.print_exc(file=self.stderr)
 /opt/phillberts.com/python/build/bdist.linux-x86_64/egg/flup/server/fcgi_base.py in handler(self=<flup.server.fcgi.WSGIServer object at 0x95e4d0>, req=<flup.server.fcgi_base.Request object at 0xbccd50>)
 1110         try:
 1111             try:
 1112                 result = self.application(environ, start_response)
 1113                 try:
 1114                     for data in result:
 /opt/phillberts.com/python/phillberts/router.py in route(self=<__main__.Router object at 0x2aad8ce4e350>, environ={'DOCUMENT_ROOT': '', 'GATEWAY_INTERFACE': 'CGI/1.1', 'HTTP_ACCEPT': 'Accept: application/xhtml+xml,text/html;q=0.9,text/plain;', 'HTTP_ACCEPT_CHARSET': 'ISO-8859-1,utf-8;q=0.7,*;q=0.7', 'HTTP_ACCEPT_ENCODING': 'gzip', 'HTTP_ACCEPT_LANGUAGE': 'en-us,en;q=0.5', 'HTTP_CACHE_CONTROL': 'no-cache', 'HTTP_CONNECTION': 'close', 'HTTP_HOST': 'phillberts.com', 'HTTP_PRAGMA': 'no-cache', ...}, start_response=<function start_response at 0xbcdcf8>)
   78             ### Call the requested action
   79             action = getattr(self.controller, result["action"].lower())
   80             retval = action(environ, start_response)
   81             return retval
   82         else:
retval undefined, action = <bound method Controller.service of <controller.Controller object at 0x2aad8ce4e410>>, environ = {'DOCUMENT_ROOT': '', 'GATEWAY_INTERFACE': 'CGI/1.1', 'HTTP_ACCEPT': 'Accept: application/xhtml+xml,text/html;q=0.9,text/plain;', 'HTTP_ACCEPT_CHARSET': 'ISO-8859-1,utf-8;q=0.7,*;q=0.7', 'HTTP_ACCEPT_ENCODING': 'gzip', 'HTTP_ACCEPT_LANGUAGE': 'en-us,en;q=0.5', 'HTTP_CACHE_CONTROL': 'no-cache', 'HTTP_CONNECTION': 'close', 'HTTP_HOST': 'phillberts.com', 'HTTP_PRAGMA': 'no-cache', ...}, start_response = <function start_response at 0xbcdcf8>
 /opt/phillberts.com/python/phillberts/controller.py in service(self=<controller.Controller object at 0x2aad8ce4e410>, environ={'DOCUMENT_ROOT': '', 'GATEWAY_INTERFACE': 'CGI/1.1', 'HTTP_ACCEPT': 'Accept: application/xhtml+xml,text/html;q=0.9,text/plain;', 'HTTP_ACCEPT_CHARSET': 'ISO-8859-1,utf-8;q=0.7,*;q=0.7', 'HTTP_ACCEPT_ENCODING': 'gzip', 'HTTP_ACCEPT_LANGUAGE': 'en-us,en;q=0.5', 'HTTP_CACHE_CONTROL': 'no-cache', 'HTTP_CONNECTION': 'close', 'HTTP_HOST': 'phillberts.com', 'HTTP_PRAGMA': 'no-cache', ...}, start_response=<function start_response at 0xbcdcf8>)
   46         #storage = self.storage()
   47         #storage = phillberts.storage.Storage()
   48         model_class, model = self.model(component=self.component, tag=self.request['phillberts.router.tag'])
   49         view_class, view = self.view(component=self.component, tag=self.request['phillberts.router.tag'])
   50 
model_class undefined, model undefined, self = <controller.Controller object at 0x2aad8ce4e410>, self.model = <bound method Controller.model of <controller.Controller object at 0x2aad8ce4e410>>, component undefined, self.component = '', tag undefined, self.request = {'start_response': <function start_response at 0...tion': 'service', 'HTTP_ACCEPT_ENCODING': 'gzip'}
 /opt/phillberts.com/python/phillberts/controller.py in model(self=<controller.Controller object at 0x2aad8ce4e410>, component='', tag='', type=None)
  103                 model_class = phillberts.model.Static 
  104 
  105         if issubclass(model_class, zro.util.Taggable):
  106             model_uuids = self.storage().query(cls=model_class, tag=tag)
  107             if tag is None and self.request['phillberts.router.mode'] in ("provide", "new", "edit"):
builtin issubclass = <built-in function issubclass>, model_class undefined, global zro = <module 'zro' from './zro/__init__.pyc'>, zro.util = <module 'zro.util' from './zro/util.pyc'>, zro.util.Taggable = <class 'zro.util.Taggable'>

<type 'exceptions.UnboundLocalError'>: local variable 'model_class' referenced before assignment
      args = ("local variable 'model_class' referenced before assignment",)
      message = "local variable 'model_class' referenced before assignment"