For the "clearing" process
HTML Python Shell
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
static Apple Icon Feb 25, 2015
.gitignore remove pyc files Feb 25, 2015 Added two questions from group phone call. Mar 11, 2015

Question of the Day

The App

Creative Commons License
Question of the Day by is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.

Getting Started with Python on Heroku

(Adapted from

First, make sure you have the latest version of pip:

	python -m pip install -U pip

Next, make sure you have virtualenv installed:

	virtualenv --version

If this gives you an error message, run:

	pip install virtualenv

Run Locally

  1. Setup virtualenv

     virtualenv venv --distribute
  2. Activate virtualenv:


     source venv/bin/activate

    Windows (you can also just type "go"):

  3. Get the deps:

     pip install -r requirements.txt
  4. Start Flask Server

  5. Test out the app


Run on Heroku

  1. Create the app

     heroku create -s cedar
  2. Deploy the app

     git push heroku master
  3. Open the app in your browser

     heroku open

Nicer alternative:

Log onto, then follow the instructions to connect to your github repository and launch your app. This can include auto-deployment every time you update your Github repository!


  • When you change, Flask's automatic refresh doesn't work. You have to kill it and restart it to see the results. The refresh only seems to work on templates.
  • On Android, open the url in your browser, then from the browser menu choose "Add to home screen." This will add an icon for the app to your device home screen.
  • On iOS (iPhone, iPad) you must use Safari to get an icon on the home screen. Open in Safari, then select the box with the arrow coming out of it, then choose "add to home screen."