Can't login to local instance of Batucada with my openID account

RESOLVED DUPLICATE of bug 623612

Status

RESOLVED DUPLICATE of bug 623612
8 years ago
4 years ago

People

(Reporter: paul, Assigned: paulosman)

Tracking

Details

(Whiteboard: batucada)

(Reporter)

Description

8 years ago
User-Agent: 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b8) Gecko/20100101 Firefox/4.0b8
Build Identifier:

Description:

If you try to login with your OpenID account at login/openid/ you returned back from whence you came and are not
logged in 


Reproducible: Always 

Other OG / Forum related modules installed
..

Steps to reproduce:
See description

Expected Results:
You should be logged in and redirected to the main page

Actual Results:
See description

Proposed solution:

Log:

Django version 1.2.3, using settings 'batucada.settings_local'
Development server is running at http://127.0.0.1:8000/
Quit the server with CONTROL-C.
Absolute URI: http://127.0.0.1:8000/en-US/
========================================
Traceback (most recent call last):
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/core/handlers/base.py", line 100, in get_response
    response = callback(request, *callback_args, **callback_kwargs)
  File "/Users/paul/Development/django_projects/batucada/apps/dashboard/views.py", line 80, in index
    return splash(request)
  File "/Users/paul/Development/django_projects/batucada/apps/users/decorators.py", line 26, in decorator
    return func(*args, **kwargs)
  File "/Users/paul/Development/django_projects/batucada/apps/dashboard/views.py", line 21, in splash
    if projects:
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/models/query.py", line 112, in __nonzero__
    iter(self).next()
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/models/query.py", line 106, in _result_iter
    self._fill_cache()
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/models/query.py", line 760, in _fill_cache
    self._result_cache.append(self._iter.next())
  File "/Users/paul/.virtualenvs/batucada/src/django-cache-machine/caching/base.py", line 127, in __iter__
    obj = iterator.next()
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/models/query.py", line 269, in iterator
    for row in compiler.results_iter():
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/models/sql/compiler.py", line 672, in results_iter
    for rows in self.execute_sql(MULTI):
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/models/sql/compiler.py", line 727, in execute_sql
    cursor.execute(sql, params)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/backends/mysql/base.py", line 86, in execute
    return self.cursor.execute(query, args)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/MySQLdb/cursors.py", line 173, in execute
    self.errorhandler(self, exc, value)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
    raise errorclass, errorvalue
OperationalError: (1054, "Unknown column 'projects_project.detailed_description_html' in 'field list'")

========================================
Request:
<WSGIRequest
GET:<QueryDict: {}>,
POST:<QueryDict: {}>,
COOKIES:{'csrftoken': '017dff141d86b60394172d22d00fc84c',
 'sessionid': '5d397251ac8d8665159851bbf6f9785d'},
META:{'Apple_PubSub_Socket_Render': '/tmp/launch-LGtYtf/Render',
 'CELERY_LOADER': 'djcelery.loaders.DjangoLoader',
 'COMMAND_MODE': 'unix2003',
 'CONTENT_LENGTH': '',
 'CONTENT_TYPE': 'text/plain',
 'CSRF_COOKIE': '017dff141d86b60394172d22d00fc84c',
 'DISPLAY': '/tmp/launch-4SBYW3/org.x:0',
 'DJANGO_SETTINGS_MODULE': 'batucada.settings_local',
 'GATEWAY_INTERFACE': 'CGI/1.1',
 'HOME': '/Users/paul',
 'HTTP_ACCEPT': 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8',
 'HTTP_ACCEPT_CHARSET': 'ISO-8859-1,utf-8;q=0.7,*;q=0.7',
 'HTTP_ACCEPT_ENCODING': 'gzip, deflate',
 'HTTP_ACCEPT_LANGUAGE': u'en-US',
 'HTTP_CONNECTION': 'keep-alive',
 'HTTP_COOKIE': 'csrftoken=017dff141d86b60394172d22d00fc84c; sessionid=5d397251ac8d8665159851bbf6f9785d',
 'HTTP_HOST': '127.0.0.1:8000',
 'HTTP_KEEP_ALIVE': '115',
 'HTTP_USER_AGENT': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:2.0b8) Gecko/20100101 Firefox/4.0b8',
 'LANG': 'en_GB.UTF-8',
 'LOGNAME': 'paul',
 'OLDPWD': '/Users/paul/Development/django_projects',
 'PATH': '/Users/paul/.virtualenvs/batucada/bin:/opt/local/bin:/opt/local/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/git/bin:/usr/X11/bin',
 'PATH_INFO': u'/en-US/',
 'PS1': '(batucada)\\h:\\W \\u\\$ ',
 'PWD': '/Users/paul/Development/django_projects/batucada',
 'PYTHONPATH': '/Users/paul/Development/django_projetcs',
 'QUERY_STRING': '',
 'REMOTE_ADDR': '127.0.0.1',
 'REMOTE_HOST': '',
 'REQUEST_METHOD': 'GET',
 'RUN_MAIN': 'true',
 'SCRIPT_NAME': u'',
 'SERVER_NAME': 'drumbeat.local',
 'SERVER_PORT': '8000',
 'SERVER_PROTOCOL': 'HTTP/1.1',
 'SERVER_SOFTWARE': 'WSGIServer/0.1 Python/2.6.1',
 'SHELL': '/bin/bash',
 'SHLVL': '1',
 'SSH_AUTH_SOCK': '/tmp/launch-5B3HZK/Listeners',
 'TERM': 'xterm-color',
 'TERM_PROGRAM': 'Apple_Terminal',
 'TERM_PROGRAM_VERSION': '273',
 'TMPDIR': '/var/folders/QD/QDCKj23nHsGvtWPzYNiSbU+++TI/-Tmp-/',
 'TZ': 'America/Toronto',
 'USER': 'paul',
 'VERSIONER_PYTHON_PREFER_32_BIT': 'no',
 'VERSIONER_PYTHON_VERSION': '2.6',
 'VIRTUAL_ENV': '/Users/paul/.virtualenvs/batucada',
 'WORKON_HOME': '/Users/paul/.virtualenvs',
 '_': '/Users/paul/.virtualenvs/batucada/bin/python',
 '__CF_USER_TEXT_ENCODING': '0x1F5:0:0',
 'wsgi.errors': <open file '<stderr>', mode 'w' at 0x100416140>,
 'wsgi.file_wrapper': <class 'django.core.servers.basehttp.FileWrapper'>,
 'wsgi.input': <socket._fileobject object at 0x101da1500>,
 'wsgi.multiprocess': False,
 'wsgi.multithread': True,
 'wsgi.run_once': False,
 'wsgi.url_scheme': 'http',
 'wsgi.version': (1, 0)}>
[11/Jan/2011 12:34:53] "GET /en-US/ HTTP/1.1" 500 5165
[11/Jan/2011 12:34:53] "GET /media/fonts/MuseoSans500/MuseoSans500.js HTTP/1.1" 200 4944
[11/Jan/2011 12:34:53] "GET /media/css/style.css?v=1 HTTP/1.1" 200 4709
[11/Jan/2011 12:34:53] "GET /media/css/batucada.css?v=1 HTTP/1.1" 200 45317
[11/Jan/2011 12:34:53] "GET /media/js/libs/modernizr-1.6.min.js HTTP/1.1" 200 9563
[11/Jan/2011 12:34:53] "GET /media/js/libs/jquery-1.4.2.min.js HTTP/1.1" 200 72174
[11/Jan/2011 12:34:53] "GET /media/js/libs/jquery.tmpl.min.js HTTP/1.1" 200 7404
[11/Jan/2011 12:34:53] "GET /media/js/script.js HTTP/1.1" 200 4975
[11/Jan/2011 12:34:53] "GET /media/images/favicon.ico HTTP/1.1" 200 1406
[11/Jan/2011 12:34:53] "GET /media/images/reply.icon.png HTTP/1.1" 200 566
[11/Jan/2011 12:34:53] "GET /media/images/twitter.png HTTP/1.1" 200 985
[11/Jan/2011 12:34:53] "GET /media/images/facebook.png HTTP/1.1" 200 785
[11/Jan/2011 12:34:53] "GET /media/images/flickr.png HTTP/1.1" 200 968
[11/Jan/2011 12:34:54] "GET /media/js/plugins.js HTTP/1.1" 200 1547
[11/Jan/2011 12:35:39] "GET /en-US/login/ HTTP/1.1" 200 6283
[11/Jan/2011 12:35:39] "GET /media/fonts/MuseoSans500/MuseoSans500.js HTTP/1.1" 200 4944
[11/Jan/2011 12:35:39] "GET /media/css/style.css?v=1 HTTP/1.1" 200 4709
[11/Jan/2011 12:35:39] "GET /media/css/batucada.css?v=1 HTTP/1.1" 200 45317
[11/Jan/2011 12:35:39] "GET /media/js/libs/modernizr-1.6.min.js HTTP/1.1" 200 9563
[11/Jan/2011 12:35:39] "GET /media/js/libs/jquery-1.4.2.min.js HTTP/1.1" 200 72174
[11/Jan/2011 12:35:39] "GET /media/js/libs/jquery.tmpl.min.js HTTP/1.1" 200 7404
[11/Jan/2011 12:35:39] "GET /media/js/script.js HTTP/1.1" 200 4975
[11/Jan/2011 12:35:39] "GET /media/images/favicon.ico HTTP/1.1" 200 1406
[11/Jan/2011 12:35:39] "GET /media/images/openid-22x25.png HTTP/1.1" 200 624
[11/Jan/2011 12:35:40] "GET /media/js/plugins.js HTTP/1.1" 200 1547
[11/Jan/2011 12:35:42] "GET /en-US/login/openid/ HTTP/1.1" 200 4503
[11/Jan/2011 12:35:42] "GET /media/fonts/MuseoSans500/MuseoSans500.js HTTP/1.1" 200 4944
[11/Jan/2011 12:35:42] "GET /media/css/style.css?v=1 HTTP/1.1" 200 4709
[11/Jan/2011 12:35:42] "GET /media/css/batucada.css?v=1 HTTP/1.1" 200 45317
[11/Jan/2011 12:35:42] "GET /media/js/libs/modernizr-1.6.min.js HTTP/1.1" 200 9563
[11/Jan/2011 12:35:42] "GET /media/js/libs/jquery-1.4.2.min.js HTTP/1.1" 200 72174
[11/Jan/2011 12:35:42] "GET /media/js/libs/jquery.tmpl.min.js HTTP/1.1" 200 7404
[11/Jan/2011 12:35:42] "GET /media/js/script.js HTTP/1.1" 200 4975
[11/Jan/2011 12:35:42] "GET /media/images/favicon.ico HTTP/1.1" 200 1406
[11/Jan/2011 12:35:42] "GET /media/images/openid/google.png HTTP/1.1" 200 5651
[11/Jan/2011 12:35:42] "GET /media/images/openid/yahoo.png HTTP/1.1" 200 1470
[11/Jan/2011 12:35:42] "GET /media/images/openid/myopenid.png HTTP/1.1" 200 2477
[11/Jan/2011 12:35:43] "GET /media/js/plugins.js HTTP/1.1" 200 1547
Generated checkid_setup request to http://www.myopenid.com/server with assocication {HMAC-SHA1}{4d2c88c0}{TupYMg==}
[11/Jan/2011 12:35:48] "POST /en-US/login/openid/ HTTP/1.1" 302 0
Error attempting to use stored discovery information: <openid.consumer.consumer.TypeURIMismatch: Required type http://openid.net/signon/1.0 not found in ['http://specs.openid.net/auth/2.0/signon', 'http://openid.net/sreg/1.0', 'http://openid.net/extensions/sreg/1.1', 'http://schemas.openid.net/pape/policies/2007/06/phishing-resistant', 'http://openid.net/srv/ax/1.0'] for endpoint <openid.consumer.discover.OpenIDServiceEndpoint server_url='http://www.myopenid.com/server' claimed_id='http://openid.ilovetheopenweb.org/paulbooker' local_id='http://openid.ilovetheopenweb.org/paulbooker' canonicalID=None used_yadis=True >>
Attempting discovery to verify endpoint
Performing discovery on http://openid.ilovetheopenweb.org/paulbooker
Received id_res response from http://www.myopenid.com/server using association {HMAC-SHA1}{4d2c88c0}{TupYMg==}
[11/Jan/2011 12:35:51] "GET /en-US/login/openid/complete/?janrain_nonce=2011-01-11T17%3A35%3A48ZPmDwnN&openid1_claimed_id=http%3A%2F%2Fopenid.ilovetheopenweb.org%2Fpaulbooker&openid.assoc_handle=%7BHMAC-SHA1%7D%7B4d2c88c0%7D%7BTupYMg%3D%3D%7D&openid.identity=http%3A%2F%2Fopenid.ilovetheopenweb.org%2Fpaulbooker&openid.mode=id_res&openid.op_endpoint=http%3A%2F%2Fwww.myopenid.com%2Fserver&openid.response_nonce=2011-01-11T17%3A31%3A58ZQUw4lt&openid.return_to=http%3A%2F%2F127.0.0.1%3A8000%2Fen-US%2Flogin%2Fopenid%2Fcomplete%2F%3Fjanrain_nonce%3D2011-01-11T17%253A35%253A48ZPmDwnN%26openid1_claimed_id%3Dhttp%253A%252F%252Fopenid.ilovetheopenweb.org%252Fpaulbooker&openid.sig=mCsl4be9eMTZFQRPvZvljPvZjrI%3D&openid.signed=assoc_handle%2Cidentity%2Cmode%2Cop_endpoint%2Cresponse_nonce%2Creturn_to%2Csigned HTTP/1.1" 403 4534
[11/Jan/2011 12:35:51] "GET /media/fonts/MuseoSans500/MuseoSans500.js HTTP/1.1" 200 4944
[11/Jan/2011 12:35:51] "GET /media/css/style.css?v=1 HTTP/1.1" 200 4709
[11/Jan/2011 12:35:51] "GET /media/css/batucada.css?v=1 HTTP/1.1" 200 45317
[11/Jan/2011 12:35:51] "GET /media/js/libs/modernizr-1.6.min.js HTTP/1.1" 200 9563
[11/Jan/2011 12:35:51] "GET /media/js/libs/jquery-1.4.2.min.js HTTP/1.1" 200 72174
[11/Jan/2011 12:35:51] "GET /media/js/plugins.js HTTP/1.1" 200 1547
[11/Jan/2011 12:35:51] "GET /media/js/script.js HTTP/1.1" 200 4975
[11/Jan/2011 12:35:51] "GET /media/images/favicon.ico HTTP/1.1" 200 1406
[11/Jan/2011 12:35:52] "GET /media/js/libs/jquery.tmpl.min.js HTTP/1.1" 200 7404
(Reporter)

Comment 1

8 years ago
Ignore ..

Other OG / Forum related modules installed
..
(Assignee)

Comment 2

8 years ago
From the stack trace it looks like you haven't run migrations on the projects application. Please do that and re-test.
(Reporter)

Comment 3

8 years ago
(batucada)Paul-Bookers-Mac-mini:batucada paul python manage.py migrate
Skipping creation of NoticeTypes as notification app not found
Running migrations for users:
 - Migrating forwards to 0007_auto__add_field_userprofile_newsletter.
 > users:0001_initial
south execute "CREATE TABLE `users_confirmationtoken` (`id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `user_id` integer NOT NULL UNIQUE, `token` varchar(128) NOT NULL);" with params "[]"
south execute "ALTER TABLE `users_confirmationtoken` ADD CONSTRAINT `user_id_refs_id_53b75de962f55914` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`);" with params "[]"
south execute "SET FOREIGN_KEY_CHECKS=1;" with params "[]"
south execute "CREATE TABLE `users_confirmationtoken` (`id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `user_id` integer NOT NULL UNIQUE, `token` varchar(128) NOT NULL);" with params "[]"
south execute "ALTER TABLE `users_confirmationtoken` ADD CONSTRAINT `user_id_refs_id_53b75de962f55914` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`);" with params "[]"
 > users:0002_auto__add_field_confirmationtoken_created_on
south execute "ALTER TABLE `users_confirmationtoken` ADD COLUMN `created_on` datetime NOT NULL DEFAULT '2010-11-29';" with params "[]"
south execute "ALTER TABLE `users_confirmationtoken` ADD COLUMN `created_on` datetime NOT NULL DEFAULT '2010-11-29';" with params "[]"
south execute "ALTER TABLE `users_confirmationtoken` ;" with params "[]"
south execute "ALTER TABLE `users_confirmationtoken` MODIFY `created_on` datetime NOT NULL;;" with params "[]"
south execute "ALTER TABLE `users_confirmationtoken` ALTER COLUMN `created_on` DROP DEFAULT;" with params "[]"
 > users:0003_auto__add_userprofile
south execute "CREATE TABLE `users_userprofile` (`id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `username` varchar(255) NOT NULL UNIQUE DEFAULT '', `display_name` varchar(255) NULL DEFAULT '', `password` varchar(255) NOT NULL DEFAULT '', `email` varchar(75) NULL UNIQUE, `bio` longtext NOT NULL, `confirmation_code` varchar(255) NOT NULL DEFAULT '', `location` varchar(255) NOT NULL DEFAULT '', `created_on` datetime NOT NULL DEFAULT '2010-12-16', `user_id` integer NULL);" with params "[]"
south execute "ALTER TABLE `users_userprofile` ADD CONSTRAINT `user_id_refs_id_4977e722d653ba24` FOREIGN KEY (`user_id`) REFERENCES `auth_user` (`id`);" with params "[]"
south execute "CREATE INDEX `users_userprofile_fbfc09f1` ON `users_userprofile` (`user_id`);" with params "[]"
south execute "CREATE TABLE `users_userprofile` (`id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `username` varchar(255) NOT NULL UNIQUE DEFAULT '', `display_name` varchar(255) NULL DEFAULT '', `password` varchar(255) NOT NULL DEFAULT '', `email` varchar(75) NULL UNIQUE, `bio` longtext NOT NULL, `confirmation_code` varchar(255) NOT NULL DEFAULT '', `location` varchar(255) NOT NULL DEFAULT '', `created_on` datetime NOT NULL DEFAULT '2010-12-16', `user_id` integer NULL);" with params "[]"
south execute "DROP TABLE `users_userprofile` CASCADE;" with params "[]"
 ! Error found during real run of migration! Aborting.

 ! Since you have a database that does not support running
 ! schema-altering statements in transactions, we have had 
 ! to leave it in an interim state between migrations.

! You *might* be able to recover with:   = DROP TABLE `users_userprofile` CASCADE; []

 ! The South developers regret this has happened, and would
 ! like to gently persuade you to consider a slightly
 ! easier-to-deal-with DBMS.
 ! NOTE: The error which caused the migration to fail is further up.
Traceback (most recent call last):
  File "manage.py", line 26, in <module>
    execute_manager(settings)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/core/management/__init__.py", line 438, in execute_manager
    utility.execute()
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/core/management/__init__.py", line 379, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/core/management/base.py", line 191, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/core/management/base.py", line 220, in execute
    output = self.handle(*args, **options)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/management/commands/migrate.py", line 105, in handle
    ignore_ghosts = ignore_ghosts,
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/__init__.py", line 191, in migrate_app
    success = migrator.migrate_many(target, workplan, database)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/migrators.py", line 221, in migrate_many
    result = migrator.__class__.migrate_many(migrator, target, migrations, database)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/migrators.py", line 292, in migrate_many
    result = self.migrate(migration, database)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/migrators.py", line 125, in migrate
    result = self.run(migration)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/migrators.py", line 99, in run
    return self.run_migration(migration)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/migrators.py", line 81, in run_migration
    migration_function()
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/migration/migrators.py", line 57, in <lambda>
    return (lambda: direction(orm))
  File "/Users/paul/Development/django_projects/batucada/apps/users/migrations/0003_auto__add_userprofile.py", line 22, in forwards
    ('user', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['auth.User'], null=True, blank=True)),
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/db/generic.py", line 226, in create_table
    ', '.join([col for col in columns if col]),
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/south/db/generic.py", line 150, in execute
    cursor.execute(sql, params)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/django/db/backends/mysql/base.py", line 86, in execute
    return self.cursor.execute(query, args)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/MySQLdb/cursors.py", line 173, in execute
    self.errorhandler(self, exc, value)
  File "/Users/paul/.virtualenvs/batucada/lib/python2.6/site-packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
    raise errorclass, errorvalue
_mysql_exceptions.OperationalError: (1050, "Table 'users_userprofile' already exists")
(batucada)Paul-Bookers-Mac-mini:batucada paul$
(Assignee)

Comment 4

8 years ago
Okay, so this is a dup of Bug # 623612. We may need to investigate another migration tool, since south appears to have difficulties with foreign key constraints. Workaround in the meantime:

1) Drop / Recreate your database
2) Remove south from INSTALLED_APPS in your settings.py or settings_local.py file
3) Run python manage.py syncdb
(Assignee)

Updated

8 years ago
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 623612
(Reporter)

Comment 6

8 years ago
Got my local server working again.
Product: Websites → Websites Graveyard
You need to log in before you can comment on or make changes to this bug.