DISQUS

DISQUS Hello! benjamingolub.com is using DISQUS, a powerful comment system, to manage its comments. Learn more.

Community Page

Jump to original thread »
Author

friendfeed.py Patch for use on Google App Engine

Started by Benjamin Golub · 1 year ago

Ask and ye shall receive.  Attached is a patch for using friendfeed.py on Google App Engine.  You need to also have demjson available.  Google App Engine does not allow use of many C modules (like cjson) and both json and simplejson will throw decoding errors from time to time. demjson is slow but won’t throw [...] ... Continue reading »

12 comments

  • This is great! Thanks a lot. My own hacked up version was barely functional. :)
  • No problem; mine was hacky too for a long time. The thing that got me was urllib2 will automatically set the correct content-type when POSTing but urlfetch does not. I was stuck on that for hours.
  • Finally got some time to be playing around again - this worked great, I did update the json code to use django's simplejson (I was using that in my original crappy friendfeed.py :) - but other than that it was as you patched it and everything was smooth sailing.
  • Glad it's working for you; let me know if you have any trouble.
  • Great! This is something I've been waiting for. I hacked around it to get simple retrieval to work but I think I'll go ahead and replace my code with this.
  • Let me know how it works out for you.
  • HI,
    thank you very much for this patch, however, I got this error trying to use it:

    from django.utils import urlencode
    ImportError: cannot import name urlencode
  • Are you sure you have Django in your python path? You might also need to
    use Django trunk; I have not tested this using the version included in
    Google App Engine (which is .96 and very far away from trunk). This link (
    http://code.google.com/appengine/articles/djang...) tells you how to use
    trunk on GAE.

    Good luck!
  • Thank you very much, I too think that the problem come from Django, I tried using GAE SDK, without importing anything from Django, may I re-think about how to implement things in my project again.

    I havn't used Django as a framework before , even not think to associate it with GAE, for the moment I am trying webpy as a frame work.

    may be the solution is just to import the "django.utils.http import urlencode" I mean to include http to django utils in GAE.

    again thank you very much for your help and for the links.
  • HI, just to point that I found a tweak for my case , I mean a patch for non django framework users:

    1) download the following files :

    1-1)http
    1-2)encoding
    1-3)functional

    from :
    http://code.djangoproject.com/browser/django/br...

    adding those file to the project and it work, again thank you for this patch.
  • I should've taken the time to search before hacking my own version. Need to go back and apply your urlencode fix though. Thanks.

    http://adamloving.com/2008/07/22/changes-to-fri...

Add New Comment

Returning? Login