dbt-labs / dbt-rpc

A server that can compile and run queries in the context of a dbt project. Additionally, it provides methods that can be used to list and terminate running processes.
https://docs.getdbt.com/reference/commands/rpc
Apache License 2.0
19 stars 7 forks source link

Fix dbt-core v1.4 compat, bump version + lower bound #121

Closed jtcohen6 closed 1 year ago

jtcohen6 commented 1 year ago

resolves #110

The changes in https://github.com/dbt-labs/dbt-rpc/pull/103 provided compatibility with >=1.4. They are incompatible with <=1.3.

Follow-ups after merging:

jtcohen6 commented 1 year ago

Update: We need to handle the exception renames from https://github.com/dbt-labs/dbt-core/pull/6539. I can confirm that the IDE in dbt Cloud is not working with 1.4 (prerelease) in the meantime.

Screenshot 2023-01-12 at 23 08 46
jtcohen6 commented 1 year ago

Seeing a lot of this error message in the automated tests:

E       AssertionError: invalid response from server: <!doctype html>
E       <html lang=en>
E       <title>500 Internal Server Error</title>
E       <h1>Internal Server Error</h1>
E       <p>The server encountered an internal error and was unable to complete your request. Either the server is overloaded or there is an error in the application.</p>

Update: Underlying issue here was that we added an abstract method in https://github.com/dbt-labs/dbt-core/pull/6488, and it needed to be implemented in the "extension" RPCTask:

  File "/Users/jerco/dev/product/plugins/server/dbt-rpc/dbt_rpc/rpc/task_manager.py", line 178, in rpc_task
    return self._get_manifest_callable(task)
  File "/Users/jerco/dev/product/plugins/server/dbt-rpc/dbt_rpc/rpc/task_manager.py", line 168, in _get_manifest_callable
    return task(deepcopy(self.args), self.config, self.manifest)
TypeError: Can't instantiate abstract class RemoteRPCCli with abstract method defer_to_manifest