Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Signup failed with self-host deployment using helm #1363

Open
little-eyes opened this issue Nov 2, 2023 · 1 comment
Open

Signup failed with self-host deployment using helm #1363

little-eyes opened this issue Nov 2, 2023 · 1 comment

Comments

@little-eyes
Copy link

Hi,

I deployed querybook v3 in a k8s cluster using helm charts available in the repo. When I launch the UI to sign up account, I got the below error back.

{
    "error": "(pymysql.err.OperationalError) (1054, \"Unknown column 'is_group' in 'field list'\")\n[SQL: INSERT INTO user (username, fullname, password, email, profile_img, deleted, is_group, properties) VALUES (%(username)s, %(fullname)s, %(password)s, %(email)s, %(profile_img)s, %(deleted)s, %(is_group)s, %(properties)s)]\n[parameters: {'username': 'jilongliao', 'fullname': None, 'password': 'pbkdf2:sha256:260000$QY9qdLCOaHl6klPx$592fcd34070347cca21b15481657ae91dde9badf0a3dd8edfd24460bffe6c83f', 'email': '[email protected]', 'profile_img': None, 'deleted': 0, 'is_group': 0, 'properties': '{}'}]\n(Background on this error at: https://sqlalche.me/e/14/e3q8)",
    "host": "web-54885bc54b-nrsnh",
    "traceback": "Traceback (most recent call last):\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/base.py\", line 1819, in _execute_context\n    self.dialect.do_execute(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/default.py\", line 732, in do_execute\n    cursor.execute(statement, parameters)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/cursors.py\", line 148, in execute\n    result = self._query(query)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/cursors.py\", line 310, in _query\n    conn.query(q)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 548, in query\n    self._affected_rows = self._read_query_result(unbuffered=unbuffered)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 775, in _read_query_result\n    result.read()\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 1156, in read\n    first_packet = self.connection._read_packet()\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 725, in _read_packet\n    packet.raise_for_error()\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/protocol.py\", line 221, in raise_for_error\n    err.raise_mysql_exception(self._data)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/err.py\", line 143, in raise_mysql_exception\n    raise errorclass(errno, errval)\npymysql.err.OperationalError: (1054, \"Unknown column 'is_group' in 'field list'\")\n\nThe above exception was the direct cause of the following exception:\n\nTraceback (most recent call last):\n  File \"/opt/querybook/querybook/server/app/datasource.py\", line 84, in handler\n    results = fn(**kwargs)\n  File \"/opt/querybook/querybook/server/app/auth/password_auth.py\", line 58, in signup_user_endpoint\n    user = create_user(\n  File \"/opt/querybook/querybook/server/app/db.py\", line 136, in func\n    return fn(*args, **kwargs)\n  File \"/opt/querybook/querybook/server/logic/user.py\", line 63, in create_user\n    user = User.create(\n  File \"/opt/querybook/querybook/server/app/db.py\", line 136, in func\n    return fn(*args, **kwargs)\n  File \"/opt/querybook/querybook/server/lib/sqlalchemy/__init__.py\", line 110, in create\n    session.commit()\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/session.py\", line 1451, in commit\n    self._transaction.commit(_to_root=self.future)\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/session.py\", line 829, in commit\n    self._prepare_impl()\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/session.py\", line 808, in _prepare_impl\n    self.session.flush()\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/session.py\", line 3383, in flush\n    self._flush(objects)\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/session.py\", line 3523, in _flush\n    transaction.rollback(_capture_exception=True)\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/util/langhelpers.py\", line 70, in __exit__\n    compat.raise_(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/util/compat.py\", line 208, in raise_\n    raise exception\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/session.py\", line 3483, in _flush\n    flush_context.execute()\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/unitofwork.py\", line 456, in execute\n    rec.execute(self)\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/unitofwork.py\", line 630, in execute\n    util.preloaded.orm_persistence.save_obj(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/persistence.py\", line 245, in save_obj\n    _emit_insert_statements(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/orm/persistence.py\", line 1238, in _emit_insert_statements\n    result = connection._execute_20(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/base.py\", line 1631, in _execute_20\n    return meth(self, args_10style, kwargs_10style, execution_options)\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/sql/elements.py\", line 332, in _execute_on_connection\n    return connection._execute_clauseelement(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/base.py\", line 1498, in _execute_clauseelement\n    ret = self._execute_context(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/base.py\", line 1862, in _execute_context\n    self._handle_dbapi_exception(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/base.py\", line 2043, in _handle_dbapi_exception\n    util.raise_(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/util/compat.py\", line 208, in raise_\n    raise exception\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/base.py\", line 1819, in _execute_context\n    self.dialect.do_execute(\n  File \"/usr/local/lib/python3.9/site-packages/sqlalchemy/engine/default.py\", line 732, in do_execute\n    cursor.execute(statement, parameters)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/cursors.py\", line 148, in execute\n    result = self._query(query)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/cursors.py\", line 310, in _query\n    conn.query(q)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 548, in query\n    self._affected_rows = self._read_query_result(unbuffered=unbuffered)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 775, in _read_query_result\n    result.read()\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 1156, in read\n    first_packet = self.connection._read_packet()\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/connections.py\", line 725, in _read_packet\n    packet.raise_for_error()\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/protocol.py\", line 221, in raise_for_error\n    err.raise_mysql_exception(self._data)\n  File \"/usr/local/lib/python3.9/site-packages/pymysql/err.py\", line 143, in raise_mysql_exception\n    raise errorclass(errno, errval)\nsqlalchemy.exc.OperationalError: (pymysql.err.OperationalError) (1054, \"Unknown column 'is_group' in 'field list'\")\n[SQL: INSERT INTO user (username, fullname, password, email, profile_img, deleted, is_group, properties) VALUES (%(username)s, %(fullname)s, %(password)s, %(email)s, %(profile_img)s, %(deleted)s, %(is_group)s, %(properties)s)]\n[parameters: {'username': 'jilongliao', 'fullname': None, 'password': 'pbkdf2:sha256:260000$QY9qdLCOaHl6klPx$592fcd34070347cca21b15481657ae91dde9badf0a3dd8edfd24460bffe6c83f', 'email': '[email protected]', 'profile_img': None, 'deleted': 0, 'is_group': 0, 'properties': '{}'}]\n(Background on this error at: https://sqlalche.me/e/14/e3q8)\n"
}

Any suggestions?

@michael-pattern
Copy link

From my test - this appears to be caused by a failing alembic migration earlier in the chain: #935

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants