V
V
Valery Semenov2013-05-22 10:31:06
Django
Valery Semenov, 2013-05-22 10:31:06

What is the correct way to create a django module as a pypi package?

To create a pypi package, you need to create a git project in a separate folder, specify the necessary settings, register ... this is all clear.
But what is the proper way to create a package that is a django module. In a separate directory, you cannot create a module without django itself, you cannot debug it. It is necessary, along with the package being created, to initialize django. But when registering and updating, you will need to delete unnecessary files. So right? Yes, and somehow it is not reasonable to create a separate instance of django, then to create a package, so that later it can be installed on another local project and checked there. Probably I don't understand something.
So. What is the correct way to create a django module as a pypi package?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
A
alz, 2013-05-22
@alz

Create a separate directory and add it to python path

U
un1t, 2015-02-06
@un1t

I use TDD, the code can be tested and debugged without a separate django project.
For example, like here
https://github.com/un1t/django-templatetags
see the file runtests.py

V
Vadim Shandrinov, 2015-03-27
@suguby

I was also puzzled . How do you develop a PyPI package?
Is there a solution?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question