{"action":"closed","issue":{"url":"https://api.github.com/repos/airbnb/airflow/issues/165","labels_url":"https://api.github.com/repos/airbnb/airflow/issues/165/labels{/name}","comments_url":"https://api.github.com/repos/airbnb/airflow/issues/165/comments","events_url":"https://api.github.com/repos/airbnb/airflow/issues/165/events","html_url":"https://github.com/airbnb/airflow/issues/165","id":96664780,"number":165,"title":"`context` referenced before assignment","user":{"login":"seibert","id":425352,"avatar_url":"https://avatars.githubusercontent.com/u/425352?v=3","gravatar_id":"","url":"https://api.github.com/users/seibert","html_url":"https://github.com/seibert","followers_url":"https://api.github.com/users/seibert/followers","following_url":"https://api.github.com/users/seibert/following{/other_user}","gists_url":"https://api.github.com/users/seibert/gists{/gist_id}","starred_url":"https://api.github.com/users/seibert/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seibert/subscriptions","organizations_url":"https://api.github.com/users/seibert/orgs","repos_url":"https://api.github.com/users/seibert/repos","events_url":"https://api.github.com/users/seibert/events{/privacy}","received_events_url":"https://api.github.com/users/seibert/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-22T21:12:28Z","updated_at":"2015-07-22T23:12:06Z","closed_at":"2015-07-22T23:12:06Z","body":"The except block here:\r\n\r\nhttps://github.com/airbnb/airflow/blob/master/airflow/models.py#L840\r\n\r\nwill fail if an exception is thrown in the preceding try block before line 826:\r\n\r\nhttps://github.com/airbnb/airflow/blob/master/airflow/models.py#L840\r\n\r\nThe fix is to ensure that `context` has been assigned regardless of where the exception is thrown, but I'm not familiar enough with this code to know how best to do that."}}