Skip to content

Commit 5385d00

Browse files
authored
Fix: Refreshing snapshot intervals for uncategorized snapshots when state is stored in databricks (#4095)
1 parent 71dfa05 commit 5385d00

File tree

2 files changed

+1
-9
lines changed

2 files changed

+1
-9
lines changed

sqlmesh/core/state_sync/db/interval.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ def refresh_snapshot_intervals(self, snapshots: t.Collection[Snapshot]) -> t.Lis
142142
if not snapshots:
143143
return []
144144

145-
_, intervals = self._get_snapshot_intervals(snapshots)
145+
_, intervals = self._get_snapshot_intervals([s for s in snapshots if s.version])
146146
for s in snapshots:
147147
s.intervals = []
148148
s.dev_intervals = []

tests/core/engine_adapter/integration/config.yaml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,6 @@ gateways:
118118
database: {{ env_var('SNOWFLAKE_DATABASE') }}
119119
user: {{ env_var('SNOWFLAKE_USER') }}
120120
password: {{ env_var('SNOWFLAKE_PASSWORD') }}
121-
state_connection:
122-
type: duckdb
123121

124122
inttest_databricks:
125123
connection:
@@ -128,8 +126,6 @@ gateways:
128126
server_hostname: {{ env_var('DATABRICKS_SERVER_HOSTNAME') }}
129127
http_path: {{ env_var('DATABRICKS_HTTP_PATH') }}
130128
access_token: {{ env_var('DATABRICKS_ACCESS_TOKEN') }}
131-
state_connection:
132-
type: duckdb
133129

134130
inttest_redshift:
135131
connection:
@@ -138,16 +134,12 @@ gateways:
138134
user: {{ env_var('REDSHIFT_USER') }}
139135
password: {{ env_var('REDSHIFT_PASSWORD') }}
140136
database: {{ env_var('REDSHIFT_DATABASE') }}
141-
state_connection:
142-
type: duckdb
143137

144138
inttest_bigquery:
145139
connection:
146140
type: bigquery
147141
method: service-account
148142
keyfile: {{ env_var('BIGQUERY_KEYFILE') }}
149-
state_connection:
150-
type: duckdb
151143

152144
inttest_clickhouse_cloud:
153145
connection:

0 commit comments

Comments
 (0)