Making Django Play Nice with Third Party Services


DjangoCon 2013

Matt Makai / @mattmakai

Why Care?

  • Your app, your responsibility
  • Service usage is increasing
  • Little effort to prevent big headaches

What You Will Learn

  • Discover new services
  • Evaluate objectively
  • Integrate properly with Django
  • Maintain your sanity

Third Party Service Usage

Discover

Discover Services

Mindset

  • Research when not under pressure to immediately integrate
  • Ask "What problem can this service potentially solve?"

Mindset

  • Background and philosophy
  • Openness about their solution approach
  • Bookmark services and arguments for and against

"Push" sources

Heroku Addons

Geckoboard Widgets

Ducksboard Integrations

Evaluate

Evaluate Services

Platform

  • Language tutorials provided?
  • Platform ecosystem?
  • Developer evangelists?
  • Data gravity?
  • StackExchange or forum discussions?

Twilio

  • Tutorials in Python
  • Platform built on Python
  • Open source Django application examples
  • Developer evangelists active in Python community

Twilio open source examples

Stripe

  • Payment processing
  • Tutorials in Ruby, Python, PHP
  • Ruby & CoffeeScript platform
  • Third party open source Django application examples

Stripe tutorial

Intercom

  • Customer engagement
  • Ruby on Rails platform
  • Third party open source Django application examples
  • Long term viability?

Intercom open source

Integrate

Integrate Services

Integration Paths

  • First-party binding
  • Open source binding
  • libsaas
  • Requests

First-party binding

  • Ideal
  • Age? Update frequency?
  • Pull request incorporation speed
  • Outstanding issues

Official GitHub binding?

Third-party binding

  • Age? Update frequency?
  • Pull request incorporation speed
  • Outstanding issues
  • Company backing?

Third-party binding

Print repos

libsaas

Print repos

Requests

Print (public) Repos

Maintain

Maintain Services

Project README / docs

  • What services are used?
  • How are the services tested locally?
  • Who controls the user names and passwords?
  • Do the services cover full range of purposes? (debugging, user engagement, payments, etc)

Environment variables

Local env variable setting

Testing services

  • Separate tests
  • Custom test runner
  • Break build? Or alert?
  • unittest2 @if-skip decorator

PyPi Notifications

Resources

Resources

Thank you!


codingacrossamerica.com

?