Full Stack Python

# Development Environments

A development environment is a combination of a text editor and the Python interpreter. The text editor allows you to write the code. The interpreter provides a way to execute the code you've written. A text editor can be as simple as Notepad on Windows or more complicated as a complete integrated development environment (IDE) such as PyCharm which runs on any major operating system.

## Why is a development environment necessary?

Python code needs to be written, executed and tested to build applications. The text editor provides a way to write the code. The interpreter allows it to be executed. Testing to see if the code does what you want can either be done manually or by unit and functional tests.

## A development environment example

Here's what I (the author of Full Stack Python, Matt Makai) use to develop most of my Python applications. I have a Macbook Pro with Mac OS X as its base operating system. Ubuntu 14.04 LTS is virtualized on top with Parallels. My code is written in vim and executed with the Python 2.7.x interpreter via the command line. I use virtualenv to create separate Python interpreters with their own isolated application dependencies and virtualenvwrapper to quickly switch between the interpreters created by virtualenv.

That's a common set up but you can certainly write great code with a much less expensive set up or a cloud-based development environment.

## Open source development environments

- vim is my editor of choice and installed by default on most *nix systems.

- emacs is another editor often used on *nix.

- PyDev is a Python IDE plug in for Eclipse.

- Sublime Text versions 2 and 3 (currently in beta) are popular text editors that can be extended with code completion, linting, syntax highlighting and other features using plugins.

- Atom is an open source editor built by the GitHub team.

## Python-specific IDEs

- PyCharm is a Python-specific IDE built on JetBrains' platform. There are free editions for students and open source projects.

- Wing IDE is a paid development environment with integrated debugging and code completion.

- Komodo

## Hosted development environment services

In the past couple of years several cloud-based development environments have popped up. These can work great for when you're learning or stuck on a machine with only a browser but no way to install your own software. Most of these have free tiers for getting started and paid tiers as you scale up your application.

- Nitrous.io

- Cloud9

- Terminal

- Koding

## Development environment resources

- If you're considering the cloud-based development environment route, check out this great article comparing Cloud9, Koding and Nitrous.io by Lauren Orsini. She also explains more about what a cloud IDE is and is not.

- Real Python has an awesome, detailed post on setting up your Sublime Text 3 environment as a full-fledged IDE.

- The Hitchhiker's Guide to Python has a page dedicated to development environments.

- Choosing the best Python IDE is a review of six IDEs. PyCharm, Wing IDE and PyDev stand out above the other three in this review.

- PyCharm: The Good Parts shows you how to be more efficient and productive with that IDE if it's your choice for writing Python code.

- Learn Vim Progressively is a wonderful tutorial that follows the path I took when learning Vim: learn just enough to survive with it as your day-to-day editor then begin adding more advanced commands on top.

Let me start over from the Full Stack Python introduction.

Show me a list of the best Python learning resources.

I want to get started coding a Python web app.

#### Interested in major updates to this site or an alert when a complete Full Stack Python book with detailed example code is released? Sign up here and you'll an occasional email only when there's big news to report.