When I tried to upgrade database to r581 from r569, I found some tables are not synced by "manage.py syncdb" but "manage.py migrate" refused to migrate them either. Here is the output:

$ python2.5 manage.py syncdb
Syncing...

Synced:
 > django.contrib.auth
 > django.contrib.contenttypes
 > django.contrib.sessions
 > django.contrib.sites
 > django.contrib.admin
 > django.contrib.markup
 > south

Not synced (use migrations):
 - forum
(use ./manage.py migrate to migrate these)

$ python2.5 manage.py migrate
Running migrations for forum:
- Nothing to migrate.
 - Loading initial data for forum.

According to the code diff, it looks like the database tables are actually not changed, but the interface is changed a little. Should I be worried about the database in this case? Why does "manage.py syncdb" complain that "forum" is not synced?

Thanks in advance for any help.

asked 06 Sep '10, 19:48

X%20M's gravatar image

X M
1811510
accept rate: 0%


From 569 to 581 there's no schema changes so you shouldn't be worried. The syncdb command is responsible for creating the database schema, or any new tables. But when you install south (the migration library used by OSQA) it intercepts that command and does not synchronize any django app that appears to have migrations, in this case the forum app (the OSQA core), thus the "Not synced..." blah blah output. But that doesn't mean there are any migrations to run. So when you run migrate, it says there is nothing to migrate, and it's true :)

link

answered 06 Sep '10, 21:02

Hernani%20Cerqueira's gravatar image

Hernani Cerq... ♦♦
16.8k65975
accept rate: 52%

Thanks for the answer. So if there are indeed changes in the schema, South will make the migration and dbsync will say that app is "synced", is it correct?

(06 Sep '10, 21:57) X M
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×62
×13

Asked: 06 Sep '10, 19:48

Seen: 468 times

Last updated: 06 Sep '10, 21:57

powered by OSQA