Markus, one specific question re your blog post.
"What happens when you call python manage.py makemigrations? First of all,
since no apps are given, Django reads the migrations from all apps listed in
INSTALLED_APPS. In our case, this is ('author', 'book',). "
I have the following in INSTALLED_APPS:
In [2]: apps.get_app_configs()
Out[2]: ValuesView(OrderedDict([('admin', <AdminConfig: admin>), ('auth',
<AuthConfig: auth>), ('contenttypes', <ContentTypesConfig: contenttypes>),
('sessions', <SessionsConfig: sessions>), ('messages', <MessagesConfig:
messages>), ('staticfiles', <StaticFilesConfig: staticfiles>), ('sites',
<SitesConfig: sites>), ('allauth', <AppConfig: allauth>), ('account',
<AccountConfig: account>), ('socialaccount', <SocialAccountConfig:
socialaccount>), ('main', <MainConfig: main>)]))
But it seems it doesn't see my "main" app. Your note seems to indicate that it
will 'make migrations' for INSTALLED_APPS.
$ python manage.py migrate --list
admin
[ ] 0001_initial
auth
[ ] 0001_initial
contenttypes
[ ] 0001_initial
sessions
[ ] 0001_initial
sites
[ ] 0001_initial
socialaccount
(no migrations)
I have to explicitly run with 'main' app. Just wondering if I am missing
something in my config.
$ python manage.py makemigrations main
Migrations for 'main':
0001_initial.py:
- Create model Currencies
- Create model Locations
- Create model Posts
- Create model UserProfile
On Sep 22, 2014, at 9:16 AM, Markus Holtermann <[email protected]> wrote:
> On Mon, Sep 22, 2014 at 08:41:36AM -0700, Anil Jangity wrote:
>> If I don't use syncdb, I should also create the super user account
>> using data migration? If so, it seems like I need to go do
>> User.objects.create_superuser().
>
> There still is the option of running "python manage.py createsuperuser"
> after the migrations are applied. If I don't need a superuser account
> during the migration, this would be my way of doing it.
>
> /Markus
--
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 [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/C9A4828C-8B10-4300-9BA0-7AB768BDF39D%40me.com.
For more options, visit https://groups.google.com/d/optout.