vincbeck commented on code in PR #34317:
URL: https://github.com/apache/airflow/pull/34317#discussion_r1358503642
##########
airflow/www/extensions/init_jinja_globals.py:
##########
@@ -69,10 +70,13 @@ def prepare_jinja_globals():
"git_version": git_version,
"k8s_or_k8scelery_executor": IS_K8S_OR_K8SCELERY_EXECUTOR,
"rest_api_enabled": False,
- "auth_manager": get_auth_manager(),
"config_test_connection": conf.get("core", "test_connection",
fallback="Disabled"),
}
+ # Extra global specific to auth manager
+ extra_globals["auth_manager"] = get_auth_manager()
+ extra_globals["DagDetails"] = DagDetails
Review Comment:
From the tests it does not seem to work:
```
FAILED
tests/www/views/test_views_acl.py::test_success[rendered-templates-all-dag-user]
- jinja2.exceptions.UndefinedError: 'can_edit' is undefined
FAILED tests/www/views/test_views_acl.py::test_success[task] -
AssertionError: Couldn't find 'Task Instance Details'
FAILED tests/www/views/test_views_acl.py::test_success[xcom] -
jinja2.exceptions.UndefinedError: 'can_edit' is undefined
FAILED
tests/www/views/test_views_acl.py::test_success[grid-data-for-readonly-role] -
AssertionError: Couldn't find 'runme_1'
```
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]