Getting closer. I added the following init-param to my web.xml

    <init-param>
      <param-name>python.path</param-name>
      <param-value>c:\temp\webapp\WEB-INF\lib\Lib;c:\temp\webapp
\web2py</param-value>
    </init-param>

and based off of one of deha's post found that Jython has no signal
module so I stole the one from:
http://twistedmatrix.com/trac/attachment/ticket/3413/signal.py

I have my original layout as defined in the post above (ie. no web2py
in WEB-INF/*  just in webapp)

Unfortunately now I get:

java.lang.IllegalArgumentException: Unknown signal: QUIT

so I'm going to muck around with the signal.py file since I'm on a
windows platform I figure I'll have to modify the signals
accordingly.

-Andrew

On Nov 11, 2:34 pm, Andrew <[EMAIL PROTECTED]> wrote:
> I'm able to deploy fine but when I try to hit the application I
> receive:
>
> Traceback (most recent call last):
>   File "c:\temp\webapp\WEB-INF\lib\modjy.jar\modjy.py", line 76, in
> service
>   File "c:\temp\webapp\WEB-INF\lib\modjy.jar\modjy_exceptions.py",
> line 91, in handle
> modjy_exceptions.NoCallable: Error loading jython callable 'handler':
> No module named gluon
>
> Initially my layout looked like the following:
>
> c:\temp\webapp
>                 |__WEB-INF
>                 |         |__web.xml
>                 |         |___lib
>                 |                |__modjy.jar
>                 |                |__jython-complete.jar
>                 |                |__Lib
>                 |__web2py
>                          |__(web2py src structure with gluon etc)
>                          |__application.py
>
> application.py looks like:
>
> import os
> from gluon.main import wsgibase
>
> def handler(environ, start_response):
>     return wsgibase(environ, start_response)
>
> I've tried copying the web2py folder to WEB-INF/lib as well as copying
> the contents of the web2py folder to WEB-INF/lib.
>
> I wasn't sure where to set python path but I'm thinking maybe as a
> param / init value in the web.xml for the modjy servlet as defined 
> in:http://modjy.xhaus.com/params.html
> I'll give that a shot.
>
> If you see anything out of place here let me know :)
>
> Thanks,
> Andrew
>
> On Nov 11, 11:50 am, mdipierro <[EMAIL PROTECTED]> wrote:
>
> > Absolutely. I am very exited by seeing web2py on jython. That would be
> > a very big step.
>
> > # in Django from your link
>
> >     import os
> >     from django.core.handlers import wsgi
> >     os.putenv("DJANGO_SETTINGS_MODULE", "mysite.settings")
> >     def handler(environ, start_response):
> >     h = wsgi.WSGIHandler()
> >     return h(environ, start_response)
>
> > # in web2py there are no setting
>
> >     from gluon.main import wsgibase
> >     return wsgibase(environ, start_response)
>
> > # make sure the web2py folder is in your python path
>
> > let me us know how things progress!
>
> > Massimo
>
> > On Nov 11, 11:37 am, Andrew <[EMAIL PROTECTED]> wrote:
>
> > > I'm trying to get Web2Py working in glassfish via the new Jython 2.5
> > > beta (www.jython.org) and was following the same approach that Frank
> > > outlines 
> > > here:http://fwierzbicki.blogspot.com/2008/04/jython-and-django-progress-pa...
>
> > > I'm stuck at the point where you setup the application.py and was
> > > wondering if A) this approach could even work with web2py the way it
> > > does with django  and B) if anyone could assist me with how the
> > > application.py would look?
>
> > > Any help is greatly appreciated :)
>
> > > TIA,
> > > Andrew
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to