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

fix(sqllab): error with lazy_gettext for tab titles #25469

Merged
merged 3 commits into from
Sep 30, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions superset/views/sql_lab/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
from flask_appbuilder import expose
from flask_appbuilder.models.sqla.interface import SQLAInterface
from flask_appbuilder.security.decorators import has_access, has_access_api
from flask_babel import lazy_gettext as _
from flask_babel import gettext as __
from sqlalchemy import and_

from superset import db
Expand Down Expand Up @@ -90,7 +90,7 @@ def post(self) -> FlaskResponse:
user_id=get_user_id(),
# This is for backward compatibility
label=query_editor.get("name")
or query_editor.get("title", _("Untitled Query")),
or query_editor.get("title", __("Untitled Query")),
active=True,
database_id=query_editor["dbId"],
schema=query_editor.get("schema"),
Expand Down