Wednesday, November 2, 2016

Some Ways to Debug Django

Analysis of different methodologies.  One may choose different methods based on what works best for them in their scenario.

How one developer debug's in Django




Video/Standard methods used:


  1. python print statements
  2. django_extensions documentation: https://django-extensions.readthedocs.io/en/latest/
  3. Werkzueg Debugger Documentation: https://pypi.python.org/pypi/Werkzeug

Visual Studio Code

Can be used for both editing with code completion, code snippets and debugging: https://code.visualstudio.com/docs/languages/python
VS code also has GIT built-in to it's IDE.

Visual Studio 2015 Community Edition:

Can be sued for creating projects, python virtual environments, editing with code completion, code snippets and debugging.  Would be nicer to use this method if you have TFS and GIT as project management/source control standard.

  1. Django and MySQL on Assure with VS 2.2: 
  2. Visual Studio Community Edition installer: https://www.visualstudio.com/vs/community/
  3. PTVS - Python Tools for Visual Studio can be downloaded here: https://pytools.codeplex.com/releases/view/10970 Note: it's for 2013, one should be prepared to roll-back after install, if you have issues.  The first time I installed this I had to rollback my system.  It could've been system related.