Skip to main content

A simple application that helps displays various debug information about the Django project

Project description

# django-debug-informer

[![Build Status](https://api.travis-ci.org/Gr1N/django-debug-informer.png "Build Status")](https://travis-ci.org/Gr1N/django-debug-informer)

The Django Debug Informer is a simple application that helps displays various debug information about the Django project. It works on Django 1.9.x and Python 3.5.x.


# Installation

Install the Debug Informer using [pip](http://www.pip-installer.org/):

% pip install django-debug-informer

And add `debug_informer` to your `INSTALLED_APPS` setting:

INSTALLED_APPS = (
# ...
'debug_informer',
)

Add `DebugInformerHeadersMiddleware` to your `MIDDLEWARE_CLASSES` setting:

MIDDLEWARE_CLASSES = [
# ...
'debug_informer.middleware.DebugInformerHeadersMiddleware',
]

Include the application urls into your project root urlconf:

urlpatterns = [
# ...
url(r'^djdi/', include('debug_informer.urls', namespace='djdi')),
]

Enjoy!

# Usage

Get Python version:

% curl -v http://127.0.0.1:8000/djdi/versions/python/
...
< HTTP/1.0 200 OK
< Content-Type: application/json
< X-DI-Backend-Host: backend-host.local
< X-DI-Backend-Pid: 11137
< X-DI-Backend-Start-At: 2016-01-31T10:45:24.486301
...
{
"name": "Python",
"version": "3.5.1 (default, Dec 7 2015, 21:59:10) \n[GCC 4.2.1 Compatible Apple LLVM 7.0.0 (clang-700.1.76)]"
}

Get packages versions:

% curl -v http://127.0.0.1:8000/djdi/versions/packages/
...
< HTTP/1.0 200 OK
< Content-Type: application/json
< X-DI-Backend-Host: backend-host.local
< X-DI-Backend-Pid: 11137
< X-DI-Backend-Start-At: 2016-01-31T10:45:24.486301
...
{
"list": [
{
"name": "Django",
"version": "1.9.1"
},
{
"name": "pip",
"version": "8.0.2"
},
{
"name": "pluggy",
"version": "0.3.1"
},
{
"name": "py",
"version": "1.4.31"
},
{
"name": "setuptools",
"version": "12.0.5"
},
{
"name": "tox",
"version": "2.3.1"
},
{
"name": "virtualenv",
"version": "14.0.3"
}
],
"total": 7
}

Get version for package:

% curl -v http://127.0.0.1:8000/djdi/versions/package/Django/
...
< HTTP/1.0 200 OK
< Content-Type: application/json
< X-DI-Backend-Host: backend-host.local
< X-DI-Backend-Pid: 11137
< X-DI-Backend-Start-At: 2016-01-31T10:45:24.486301
...
{
"name": "Django",
"version": "1.9.1"
}

Specified package not found:

% curl -v http://127.0.0.1:8000/djdi/versions/package/awesomepackage/
...
< HTTP/1.0 404 NOT FOUND
< Content-Type: application/json
< X-DI-Backend-Host: backend-host.local
< X-DI-Backend-Pid: 11137
< X-DI-Backend-Start-At: 2016-01-31T10:45:24.486301
...
{}


# License

*django-debug-informer* is licensed under the MIT license. See the license file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-debug-informer-0.3.0.zip (12.9 kB view details)

Uploaded Source

File details

Details for the file django-debug-informer-0.3.0.zip.

File metadata

File hashes

Hashes for django-debug-informer-0.3.0.zip
Algorithm Hash digest
SHA256 2ef70a73b85eb13e7b6e9c7b8b63fcd4fcc178f8ddfaf44ad95481717630c5f2
MD5 eb374f2fd14ab9a024b3b8694b2d80c0
BLAKE2b-256 9c688bb972a1378e7626d8ab6f2d88cd5102f86594b1709f4f53bd14d905fa55

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page