Posts Tagged ‘django’

Allow your visitors to sign in via Twitter, Facebook, FriendFeed, OpenID, and OAuth with django-socialregistration

Wednesday, October 28th, 2009


The title says it all. Allow your visitors to sign in via Twitter, Facebook, FriendFeed, OpenID, and OAuth with django-socialregistration. Hence the name, “social registration”. I’ve been tinkering with this module and I’ve just got the Twitter OAuth login/registration to work. It’s pretty neat!

You know how much you loathe having to register/sign-up for yet another new service, just to try it? Well, as a site owner, it’s really in your best interest to lower the bar for the public to figure out if they want to use your service. Make it as frictionless as possible.

The README provides all the instructions you need, except one thing: you must explicitly tell Django’s authentication process to also check the socialregistration module’s authentication backend

In other words, in your settings.py:

AUTHENTICATION_BACKENDS = (

    # this is the default backend, don't forget to include it!
    'django.contrib.auth.backends.ModelBackend', 

    # this is what you're adding for using Twitter
    'socialregistration.auth.TwitterAuth', 

    'socialregistration.auth.FacebookAuth', # Facebook

    'socialregistration.auth.OpenIDAuth', # OpenID

    )

You can either add it in your settings.py or global_settings.py (mine’s in /usr/local/lib/python2.6/dist-packages/django/conf/ )
(more…)

A change in direction: Python, Django, and Google App Engine

Saturday, June 13th, 2009

This is a cross-post from my other for-own-use developer blog. I’m posting it here because people often ask me what I’m so busy with.

It’s been a while since my last post; I have been real busy. Anyway, just to quickly say this, I’ve made a change in direction in my development efforts.

I’ve said earlier that I am determined learn a new programming language this year because my brain is starting to rot, but have since decided a few months ago that it will not be Cocoa Touch, for various reasons: too niche (the emerging global mobile apps market is highly fragmented by Nokia, iPhone, Android, Crackberry and possibly Palm as a viable contender), and skills here only attacks a small piece of my larger effort, which my gut tells me it’s a task that could probably be farmed out and done cheaper/faster by outsourcing to a iPhone dev shop where Cocoa Touch is their core competency.

A mobile app that does not utilize any connectivity, nay, “intelligent” connectivity, is not much different from calc.exe on your WinXP desktop. It’s fine for a narrow and specific, uninteresting task. An interesting mobile app would tap the cloud for some form of intelligence. Why not leverage that mandatory data plan from AT&T for your iPhone?

When the time comes, if necessary (such as if the iPhone app will be an important part of my competitive advantage), then I’ll pick up Cocoa Touch myself. For now, I do not think that will be the case, thus I’m going to spend more time on laying the groundwork for the more important piece: the back-end, web 2.0 / cloud computing / SaaS piece. And as Microsoft knows, as Tim O’Reilly says – nobody with their right mind would bet against the Web! (Have you seen HTML5?)

The past month or two, I’ve tried real hard to squeeze time in to learn Python, Django and Google App Engine – all at the same time in parallel, not sequentially. Yes, I’m trying to rush – because I am impatient.
(more…)