#24742: Can't runserver on a read-only database due to migrations
-----------------------------+--------------------
     Reporter:  delgiudices  |      Owner:  nobody
         Type:  Bug          |     Status:  new
    Component:  Migrations   |    Version:  1.8
     Severity:  Normal       |   Keywords:
 Triage Stage:  Unreviewed   |  Has patch:  0
Easy pickings:  0            |      UI/UX:  0
-----------------------------+--------------------
 So i was handed a read only database to develop a Web API.
 This is traceback when i runserver
 {{{
 Performing system checks...

 System check identified no issues (0 silenced).
 Unhandled exception in thread started by <function wrapper at 0x10ba2a848>
 Traceback (most recent call last):
   File "/Users/delgiudices/Dev/django/django/utils/autoreload.py", line
 220, in wrapper
     fn(*args, **kwargs)
   File
 "/Users/delgiudices/Dev/django/django/core/management/commands/runserver.py",
 line 111, in inner_run
     self.check_migrations()
   File
 "/Users/delgiudices/Dev/django/django/core/management/commands/runserver.py",
 line 158, in check_migrations
     executor = MigrationExecutor(connections[DEFAULT_DB_ALIAS])
   File "/Users/delgiudices/Dev/django/django/db/migrations/executor.py",
 line 19, in __init__
     self.loader = MigrationLoader(self.connection)
   File "/Users/delgiudices/Dev/django/django/db/migrations/loader.py",
 line 47, in __init__
     self.build_graph()
   File "/Users/delgiudices/Dev/django/django/db/migrations/loader.py",
 line 180, in build_graph
     self.applied_migrations = recorder.applied_migrations()
   File "/Users/delgiudices/Dev/django/django/db/migrations/recorder.py",
 line 59, in applied_migrations
     self.ensure_schema()
   File "/Users/delgiudices/Dev/django/django/db/migrations/recorder.py",
 line 53, in ensure_schema
     editor.create_model(self.Migration)
   File "/Users/delgiudices/Dev/django/django/db/backends/base/schema.py",
 line 284, in create_model
     self.execute(sql, params or None)
   File "/Users/delgiudices/Dev/django/django/db/backends/base/schema.py",
 line 110, in execute
     cursor.execute(sql, params)
   File "/Users/delgiudices/Dev/django/django/db/backends/utils.py", line
 79, in execute
     return super(CursorDebugWrapper, self).execute(sql, params)
   File "/Users/delgiudices/Dev/django/django/db/backends/utils.py", line
 64, in execute
     return self.cursor.execute(sql, params)
   File "/Users/delgiudices/Dev/django/django/db/utils.py", line 95, in
 __exit__
     six.reraise(dj_exc_type, dj_exc_value, traceback)
   File "/Users/delgiudices/Dev/django/django/db/backends/utils.py", line
 62, in execute
     return self.cursor.execute(sql)
   File "/Users/delgiudices/Dev/django/django/db/backends/mysql/base.py",
 line 124, in execute
     return self.cursor.execute(query, args)
   File "/Users/delgiudices/Dev/.envs/python29/lib/python2.7/site-
 packages/MySQLdb/cursors.py", line 205, in execute
     self.errorhandler(self, exc, value)
   File "/Users/delgiudices/Dev/.envs/python29/lib/python2.7/site-
 packages/MySQLdb/connections.py", line 36, in defaulterrorhandler
     raise errorclass, errorvalue
 django.db.utils.OperationalError: (1142, "CREATE command denied to user
 'someuser'@'someip' for table 'django_migrations'")

 }}}

--
Ticket URL: <https://code.djangoproject.com/ticket/24742>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" 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].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/054.6ebc7f94295406a4880b0cca3d264350%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to