Video Streaming with Flask

I'm sure by now you know that I have released a book and a couple of videos on Flask in cooperation with O'Reilly Media. While the coverage of the Flask framework in these is fairly complete, there are a small number of features that for one reason or another did not get mentioned much, so I thought it would be a good idea to write articles about them here.

This article is dedicated to streaming, an interesting feature that gives Flask applications the ability to provide large responses efficiently partitioned in small chunks, potentially over a long period of time. To illustrate the topic I'm going to show you how to build a live video streaming server!

7 comments

The Flask Mega-Tutorial: Now with Python 3 Support

After more than a year working on various projects on the side of my day job, I have now found some time to rest and return to the blog, which I haven't cared for much during this time.

The number one problem I see from my readers is issues when trying to follow my Flask Mega-Tutorial using current versions of Flask, its extensions, or Python 3. In this article I quickly describe the updates I have made to the tutorial.

5 comments

Using Flask-Babel with Flask 0.10

One of the interesting problems that I had to address when porting my Flask Mega-Tutorial to Flask 0.10 was in supporting Flask-Babel. There is an issue when a "lazy" text generated with the lazy_gettext function is flashed. This issue was reported more than a year ago and hasn't been addressed yet.

In this short post I will show you how I solved this issue for the Mega-Tutorial, as this solution is applicable to any Flask project.

8 comments

The Rackspace Cloud API

Most of you know by now that not too long ago I joined Rackspace. As you can imagine, I am now learning tons of new things as I familiarize myself with all the OpenStack projects, none of which I have used before.

In this article I'm going to show you a few ways to work more efficiently with your Rackspace cloud account (or any OpenStack cloud for that matter). I will begin with the introduction of a command line tool that you can use to manage your cloud servers, and then go even lower level and show you how you can do the same thing using a Python SDK. To end this article I'm going to show you a complete script that creates a cloud server, configures it as a Web server and deploys a Flask application to it, all completely unattended.

My Flask Web Development Book is Out!

Posted by Miguel Grinberg under Python, Flask.

It was a long wait, but my book is finally here! You can now buy Flask Web Development at most online bookstores, and if you are lucky you may also spot it at some brick and mortar retailers.

With the book out in the wild I thought an update is in order. In this post I will give you a summary of what I have done so far with regards to Flask training, and will conclude with the next projects that will be coming in the near future.

17 comments

Watch Live Video of Earth on your Raspberry Pi

A few weeks ago NASA started streaming live video of Earth from cameras installed aboard the International Space Station (ISS), and some of the views are nothing short of breathtaking. If you haven't seen this stream yet, then stop reading and go watch it now. Keep in mind that you have a 50% chance of catching the dark part of the planet, so if all you find is an all black image then try again a little later. You can always check isstracker.com to find out over which region the ISS is over and if it is day or night there.

I thought it would be a cool idea to have this stream running constantly on a screen by my desk. Something I can keep an eye on while I work, so that I can catch the most interesting views without having to have it constantly taking space on my main computer's screens.

In this short article I'm going to show you how to play the ISS live stream on your Raspberry Pi.

3 comments

Easy Web Scraping with Python

A little over a year ago I wrote an article on web scraping using Node.js. Today I'm revisiting the topic, but this time I'm going to use Python, so that the techniques offered by these two languages can be compared and contrasted.

21 comments

Easy WebSockets with Flask and Gevent

This weekend I decided to take a short vacation from my book writing effort and spend time on a project I wanted to work on for a long time. The result of this effort is a brand new Flask extension that I think is pretty cool.

I'm happy to introduce Flask-SocketIO, a very easy to use extension that enables WebSocket communications in Flask applications.

166 comments

Fun With The Arduino Esplora: A Digital Picture Frame

Posted by Miguel Grinberg under Arduino, C++.

With this article I kick off my series on the Arduino Esplora board. Today's project is a nice (and cheap!) little digital picture frame that uses the Esplora's TFT Screen add-on.

4 comments

Flask Book and PyCon Update

With my book already available for pre-order at Amazon.com I thought an update is in order.

19 comments