Alexis Manuel
01/13/2023, 8:14 AMbuild_asset_reconciliation_sensor
bug related to Source Asset. I have now the following error during sensor tick:
dagster._core.errors.DagsterUserCodeUnreachableError: The sensor tick timed out due to taking longer than 60 seconds to execute the sensor function. One way to avoid this error is to break up the sensor work into chunks, using cursors to let subsequent sensor calls pick up where the previous call left off.
File "/usr/local/lib/python3.7/site-packages/dagster/_daemon/sensor.py", line 491, in _process_tick_generator
sensor_debug_crash_flags,
File "/usr/local/lib/python3.7/site-packages/dagster/_daemon/sensor.py", line 558, in _evaluate_sensor
instigator_data.cursor if instigator_data else None,
File "/usr/local/lib/python3.7/site-packages/dagster/_core/host_representation/repository_location.py", line 830, in get_external_sensor_execution_data
cursor,
File "/usr/local/lib/python3.7/site-packages/dagster/_api/snapshot_sensor.py", line 72, in sync_get_external_sensor_execution_data_grpc
timeout=timeout,
File "/usr/local/lib/python3.7/site-packages/dagster/_grpc/client.py", line 403, in external_sensor_execution
custom_timeout_message=custom_timeout_message,
File "/usr/local/lib/python3.7/site-packages/dagster/_grpc/client.py", line 184, in _streaming_query
e, timeout=timeout, custom_timeout_message=custom_timeout_message
File "/usr/local/lib/python3.7/site-packages/dagster/_grpc/client.py", line 137, in _raise_grpc_exception
) from e
The above exception was caused by the following exception:
grpc._channel._MultiThreadedRendezvous: <_MultiThreadedRendezvous of RPC that terminated with:
status = StatusCode.DEADLINE_EXCEEDED
details = "Deadline Exceeded"
debug_error_string = "{"created":"@1673597250.934518131","description":"Deadline Exceeded","file":"src/core/ext/filters/deadline/deadline_filter.cc","file_line":81,"grpc_status":4}"
>
File "/usr/local/lib/python3.7/site-packages/dagster/_grpc/client.py", line 180, in _streaming_query
method, request=request_type(**kwargs), timeout=timeout
File "/usr/local/lib/python3.7/site-packages/dagster/_grpc/client.py", line 168, in _get_streaming_response
yield from getattr(stub, method)(request, metadata=self._metadata, timeout=timeout)
File "/usr/local/lib/python3.7/site-packages/grpc/_channel.py", line 426, in __next__
return self._next()
File "/usr/local/lib/python3.7/site-packages/grpc/_channel.py", line 826, in _next
raise self
I built the sensor using following code:
from dagster import AssetSelection, build_asset_reconciliation_sensor
freshness_sla_sensor = build_asset_reconciliation_sensor(
name="freshness_sla_sensor", asset_selection=AssetSelection.all()
)
My assets are mainly loaded from a dbt project which has around 30 different models and sources
Is there any way to know the root cause of the sensor tick timeout ?owen
01/13/2023, 5:41 PMAlexis Manuel
01/13/2023, 6:04 PMbuild_asset_reconciliation_sensor
functionnality to ensure an efficient dbt graph scheduling.
3. The most surprising fact to me was that it occured on a fresh local PostgresDb with no prior runs and materializationsowen
01/13/2023, 6:29 PMAlexis Manuel
01/13/2023, 6:57 PMowen
01/17/2023, 10:32 PMAlexis Manuel
01/18/2023, 7:55 AMCharlie Bini
01/20/2023, 6:54 PMAlexis Manuel
01/20/2023, 6:55 PMCharlie Bini
01/20/2023, 6:58 PMAlexis Manuel
01/20/2023, 7:13 PMCharlie Bini
01/20/2023, 10:12 PMowen
01/20/2023, 10:25 PMCharlie Bini
01/20/2023, 10:27 PMThomas Rolfsnes
03/17/2023, 1:23 PMowen
03/17/2023, 3:24 PMThomas Rolfsnes
03/20/2023, 9:09 AMdagster._core.errors.DagsterUserCodeUnreachableError: Timed out waiting for call to user code GET_EXTERNAL_SENSOR_EXECUTION_DATA [7a43fc45-6780-4db0-9386-a5824a4f5026]
File "/dagster-graphql/dagster_graphql/schema/instigation.py", line 227, in resolve_evaluationResult
sensor_data = repository_location.get_external_sensor_execution_data(
File "/dagster-cloud-backend/dagster_cloud_backend/user_code/workspace.py", line 647, in get_external_sensor_execution_data
result = self.api_call(
File "/dagster-cloud-backend/dagster_cloud_backend/user_code/workspace.py", line 382, in api_call
return dagster_cloud_api_call(
File "/dagster-cloud-backend/dagster_cloud_backend/user_code/workspace.py", line 131, in dagster_cloud_api_call
for result in gen_dagster_cloud_api_call(
File "/dagster-cloud-backend/dagster_cloud_backend/user_code/workspace.py", line 246, in gen_dagster_cloud_api_call
raise DagsterUserCodeUnreachableError(
owen
03/20/2023, 5:23 PMunpartitioned -> partitioned asset
case in the asset reconciliation logic (going out this week), which may resolve the problem, but it's definitely odd to me that an asset selection of that size would be hitting this time out (as it's orders of magnitude smaller than other graphs that complete much faster).
I'm thinking that this is somehow hitting an edge case and generating way more queries than necessary, so I'm going to dig in a bit and see if I can figure out why you're seeing thisThomas Rolfsnes
03/20/2023, 5:42 PM