PyCharm

What's New in PyCharm 2.0


Major IDE Additions

New Template languages, Cython
and CoffeeScript support

New Frameworks & Tools

New technologies & tools supported
in the new version of the IDE

IDE UI & UX Updates

New features and notable changes
in IDE user interface and usability

Django & Web Dev

Most exciting new features and
tools for Web developers




Major Additions

Mako & Jinja2 Templates

Mako and Jinja2 templates can be used for any PyCharm project now with syntax highlighting, code completion, formatting, quick navigation and Structure view.

Mako Template

Mako Completion

The template format used in the project (Django, Mako or Jinja2) can be selected in Settings | Template Languages.

Select Template

Cython

Cython is a language that allows you to write C extensions for the Python language using the familiar Python syntax.

PyCharm provides Cython support with

  • Syntax highlighting, error checking and code formatting
  • Context-sensitive code completion for Cython keywords, fields of structs, and attributes of extension types

    Cython completion

  • Code navigation and Structure view
  • Quick Usages Search and refactoring tools
  • Code inspections for Cython such as unresolved references detection.

    Cython inspections

In PyCharm you can set up an external tool for compiling your Cython code from the IDE.

CoffeeScript

If you like to be on the cutting edge, PyCharm provides a powerful CoffeeScript editor with features like:

  • Syntax highlighting with error checking,
  • Code completion and coding assistance,

    CoffeeScript: method parameters

  • Code formatting
  • Quick navigation.

Advanced features are also available and include code inspections, usages search and refactorings.

CoffeeScript Usages Search



Frameworks and Tools Support

Code Analysis

Reporting of parameter type mismatch errors in function calls and binary operators (when the types can be inferred, of course);

New inspection to highlight usages of deprecated modules, classes and functions.

IPython

Support for IPython in the built-in Python console

PyPy

PyCharm allows running your applications using PyPy interpreter.

Debugger

Smart Step Into action in the debugger, allowing you to select the call to step into, when the current line contains multiple method calls.

Smart Step Into

Possibility to debug applications that spawn multiple Python processes (for example, Django applications that don't run in --no-reload mode, or applications using many other Web frameworks that use a similar approach to code auto-reloading).

Code Coverage

Code coverage analysis is added based on Ned Batchelder's coverage.py tool.

Run code coverage

Coverage results

Testing

Support for testing frameworks is extended with the attest framework.



IDE User Interface and Usability Updates

Updated UI

IDE UI in general is rethought and reworked to be more convenient and modern.

New user interface

Some specific examples include: Live templates settings, Keymap Editing UI, Plugin Manager, etc.

In-place Refactorings

Improved usability with new in-place UI for Introduce Variable/Constant/Field refactorings.

Inplace refactorings

Multiple Projects in One Window

PyCharm now allows having multiple projects open in a single IDE window.

Multiple projects

Linux
  • GTK+ UI theme improvements.
  • Better integration with docks.
  • Action to create entry in system apps menu.
  • Ability to drag'n'drop and copy/paste files between PyCharm and file managers.
Mac OS X
  • Full-screen support on Mac OS X Lion.
  • Numerous Mac-specific UI changes.
  • Correct window minimization to Dock.
Better Coding Experience

New option allows displaying directory name in the editor tab title for non-unique filenames such as views.py or __init__.py.

Directory in tab

Context Info keyboard shortcut to show the enclosing declaration for the current caret position in the editor.

New Go to Test action, allows you to quickly navigate from a class to its test and back. Also offers an option to create a new test if it does not exist.

Go to test

Option to display fields and inherited members in the Structure view.



Django & Web Development

Latest Web Technologies

For those on a cutting edge in addition to CoffeeScript support PyCharm offers:

  • Updated HTML5 schema,
  • Zen Coding 0.7 support.
JavaScript Unit Testing

Running JavaScript Unit Tests with help of JSTestDriver is now possible via a new IDE plugin.

JavaScript Debugger

The JavaScript debugger is now included into PyCharm and is integrated with the Django server run configuration.

JavaScript Debugger

JavaScript debugging is supported in Mozilla Firefox and Google Chrome browsers.

Internationalization (i18n)

PyCharm provides quick navigation from the text inside of a {% trans %} or
{% blocktrans %} tag in a Django template to the corresponding .po file.

Additionally an intention action is available to wrap a block of text inside a Django template in a {% trans %} or
{% blocktrans %} tag which also immediately extracts the text to the .po file.



Version Control Integration

VCS Support Improvements

General changes to the workflow such as a new 'Digest' view allow spending less time on the routine VCS tasks such as pre-commit review.

Image Diff

You can now compare different image-file versions from version control history in a convenient two-panel view.

Git log graph

Highlights commits included in a given commit (e.g. commits in a current branch) and provides actions like create tag/branch, checkout revision.

Git log view

GitHub

The bundled GitHub integration got even better and now supports Gists creation for sharing your code instantly from the IDE.