Thursday, May 26, 2016

Re: django.contrib apps migrations

I managed to use fixtures to suit my needs for maintaining concurrency across admin app with collaborators.

On Sunday, May 15, 2016 at 2:42:00 AM UTC-7, Michal Petrucha wrote:
On Fri, May 13, 2016 at 01:01:22PM -0700, McKinley wrote:
> Hi Michal,
>
> I know the django.contrib migrations reside within my virtualenv. What if I
> wanted a fellow developer to have access to these migrations without
> sharing the same django install. If i have a colleague working on their own
> machine and they git pull my django project, they aren't getting my admin
> and auth migrations so aren't we working on different data afterwards?

If someone else sets up the same project on a different machine, they
will still need to install the same version of Django in their
virtualenv for it to work. That means, they will also install the
necessary contrib pacages and their migrations on their machines,
exactly the same way as if you used any other third-party package that
includes models.

Migrations are a part of thier packages' code base. So the migrations
for django.contrib.admin are part of the code base of
django.contrib.admin, just like migrations for any of your packages
are part of the code base of your packages. There is no reason to
treat them in any special way. When you install Django, which includes
all its contrib packages, you inevitably also install all the
migrations that ship with Django.

Does this help answer your question? (I'm not sure I understand your
concerns correctly, to be honest.)

Michal

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/612f9748-61ac-43ba-b396-ab7333d7203e%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment