-
Notifications
You must be signed in to change notification settings - Fork 203
Open
Labels
Description
Describe the bug
A fresh install of elementary-data[databricks]==0.18.3 fails when running edr report. The error message is below. After failure, the report is generated but shows a "No Test Results" message.
The failure seems to be because elementary-data[databricks]==0.18.3 installed the latest version of dbt-databricks, version 1.10.3. The problem is fixed by manually downgrading dbt-databricks to version 1.10.1.
Error Message:
ERROR:elementary.monitor.data_monitoring.report.data_monitoring_report:Could not generate the report - Error: Failed to run dbt command.
{"info": {"name": "RunningOperationCaughtError", "code": "Q001", "msg": "Encountered an error while running operation: Database Error\n 'Macro' object has no attribute 'config'", "level": "error", "invocationId": "2e9f2a82-02cf-4190-9002-1b6ab4f033b0", "pid": 2143, "thread": "MainThread", "ts": "2025-06-11T16:21:13.556338Z"}, "data": {"exc": "Database Error\n 'Macro' object has no attribute 'config'"}}
Please reach out to our community for help with this issue.
Traceback (most recent call last):
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/monitor/api/report/report.py", line 84, in get_report_data
tests_api = TestsAPI(
^^^^^^^^^
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/monitor/api/tests/tests.py", line 52, in __init__
self.test_results_db_rows = self._get_test_results_db_rows(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/monitor/api/tests/tests.py", line 64, in _get_test_results_db_rows
return self.tests_fetcher.get_all_test_results_db_rows(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/monitor/fetchers/tests/tests.py", line 26, in get_all_test_results_db_rows
run_operation_response = self.dbt_runner.run_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/clients/dbt/command_line_dbt_runner.py", line 177, in run_operation
result = self._run_command(
^^^^^^^^^^^^^^^^^^
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/clients/dbt/command_line_dbt_runner.py", line 114, in _run_command
result = self._inner_run_command(
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/my_user_name/Code/data-team/edr/.venv/lib/python3.11/site-packages/elementary/clients/dbt/api_dbt_runner.py", line 54, in _inner_run_command
raise DbtCommandError(
elementary.exceptions.exceptions.DbtCommandError: Failed to run dbt command.
{"info": {"name": "RunningOperationCaughtError", "code": "Q001", "msg": "Encountered an error while running operation: Database Error\n 'Macro' object has no attribute 'config'", "level": "error", "invocationId": "2e9f2a82-02cf-4190-9002-1b6ab4f033b0", "pid": 2143, "thread": "MainThread", "ts": "2025-06-11T16:21:13.556338Z"}, "data": {"exc": "Database Error\n 'Macro' object has no attribute 'config'"}}
To Reproduce
Steps to reproduce the behavior:
pip install "elementary-data[databricks]- run
edr report<- the failure happens here
Expected behavior
The report should be built successfully.
Environment (please complete the following information):
- Elementary CLI (edr) version: 0.18.3
- Elementary dbt package version: 0.18.3
- dbt version you're using: 1.9.8
- Data warehouse: Databricks
- Infrastructure details: Running the elementary cli locally on a mac. Dbt is hosted in dbt cloud.
Additional context
None
Would you be willing to contribute a fix for this issue?
Yes.
Jeremynadalmirakl, arbiv, boblannon, mi-volodin, asos-dipeshbhundia and 1 more