Snapshot fails on database with views
S3RK opened this issue · 0 comments
S3RK commented
traceback (most recent call last):
File "/usr/local/bin/stellar", line 8, in <module>
load_entry_point('stellar==0.3.2', 'console_scripts', 'stellar')()
File "/Library/Python/2.7/site-packages/stellar/command.py", line 225, in main
stellar()
File "/Library/Python/2.7/site-packages/click/core.py", line 609, in __call__
return self.main(*args, **kwargs)
File "/Library/Python/2.7/site-packages/click/core.py", line 589, in main
rv = self.invoke(ctx)
File "/Library/Python/2.7/site-packages/click/core.py", line 935, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Library/Python/2.7/site-packages/click/core.py", line 781, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/Library/Python/2.7/site-packages/click/core.py", line 416, in invoke
return callback(*args, **kwargs)
File "/Library/Python/2.7/site-packages/stellar/command.py", line 51, in snapshot
app.create_snapshot(name, before_copy=before_copy)
File "/Library/Python/2.7/site-packages/stellar/app.py", line 114, in create_snapshot
table.get_table_name('master')
File "/Library/Python/2.7/site-packages/stellar/operations.py", line 58, in copy_database
row[0]
File "/Library/Python/2.7/site-packages/sqlalchemy/engine/base.py", line 721, in execute
return self._execute_text(object, multiparams, params)
File "/Library/Python/2.7/site-packages/sqlalchemy/engine/base.py", line 870, in _execute_text
statement, parameters
File "/Library/Python/2.7/site-packages/sqlalchemy/engine/base.py", line 958, in _execute_context
context)
File "/Library/Python/2.7/site-packages/sqlalchemy/engine/base.py", line 1160, in _handle_dbapi_exception
exc_info
File "/Library/Python/2.7/site-packages/sqlalchemy/util/compat.py", line 199, in raise_from_cause
reraise(type(exception), exception, tb=exc_tb)
File "/Library/Python/2.7/site-packages/sqlalchemy/engine/base.py", line 951, in _execute_context
context)
File "/Library/Python/2.7/site-packages/sqlalchemy/engine/default.py", line 436, in do_execute
cursor.execute(statement, parameters)
File "/Library/Python/2.7/site-packages/pymysql/cursors.py", line 132, in execute
result = self._query(query)
File "/Library/Python/2.7/site-packages/pymysql/cursors.py", line 271, in _query
conn.query(q)
File "/Library/Python/2.7/site-packages/pymysql/connections.py", line 726, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
File "/Library/Python/2.7/site-packages/pymysql/connections.py", line 861, in _read_query_result
result.read()
File "/Library/Python/2.7/site-packages/pymysql/connections.py", line 1064, in read
first_packet = self.connection._read_packet()
File "/Library/Python/2.7/site-packages/pymysql/connections.py", line 826, in _read_packet
packet.check_error()
File "/Library/Python/2.7/site-packages/pymysql/connections.py", line 370, in check_error
raise_mysql_exception(self._data)
File "/Library/Python/2.7/site-packages/pymysql/err.py", line 116, in raise_mysql_exception
_check_mysql_exception(errinfo)
File "/Library/Python/2.7/site-packages/pymysql/err.py", line 112, in _check_mysql_exception
raise InternalError(errno, errorvalue)
sqlalchemy.exc.InternalError: (InternalError) (1347, u"'database.viewname' is not BASE TABLE")
'\nCREATE TABLE stellar_database_1e29f56dd029c6b5e8b2eafbb99a6d07_master.viewname LIKE database.viewname\n' ()