ashb commented on a change in pull request #8940:
URL: https://github.com/apache/airflow/pull/8940#discussion_r428511975
##########
File path: airflow/www/app.py
##########
@@ -95,9 +96,18 @@ def create_app(config=None, session=None, testing=False,
app_name="Airflow"):
"""Your CUSTOM_SECURITY_MANAGER must now extend
AirflowSecurityManager,
not FAB's security manager.""")
- appbuilder = AppBuilder(
- app,
- db.session if not session else session,
+ class AirflowAppBuilder(AppBuilder):
+
+ def add_view(self, baseview, *args, **kwargs):
+ if hasattr(baseview, 'datamodel'):
+ # Delete sessions if initiated previously to limit side
effects. We want to use
+ # the current session in the current application.
+ baseview.datamodel.session = None
Review comment:
Oh, i remember what my problem was: date columns on FABs own security
models.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]