When the token is used in the databricks connection, the host name is being pulled from extra json data

https://github.com/apache/airflow/blob/fdd9b6f65b608c516b8a062b058972d9a45ec9e3/airflow/providers/databricks/hooks/databricks.py#L160


I think the host name should be pulled from databricks_conn directly as the line 164, where basic auth is being used https://github.com/apache/airflow/blob/fdd9b6f65b608c516b8a062b058972d9a45ec9e3/airflow/providers/databricks/hooks/databricks.py#L164

Thanks!

Liusong


tests/providers/databricks/hooks/test_databricks.py
def test_is_terminal_true(self):
        terminal_states = ['TERMINATED', 'SKIPPED', 'INTERNAL_ERROR']
        for state in terminal_states:
            run_state = RunState(state, '', '')
            self.assertTrue(run_state.is_terminal)
    def test_is_terminal_false(self):
        non_terminal_states = ['PENDING', 'RUNNING', 'TERMINATING']
        for state in non_terminal_states:
            run_state = RunState(state, '', '')
            self.assertFalse(run_state.is_terminal)
    def test_is_terminal_with_nonexistent_life_cycle_state(self):
        run_state = RunState('blah', '', '')
        with self.assertRaises(AirflowException):
            run_state.is_terminal
    def test_is_successful(self):
        run_state = RunState('TERMINATED', 'SUCCESS', '')
        self.assertTrue(run_state.is_successful)