You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "Siddharth Anand (JIRA)" <ji...@apache.org> on 2016/11/24 17:08:59 UTC
[jira] [Commented] (AIRFLOW-652) Endpoint /admin/airflow/sandbox
seems unnecessary
[ https://issues.apache.org/jira/browse/AIRFLOW-652?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15693782#comment-15693782 ]
Siddharth Anand commented on AIRFLOW-652:
-----------------------------------------
[~g.toonstra] I wonder if the sandbox (it if can be made to work) can be used for your http operator test!
> Endpoint /admin/airflow/sandbox seems unnecessary
> -------------------------------------------------
>
> Key: AIRFLOW-652
> URL: https://issues.apache.org/jira/browse/AIRFLOW-652
> Project: Apache Airflow
> Issue Type: Improvement
> Components: webserver
> Reporter: Kengo Seki
> Priority: Minor
>
> airflow/www/views.py exposes an endpoint /sandbox as follows:
> {code}
> 627 @expose('/sandbox')
> 628 @login_required
> 629 def sandbox(self):
> 630 title = "Sandbox Suggested Configuration"
> 631 cfg_loc = conf.AIRFLOW_CONFIG + '.sandbox'
> 632 f = open(cfg_loc, 'r')
> 633 config = f.read()
> 634 f.close()
> 635 code_html = Markup(highlight(
> 636 config,
> 637 lexers.IniLexer(), # Lexer call
> 638 HtmlFormatter(noclasses=True))
> 639 )
> 640 return self.render(
> 641 'airflow/code.html',
> 642 code_html=code_html, title=title, subtitle=cfg_loc)
> {code}
> But this endpoint seems unused. If there is no airflow.cfg.sandbox file, "Ooops" page is shown. I think we can remove this for code cleanup.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)