See Python, See Python Go, Go Python Go

Andrey Petrov is the author of urllib3, the creator of Briefmetrics and ssh-chat, and a former Googler and YCombinator alum. He’s here to tell us of a dangerous expedition his requests undertook, which sent them from Python, through the land of C, to a place called Go (and back again).

Today we're going to make a Python library that is actually the Go webserver, for which we can write handlers in Python. It makes Python servers really fast, and—more importantly—it’s a bit fun and experimental. This post is a more detailed overview of my PyCon 2016 talk of the same title. If you'd like to play along at home, this code was written in Go 1.6 and Python 3.5 and the entire complete...

Read more →

Finally, Real-Time Django Is Here: Get Started with Django Channels

Django Channel header

Today, we're thrilled to host Jacob Kaplan-Moss. Jacob's a former Herokai and long-time core contributor to Django, and he's here to share an in-depth look at something that he believes will define the future of the framework.

When Django was created, over ten years ago, the web was a less complicated place. The majority of web pages were static. Database-backed, Model/View/Controller-style web apps were the new spiffy thing. Ajax was barely starting to be used, and only in narrow contexts.

The web circa 2016 is significantly more powerful. The last few years have seen the rise of the so-called “real-time” web: apps with much higher interaction between clients and servers and...

Read more →

Django 1.9's Improvements for Postgres

A big update to the beloved Python web framework known as Django was released recently: Django 1.9. This release contains a long list of improvements for everything from the graphical styling of the admin to the ability to run your test suite in parallel.

Our favorite improvements to the framework were, of course, all about our favorite database: Postgres. Here are some of the highlights from the official release notes (highly recommended reading).

Renamed PostgreSQL Back-end

Django's fantastic built-in Postgres database back-end received a nice name change. Previously known as django.db.backends.postgresql_psycopg2, the back-end will now be officially available as the much easier...

Read more →

Securing Celery on Heroku

Celery is by far the most popular library in Python for distributing asynchronous work using a task queue. If you're building a Python web app, chances are you already use it to send email, perform API integrations, etc. Many people choose Redis as their message broker of choice because it's dead simple to set up: provision a Redis addon, use its envrionment variable as your BROKER_URL, and you're done. But the simplicity of Redis comes at a cost. Redis does not currently support SSL, and it doesn't seem like that's going to change any time soon. Because Heroku add-ons communicate over the public web, that means the contents of Celery jobs are traveling unencrypted...

Read more →

Waza 2013: How Ecosystems Build Mastery

When we think of the concept of Waza (技) or "art and technique," it's easy to get caught up in the idea of individual mastery. It's true that works of art are often created by those with great skill, but acquiring that skill is neither solitary nor static. Generations of masters contribute to a canon and it is in that spirit that we built the Heroku platform and the Waza event. This year's Waza was no exception.

On February 28th, more than 900 attendees participated in Waza including Ruby founder Yukihiro "Matz" Matsumoto, Django co-creator Jacob Kaplan-Moss and Codeacademy’s Linda Liukas. True to form, we offered you a platform for experimentation and...

Read more →

Browse the blog archives, subscribe to the full-text feed, or visit the engineering blog.