time series line bar sqlalchemy.exc.ProgrammingError
sqlalchemy.exc.ProgrammingError
ProgrammingError: (psycopg2.ProgrammingError) column "\u6d4b\u8bd5\u5b57\u6bb5" does not exist LINE 1: SELECT "\u6d4b\u8bd5\u5b57\u6bb5" AS timestamp, COUNT() AS ... ^ [SQL: 'SELECT "\u6d4b\u8bd5\u5b57\u6bb5" AS timestamp, COUNT() AS count \nFROM servcode_table_view \nWHERE "\xe6\xb5\x8b\xe8\xaf\x95\xe5\xad\x97\xe6\xae\xb5" >= '2010-06-23 11:01:48.000000' AND "\xe6\xb5\x8b\xe8\xaf\x95\xe5\xad\x97\xe6\xae\xb5" <= '2016-06-23 11:01:48.000000' GROUP BY "\u6d4b\u8bd5\u5b57\u6bb5" \n LIMIT 50000'] Traceback (most recent call last)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1836, in __call__
return self.wsgi_app(environ, start_response)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1820, in wsgi_app
response = self.make_response(self.handle_exception(e))
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1403, in handle_exception
reraise(exc_type, exc_value, tb)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1817, in wsgi_app
response = self.full_dispatch_request()
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1477, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1381, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1475, in full_dispatch_request
rv = self.dispatch_request()
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask/app.py", line 1461, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/flask_appbuilder/security/decorators.py", line 26, in wraps
return f(self, *args, **kwargs)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/models.py", line 1295, in wrapper
return f(*args, **kwargs)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/views.py", line 558, in explore
payload = obj.get_json()
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/viz.py", line 262, in get_json
'data': self.get_data(),
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/viz.py", line 961, in get_data
df = self.get_df()
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/viz.py", line 869, in get_df
df = super(NVD3TimeSeriesViz, self).get_df(query_obj)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/viz.py", line 148, in get_df
self.results = self.datasource.query(**query_obj)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/caravel/models.py", line 726, in query
con=engine
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/pandas/io/sql.py", line 433, in read_sql_query
parse_dates=parse_dates, chunksize=chunksize)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/pandas/io/sql.py", line 1192, in read_query
result = self.execute(*args)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/pandas/io/sql.py", line 1083, in execute
return self.connectable.execute(*args, **kwargs)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1991, in execute
return connection.execute(statement, *multiparams, **params)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 906, in execute
return self._execute_text(object, multiparams, params)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1054, in _execute_text
statement, parameters
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1146, in _execute_context
context)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1341, in _handle_dbapi_exception
exc_info
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/util/compat.py", line 200, in raise_from_cause
reraise(type(exception), exception, tb=exc_tb, cause=cause)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1139, in _execute_context
context)
File "/home/chejinye/anaconda2/lib/python2.7/site-packages/sqlalchemy/engine/default.py", line 450, in do_execute
cursor.execute(statement, parameters)
ProgrammingError: (psycopg2.ProgrammingError) column "\u6d4b\u8bd5\u5b57\u6bb5" does not exist LINE 1: SELECT "\u6d4b\u8bd5\u5b57\u6bb5" AS timestamp, COUNT(*) AS ... ^ [SQL: 'SELECT "\\u6d4b\\u8bd5\\u5b57\\u6bb5" AS timestamp, COUNT(*) AS count \nFROM servcode_table_view \nWHERE "\xe6\xb5\x8b\xe8\xaf\x95\xe5\xad\x97\xe6\xae\xb5" >= \'2010-06-23 11:01:48.000000\' AND "\xe6\xb5\x8b\xe8\xaf\x95\xe5\xad\x97\xe6\xae\xb5" <= \'2016-06-23 11:01:48.000000\' GROUP BY "\\u6d4b\\u8bd5\\u5b57\\u6bb5" \n LIMIT 50000']
The debugger caught an exception in your WSGI application. You can now look at the traceback which led to the error.
To switch between the interactive traceback and the plaintext one, you can click on the "Traceback" headline. From the text traceback you can also create a paste of it. For code execution mouse-over the frame you want to debug and click on the console icon on the right side.
You can execute arbitrary Python code in the stack frames and there are some extra helpers available for introspection:
dump() shows all variables in the frame
dump(obj) dumps all that's known about the object
Where the SQL statement is generated
Looks like you're pretty deep into unicode. You might want to give python3 a shot.
../python2.7/site-packages/sqlalchemy/elements.py def str(self) ascii update to utf8 can solve @mistercrunch
I have no idea what that means