Alec,

The Openshift environment won't have the google libs in it's python 
runtime. Check that you're using a non GAE db in your model. If you could 
provide a link to a pastebin of your model, I'd be happy to take a look.

Regards,
Andrew

On Wednesday, August 15, 2012 11:44:34 PM UTC-5, Alec Taylor wrote:
>
> Following this tutorial requires I put a `session` variable in the 
> constructor.
>
>
> http://www.web2pyslices.com/slice/show/1541/integrating-linkedin-with-web2py
>  
>
> Pushing that to OpenShift gives me:
>
> <type 'exceptions.ImportError'> No module named google.appengine.api
> TRACEBACK
>
> 1.
> 2.
> 3.
> 4.
> 5.
> 6.
> 7.
> 8.
> 9.
> 10.
> 11.
> 12.
> 13.
> 14.
> 15.
> 16.
> 17.
> 18.
> 19.
>
> Traceback (most recent call last):
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/restricted.py",
>  line 205, in restricted
>     exec ccode in environment
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/wsgi/web2py/applications/silicon/models/db.py",
>  line 61, in <module>
>     + '/user/verify'#(request.vars._next or '')
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/contrib/login_methods/linkedin_account.py",
>  line 18, in __init__
>     self.session.linkedin.request_token()
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/contrib/login_methods/linkedin.py",
>  line 159, in request_token
>     response = self._https_connection(method, relative_url, query_dict)
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/contrib/login_methods/linkedin.py",
>  line 786, in _https_connection
>     return self._https_connection_gae(method, relative_url, query_dict, body)
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/contrib/login_methods/linkedin.py",
>  line 807, in _https_connection_gae
>     from google.appengine.api import urlfetch
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/custom_import.py",
>  line 293, in __call__
>     fromlist, level)
>   File 
> "/var/lib/stickshift/839015ac47324ba8b669b14e4cf8d190/app-root/runtime/repo/libs/gluon/custom_import.py",
>  line 78, in __call__
>     level)
> ImportError: No module named google.appengine.api
>
>
> I'm guessing this is a bug.
>
> Could you please fix this?
>
> Thanks,
>
> Alec Taylor 
>

-- 



Reply via email to