Here the `async_` keyword argument is not being used anywhere. The reason why 
it's here is because some engines (actually, only `HiveEngineSpec`) have the 
`async` option and override this method. SQL Lab doesn't differentiate between 
engines, and regardless of the backend will call:

```python
db_engine_spec.execute(cursor, query.executed_sql, async_=True)
```

It's better to change the method signature here to:

```python
def execute(cls, cursor, query, **kwargs):
```

This way, any extra keyword arguments are stored in `kwargs`, and derived 
classes can declare more specific signatures, eg, for `HiveEngineSpec`:

```python
def execute(cls, cursor, query, async_=False, **kwargs):
```

[ Full content available at: 
https://github.com/apache/incubator-superset/pull/5759 ]
This message was relayed via gitbox.apache.org for [email protected]

Reply via email to