Skip to main content
This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

Create and use django-integrator compliant applications.

Project Description

Django Integrator

What is it?

  • A library to conveniently import and use an integrator compliant applications.
  • A tool for starting a new Django project with the focus on creating a distributable application.

What problem does it solve?

An integrator compliant distributable application contains its own settings and url file, which using the library can than be imported into the main settings file. This way the main settings file can be kept relatively clean and simple thus being more the ‘server’ part of the Django install. This made it easier for me to split my django project out in several different applications, which improved modularity, maintainability and readability.

How do I install it?

pip install django-integrator

How do I use it?

As stated above there are two use cases, create and library.

Create

To create a new project go to the folder where you want the new project to be created in. Then issue the command: $ django-integrator-create pypi_name django_app_class_name verbose_name author email The parameters mean the following:

pypi_name:
The name of this application as it would be in the PyPI register, the program will do a query to determine if the name is available (at the time). The actual importable name will be the pypi_name with ‘-‘ replaced with underscores.
django_app_class_name:
The name that the application class (as in the apps.py) will have in Django.
verbose_name:
The name as the app will be displayed in, for example, the admin interface.
author:
Your name
email:
Your email address

This will create a new project, with some additional files and adjusted layouts compared to the default django one. Most notably, the interface folder contains only just enough to get wsgi server set. The rest is stored in the app folder. There is also a script calls devset.py which removes the current sqlite db, deletes the lates migration file, recreates migration file, set the admin user up with password admin and starts a development server.

The settings file in the app folder mirrors layout wise the same as the ‘normal’ settings file with the exception that there is some extra logic for certain configurations like middleware. Sometimes it is import that certain middleware are imported before another one. To achieve this just put your middleware in followed by the middleware it must precede. The library will detect that the middleware already exist and will add your middleware before that one.

Furthermore it also creates a setup.py file, which can be used as a base to upload the app to PyPi.

Library

At the end of the inteface.settings file you see the following lines:

>>> import django_integrator
>>> django_integrator.add_application('your_app_name')

To add more applications to your system simply repeat the last line. URL wise you can see that in interface.urls the following lines are at the end:

>>> import django_integrator
>>> django_integrator.add_urlpatterns(urlpatterns)

This will add all the applications urls to the server urls file, be careful as this will overwrite previous defined urls if the path clashes.

What license is this?

Two-clause BSD

How can I get support?

Please use the repo’s bug tracker to leave behind any questions, feedback, suggestions and comments. I will handle them depending on my time and what looks interesting. If you require guaranteed support please contact me via e-mail so we can discuss appropriate compensation.

Signing Off

Is my work helpful or valuable to you? You can repay me by donating via:

https://paypal.me/MartinHellwig

-or-

https://www.patreon.com/hellwig

Thank you!

Release History

Release History

This version
History Node

1.1.1.1

History Node

1.1.0.1

History Node

1.0.1.3

History Node

1.0.1.2

History Node

1.0.1.1

History Node

1.0.0.10

History Node

1.0.0.9

History Node

1.0.0.8

History Node

1.0.0.7

History Node

1.0.0.6

History Node

1.0.0.5

History Node

1.0.0.4

History Node

1.0.0.3

History Node

1.0.0.2

History Node

1.0.0.1

History Node

0.9.3

History Node

0.9.2

History Node

0.1.9

History Node

0.1.8

History Node

0.1.7

History Node

0.1.5

History Node

0.1.3

History Node

0.1.1

History Node

0.1.0

Download Files

Download Files

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

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
Django-Integrator-1.1.1.1.tar.gz (10.4 kB) Copy SHA256 Checksum SHA256 Source Aug 11, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting