DZone
Web Dev Zone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
  • Refcardz
  • Trend Reports
  • Webinars
  • Zones
  • |
    • Agile
    • AI
    • Big Data
    • Cloud
    • Database
    • DevOps
    • Integration
    • IoT
    • Java
    • Microservices
    • Open Source
    • Performance
    • Security
    • Web Dev
DZone > Web Dev Zone > Tools for Better Python

Tools for Better Python

Fredrik Håård user avatar by
Fredrik Håård
·
Jan. 25, 12 · Web Dev Zone · Interview
Like (0)
Save
Tweet
2.71K Views

Join the DZone community and get the full member experience.

Join For Free
TL;DR
pip install virtualenv pylint ipython autohook

Tools I use every day to write better Python, to make it more fun, or just easier:

  • A good editor: I prefer Emacs, you might like something else, but trust me on this - it’ll be a humongous project that forces you to use a full IDE. If you stay clear of large web frameworks, you might never need it. I started out using PyDev since I was used to Eclipse, but now I just don’t think its worth the complexity and overhead.
  • virtualenv: I use my virtualenvs for more than just Python these days, and setting a new environment up is the first thing I do when starting a new project.
  • pylint: Not only does it tell you what you might want to fix in your code, it tells you if your code gets better or worse. The more unsure you are, the more you should use pylint.
  • ipython: While REPL is nice, iPython is truly awesome for testing and prototyping. For me, its gradually replacing bash as well.
  • unittest/unittest2: Python comes with built-in unit test support - use it (where appropriate)!


These are the tools I use in almost any project, and recently I’ve added one of my own:

  • autohook, to run pylint/unit tests on commit to Mercurial


Finally, I’d like to point anyone starting out with Python to the excellent introduction set up by Mir Nazim at his site.

 

Source: http://blaag.haard.se/Tools-for-better-Python/

Python (language)

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • Is Your Code DRY or WET?
  • 5 Best JavaScript Web Development Frameworks
  • Practice on Pushing Messages to Devices of Different Manufacturers
  • No-Code/Low-Code Use Cases in the Enterprise

Comments

Web Dev Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • MVB Program
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends:

DZone.com is powered by 

AnswerHub logo