You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2020/03/27 23:43:38 UTC

[GitHub] [airflow] dimberman opened a new issue #7936: UI should not print traceback for missing dag/task in URL

dimberman opened a new issue #7936: UI should not print traceback for missing dag/task in URL
URL: https://github.com/apache/airflow/issues/7936
 
 
   
   
   **Apache Airflow version**:
   
   
   **Kubernetes version (if you are using kubernetes)** (use `kubectl version`):
   
   **Environment**:
   
   - **Cloud provider or hardware configuration**:
   - **OS** (e.g. from /etc/os-release):
   - **Kernel** (e.g. `uname -a`):
   - **Install tools**:
   - **Others**:
   **What happened**:
   
   Right now if a user runs tries to do certain things in the UI with dags/tasks that don't exist they get confusing tracebacks rather than an error rendered in html like "the dag/task doesn't exist". One such traceback can be seen by going to the tree view for any DAG in the UI and then changing the url in the address bar for the dag_id to be a non-existent dag. The following traceback can be seen:
   
   Traceback (most recent call last):
     File "/usr/local/lib/python2.7/dist-packages/Flask-0.10.1-py2.7.egg/flask/app.py", line 1817, in wsgi_app
       response = self.full_dispatch_request()
     File "/usr/local/lib/python2.7/dist-packages/Flask-0.10.1-py2.7.egg/flask/app.py", line 1477, in full_dispatch_request
       rv = self.handle_user_exception(e)
     File "/usr/local/lib/python2.7/dist-packages/Flask-0.10.1-py2.7.egg/flask/app.py", line 1381, in handle_user_exception
       reraise(exc_type, exc_value, tb)
     File "/usr/local/lib/python2.7/dist-packages/Flask-0.10.1-py2.7.egg/flask/app.py", line 1475, in full_dispatch_request
       rv = self.dispatch_request()
     File "/usr/local/lib/python2.7/dist-packages/Flask-0.10.1-py2.7.egg/flask/app.py", line 1461, in dispatch_request
       return self.view_functions[rule.endpoint](**req.view_args)
     File "/usr/local/lib/python2.7/dist-packages/Flask_Admin-1.4.0-py2.7.egg/flask_admin/base.py", line 68, in inner
       return self._run_view(f, *args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/Flask_Admin-1.4.0-py2.7.egg/flask_admin/base.py", line 367, in _run_view
       return fn(self, *args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/Flask_Login-0.2.11-py2.7.egg/flask_login.py", line 758, in decorated_view
       return func(*args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/airflow/www/utils.py", line 213, in view_func
       return f(*args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/airflow/www/utils.py", line 118, in wrapper
       return f(*args, **kwargs)
     File "/usr/local/lib/python2.7/dist-packages/airflow/www/views.py", line 1208, in tree
       base_date = dag.latest_execution_date or datetime.now()
   AttributeError: 'NoneType' object has no attribute 'latest_execution_date'
   
   **What you expected to happen**:
   
   
   **How to reproduce it**:
   
   
   **Anything else we need to know**:
   
   Moved here from https://issues.apache.org/jira/browse/AIRFLOW-417
       

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services