Skip to content

Commit bc89e18

Browse files
authored
Merge branch 'main' into feat/lint-unavailable-warning
2 parents 3572408 + cebdfdc commit bc89e18

8 files changed

Lines changed: 57 additions & 23 deletions

File tree

‎.release-please-manifest.json‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
".": "0.196.1"
2+
".": "0.197.0"
33
}

‎CHANGELOG.md‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,17 @@
11
# Changelog
22

3+
## [0.197.0](https://github.com/sqlstack-io/sqlbuild/compare/v0.196.1...v0.197.0) (2026-11-07)
4+
5+
6+
### Features
7+
8+
* **ui:** list the live catalog from the control API ([#1344](https://github.com/sqlstack-io/sqlbuild/issues/1344)) ([13b233f](https://github.com/sqlstack-io/sqlbuild/commit/13b233f61e35aa1982fc9dac6f53a8841485a00f))
9+
10+
11+
### Bug Fixes
12+
13+
* **adapters:** escape cursor bounds and UDF packages as dialect string literals ([#1346](https://github.com/sqlstack-io/sqlbuild/issues/1346)) ([d3fc0e0](https://github.com/sqlstack-io/sqlbuild/commit/d3fc0e04908434bf758da2abc1ff864a695c1024))
14+
315
## [0.196.1](https://github.com/sqlstack-io/sqlbuild/compare/v0.196.0...v0.196.1) (2026-11-07)
416

517

‎Cargo.lock‎

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎crates/sqlbuild-cli/Cargo.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "sqlbuild-cli"
3-
version = "0.196.1"
3+
version = "0.197.0"
44
description = "The native `sqb` executable: reused compiles and Python-free commands served without Python, every other command handed to the Python CLI."
55
edition.workspace = true
66
license-file = "LICENSE"

‎crates/sqlbuild-orchestration/tests/api/node_status/helpers.rs‎

Lines changed: 37 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -358,21 +358,50 @@ async fn listing_ignores_build_history(
358358
);
359359
}
360360

361-
/// Three thousand built nodes, half in a named database, are read in batches and keep their own builds.
361+
/// Three thousand built nodes, half in a named database, keep their own builds, and listing them grows linearly.
362362
async fn listing_reads_wide_targets_in_batches(
363363
store: &ControlStore,
364364
credentials: (&AuditContext, Uuid),
365365
(location, mut input): (Uuid, SnapshotInput),
366366
) {
367367
let names: Vec<String> = (0..3_000).map(|index| format!("wide_{index:04}")).collect();
368+
let mut medians: Vec<std::time::Duration> = Vec::new();
369+
for (first, size) in [(0, 1_000), (1_000, names.len())] {
370+
medians.push(
371+
list_wide_target(
372+
store,
373+
credentials,
374+
(location, &mut input),
375+
(&names, first, size),
376+
)
377+
.await,
378+
);
379+
}
380+
let ratio: f64 = medians[1].as_secs_f64() / medians[0].as_secs_f64();
381+
assert!(
382+
ratio < 6.0,
383+
"listing {} nodes took {:?}, {ratio:.1} times the {:?} for 1,000; listing must stay linear",
384+
names.len(),
385+
medians[1],
386+
medians[0]
387+
);
388+
}
389+
390+
/// Add `names[first..size]` with one build each and return the median time to list the first `size`.
391+
async fn list_wide_target(
392+
store: &ControlStore,
393+
credentials: (&AuditContext, Uuid),
394+
(location, input): (Uuid, &mut SnapshotInput),
395+
(names, first, size): (&[String], usize, usize),
396+
) -> std::time::Duration {
368397
let database = |index: usize| (index % 2 == 1).then(|| "analytics_db".to_owned());
369398
let built_at = |index: usize| {
370399
chrono::DateTime::parse_from_rfc3339("2026-02-01T00:00:00Z")
371400
.expect("build start")
372401
.to_utc()
373402
+ chrono::Duration::seconds(i64::try_from(index).expect("seconds"))
374403
};
375-
for (index, name) in names.iter().enumerate() {
404+
for (index, name) in names.iter().enumerate().take(size).skip(first) {
376405
input.nodes.insert(format!("model:{name}"), SnapshotNode {
377406
kind: "model".into(),
378407
definition: json!({"name":name,"destination":{"database":database(index),"schema":"main","name":name}}),
@@ -382,9 +411,7 @@ async fn listing_reads_wide_targets_in_batches(
382411
});
383412
}
384413
input.generation += 1;
385-
publish_snapshot(store, &input)
386-
.await
387-
.expect("wide snapshot");
414+
publish_snapshot(store, input).await.expect("wide snapshot");
388415
let transaction = begin(store, TransactionMode::Write).await.expect("begin");
389416
let (mut transaction, rows) = query(
390417
transaction,
@@ -396,11 +423,11 @@ async fn listing_reads_wide_targets_in_batches(
396423
.await
397424
.expect("template build");
398425
let template: Uuid = serde_json::from_value(rows[0]["event_id"].clone()).expect("event id");
399-
for (chunk_index, chunk) in names.chunks(300).enumerate() {
426+
for (chunk_index, chunk) in names[first..size].chunks(300).enumerate() {
400427
let mut parameters = vec![Parameter::Id(template)];
401428
let mut values: Vec<String> = Vec::new();
402429
for (offset, name) in chunk.iter().enumerate() {
403-
let index = chunk_index * 300 + offset;
430+
let index = first + chunk_index * 300 + offset;
404431
values.push(format!(
405432
"(${},${},${},${},${})",
406433
parameters.len() + 1,
@@ -448,7 +475,7 @@ async fn listing_reads_wide_targets_in_batches(
448475
.iter()
449476
.map(|node| (node.node_key.as_str(), node.last_build.as_ref()))
450477
.collect();
451-
let built = names
478+
let built = names[..size]
452479
.iter()
453480
.enumerate()
454481
.filter(|(index, name)| {
@@ -462,13 +489,8 @@ async fn listing_reads_wide_targets_in_batches(
462489
})
463490
})
464491
.count();
465-
assert_eq!(built, names.len(), "every wide node keeps its own build");
492+
assert_eq!(built, size, "every wide node keeps its own build");
466493
}
467494
timings.sort();
468-
assert!(
469-
timings[1] < std::time::Duration::from_millis(450),
470-
"listing {} nodes took {:?}",
471-
names.len(),
472-
timings[1]
473-
);
495+
timings[1]
474496
}

‎crates/sqlbuild-python/Cargo.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "sqlbuild-python"
3-
version = "0.196.1"
3+
version = "0.197.0"
44
description = "The sqlbuild._native Python extension module."
55
edition.workspace = true
66
license.workspace = true

‎pyproject.toml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ build-backend = "maturin"
77

88
[project]
99
name = "sqlbuild"
10-
version = "0.196.1"
10+
version = "0.197.0"
1111
description = "Typed, test-first SQL pipelines with local E2E testing"
1212
readme = "README.md"
1313
requires-python = ">=3.12,<3.15"
@@ -18,7 +18,7 @@ dependencies = [
1818
"polyglot-sql-chio==0.13.10",
1919
"pydantic-settings>=2,<3",
2020
"PyYAML>=6.0.2",
21-
"sqlbuild-cli==0.196.1", # x-release-please-version
21+
"sqlbuild-cli==0.197.0", # x-release-please-version
2222
]
2323

2424
[project.optional-dependencies]

‎uv.lock‎

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)