http://opensourcebroadcasting.appspot.com/pledgedrives/
When submitting one specific "session_organization_id_form"
I receive the following:
AttributeError: 'module' object has no attribute 'dumps'
For the full traceback, see:
http://pastie.textmate.org/767257.txt
The code for the form itself can be found here:
http://code.google.com/p/pledgedrivetracker/source/browse/pledgedrives/controllers/default.py#84\
Any suggestions on what exactly is failing and how this could be
resolved is appreciated.
Thanks!
organization = db
(db.organization.id==session.organization_id).select()
session.organization = organization
you are storing a Rows object in the session and that should not be
done.
we manage to make it work (partially) without GAE but the retrieved
object is not the same as the original.
it does not work on GAE because marshal.dumps does not exist on GAE.
If you really need to do this try:
organization = db
(db.organization.id==session.organization_id).select()
session.organization = organization.as_list()
it will store the Rows as a list of normal dictionaries.
On Jan 5, 4:57 am, johntynan <jgty...@gmail.com> wrote:
> I have a web2py app that runs well under web2py, as well as within the
> GAE development server, however, after updating the app, and then
> testing this on the production server here:
>
> http://opensourcebroadcasting.appspot.com/pledgedrives/
>
> When submitting one specific "session_organization_id_form"
>
> I receive the following:
>
> AttributeError: 'module' object has no attribute 'dumps'
>
> For the full traceback, see:
>
> http://pastie.textmate.org/767257.txt
>
> The code for the form itself can be found here:
>
> http://code.google.com/p/pledgedrivetracker/source/browse/pledgedrive...
I have one quick follow up question.
When using the following code:
form=SQLFORM(db.table)
if FORM.accepts(form,request.vars):
session.form_vars=form.vars
as you had suggested here:
I am able to add the form variables to a session.
However, I would like to now save the form.vars in a session variable
as a list of dictionaries as well. Just for grins I tried
session.form_vars=list(dict(form.vars))
do you have any suggestions for how I might get this this to work?
On Jan 5, 7:44 am, mdipierro <mdipie...@cs.depaul.edu> wrote:
> The problem is here:
>
> organization = db
> (db.organization.id==session.organization_id).select()
> session.organization = organization
>
> you are storing a Rows object in the session and that should not be
> done.
> we manage to make it work (partially) without GAE but the retrieved
> object is not the same as the original.
> it does not work on GAE because marshal.dumps does not exist on GAE.
> If you really need to do this try:
>
> organization = db
> (db.organization.id==session.organization_id).select()
> session.organization = organization.as_list()
>
> it will store the Rows as a list of normal dictionaries.
>
session.form_vars=dict(form.vars)
have you tried it?
On Jan 7, 2:56 pm, johntynan <jgty...@gmail.com> wrote:
> Thanks Massimo! This works perfectly.
>
> I have one quick follow up question.
>
> When using the following code:
>
> form=SQLFORM(db.table)
> if FORM.accepts(form,request.vars):
> session.form_vars=form.vars
>
> as you had suggested here:
>
> http://groups.google.com/group/web2py/browse_thread/thread/b3508f4a9b...