Ask Your Question

DatabaseError: column "avatar_urls" of relation "auth_user" already exists

asked 2015-05-02 19:39:15 -0600

gabriel_cervantes's avatar

updated 2015-05-03 11:55:39 -0600

I'm trying to install the latest version of askbot from askbot-devel (0.7.53) but I got stuck on the following error.

C:\Projects\askbottest>python migrate askbot WARNING!!! You are using a 'locmem' (local memory) caching backend, which is OK for a low volume site running on a single-process server. For a multi-process configuration it is neccessary to have a production cache system, such as redis or memcached.

With local memory caching and multi-process setup you might intermittently see outdated content on your site.

Running migrations for askbot: - Migrating forwards to 0189_add_avatar_urls_jsonfield_to_auth_user.

askbot:0189_add_avatar_urls_jsonfield_to_auth_user FATAL ERROR - The following SQL query failed: ALTER TABLE "auth_user" ADD COLUMN "avatar_urls" text NOT NULL DEFAULT '{}'; The error was: column "avatar_urls" of relation "auth_user" already exists

Error in migration: askbot:0189_add_avatar_urls_jsonfield_to_auth_user DatabaseError: column "avatar_urls" of relation "auth_user" already exists

Any ideas?


I ended up replacing forward() with this:

def forwards(self, orm): #db.add_column('auth_user', 'avatar_urls', #'jsonfield.fields.JSONField')(default={}), # keep_default=False) pass


I was able to complete the migration but this is just a quick workaround not a proper solution.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2015-05-03 19:51:08 -0600

Evgeny's avatar

Pushed a fix for this to the master branch, please give it a try.

edit flag offensive delete link more



It works now. Thanks!

gabriel_cervantes's avatar gabriel_cervantes  ( 2015-05-24 18:14:48 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2015-05-02 19:39:15 -0600

Seen: 923 times

Last updated: May 03 '15