[Edu-sig] HTConsole
Andre Roberge
andre.roberge at gmail.com
Thu Apr 27 04:36:00 CEST 2006
On 4/26/06, Ian Bicking <ianb at colorstudy.com> wrote:
> Andre Roberge wrote:
> > On 4/26/06, Ian Bicking <ianb at colorstudy.com> wrote:
> >> Thinking about some of these discussions, I decided to explore building
> >> a Python console app, available as a web page. No sandboxing; it's
> >> intended to be run on localhost.
> >>
> >> It's still pretty rough and doesn't have a ton of neat features. The
> >> file management is pretty weak, and doctesting is just stubbed out.
> >>
> >> Anyway, you can get it with:
> >>
> >> easy_install HTConsole
> >
> > I'd really like to get it to work so as to try, but I haven't been
> > able to. Here's what I did, followed by the (complete) error message.
> >
> > =============
> > For those (like me) who don't have easy_install, you apparently find it at:
> > http://peak.telecommunity.com/DevCenter/EasyInstall
>
> Yes, indeed, forgot to mention that. I forgot that RuleDispatch isn't
> in PyPI. Use:
>
> easy_install -f http://peak.telecommunity.com/snapshots/ HTConsole
>
> This tells it where to look for RuleDispatch.
>
Good news: this installed it properly.
Bad news: it does not work here. It starts Firefox (my default browser) at the
http://localhost:8001/
page, which then displays a server error. I've appended below the
entire error message from the console. Unfortunately, I must quit for
the night.
André
==============
C:\Python24\Scripts>htconsole
C:\Python24\lib\site-packages\wareweb-0.1-py2.4.egg\wareweb\wsgiapp.py:58: Depre
cationWarning: httpexceptions.middleware is deprecated; use make_middleware or H
TTPExceptionHandler instead
Serving from: http://localhost:8001
Error - exceptions.TypeError: unbound method compile() must be called with Templ
ate instance as first argument (got nothing instead)
URL: http://localhost:8001/
File 'c:\\python24\\lib\\site-packages\\Paste-0.9-py2.4.egg\\paste\\exceptions\\
errormiddleware.py', line 138 in __call__
app_iter = self.application(environ, detect_start_response)
File 'c:\\python24\\lib\\site-packages\\Paste-0.9-py2.4.egg\\paste\\httpexceptio
ns.py', line 619 in __call__
self.send_http_response, catch=HTTPException)
File 'c:\\python24\\lib\\site-packages\\Paste-0.9-py2.4.egg\\paste\\wsgilib.py',
line 112 in catch_errors_app
app_iter = application(environ, start_response)
File 'c:\\python24\\lib\\site-packages\\Paste-0.9-py2.4.egg\\paste\\session.py',
line 52 in __call__
app_iter = self.application(environ, session_start_response)
File 'c:\\python24\\lib\\site-packages\\Paste-0.9-py2.4.egg\\paste\\recursive.py
', line 54 in __call__
return self.application(environ, start_response)
File 'c:\\python24\\lib\\site-packages\\PasteDeploy-0.5-py2.4.egg\\paste\\deploy
\\config.py', line 157 in __call__
app_iter = self.application(environ, start_response)
File 'c:\\python24\\lib\\site-packages\\Paste-0.9-py2.4.egg\\paste\\urlparser.py
', line 173 in __call__
return application(environ, start_response)
File 'C:\\Python24\\lib\\site-packages\\wareweb-0.1-py2.4.egg\\wareweb\\servlet.
py', line 42 in __call__
File 'C:\\Python24\\lib\\site-packages\\wareweb-0.1-py2.4.egg\\wareweb\\servlet.
py', line 85 in _process
File 'C:\\Python24\\lib\\site-packages\\wareweb-0.1-py2.4.egg\\wareweb\\event.py
', line 19 in replacement_func
File 'C:\\Python24\\lib\\site-packages\\wareweb-0.1-py2.4.egg\\wareweb\\servlet.
py', line 102 in run
File 'C:\\Python24\\lib\\site-packages\\wareweb-0.1-py2.4.egg\\wareweb\\event.py
', line 19 in replacement_func
File 'c:\\python24\\lib\\site-packages\\HTConsole-0.1-py2.4.egg\\htconsole\\site
page.py', line 34 in respond
standard_template = Template.compile(file=base_filename)
exceptions.TypeError: unbound method compile() must be called with Template inst
ance as first argument (got nothing instead)
CGI Variables
-------------
HTTP_ACCEPT: 'text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,t
ext/plain;q=0.8,image/png,*/*;q=0.5'
HTTP_ACCEPT_CHARSET: 'ISO-8859-1,utf-8;q=0.7,*;q=0.7'
HTTP_ACCEPT_ENCODING: 'gzip,deflate'
HTTP_ACCEPT_LANGUAGE: 'en-us,en;q=0.5'
HTTP_CONNECTION: 'keep-alive'
HTTP_HOST: 'localhost:8001'
HTTP_KEEP_ALIVE: '300'
HTTP_USER_AGENT: 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.2)
Gecko/20060308 Firefox/1.5.0.2'
REMOTE_ADDR: '127.0.0.1'
REMOTE_HOST: 'localhost'
REQUEST_METHOD: 'GET'
SCRIPT_NAME: '/'
SERVER_NAME: '127.0.0.1'
SERVER_PORT: '8001'
SERVER_PROTOCOL: 'HTTP/1.1'
Configuration
-------------
doctest_dir: './doctests/'
root_path: 'C:\\Python24\\lib\\site-packages\\htconsole-0.1-py2.4.egg\\htconso
le'
save_dir: './python/'
WSGI Variables
--------------
application: <paste.httpexceptions.HTTPExceptionHandler instance at 0x00DC6B70
>
htconsole.base_url: ''
paste.expected_exceptions: [<class paste.httpexceptions.HTTPException at 0x00B
A65D0>]
paste.httpexceptions: <paste.httpexceptions.HTTPExceptionHandler instance at 0
x00DC6B70>
paste.recursive.forward: <paste.recursive.Forwarder from />
paste.recursive.include: <paste.recursive.Includer from />
paste.recursive.script_name: ''
paste.session.factory: <paste.session.SessionFactory object at 0x00DB4ED0>
paste.throw_errors: True
paste.urlparser.base_python_name: 'htconsole.web'
wsgi process: 'Multithread CGI (?)'
------------------------------------------------------------
>
> --
> Ian Bicking | ianb at colorstudy.com | http://blog.ianbicking.org
>
More information about the Edu-sig
mailing list