@malloy-publisher/sdk 0.17.1 → 0.17.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1484,7 +1484,7 @@ export interface ManifestEntry {
1484
1484
  */
1485
1485
  'queryCostBytes'?: number | null;
1486
1486
  /**
1487
- * For a source that reads another persisted source, how this table\'s rows were computed from it. `reused`: every persisted upstream was read from its already-materialized table, so the rows are a function of those snapshots and consistent with them. `recomputed`: at least one persisted upstream was recomputed from its definition and inlined into this build, because its table could not be read -- on either tier, an upstream this build neither materialized nor was handed by reference; for a database build, an upstream that landed in a `storage=` destination; for a `storage=` build, a source that reaches the warehouse through a non-persisted source, or whose shape does not compile in the destination. `upstreamRecomputeReason` says which. Such a table reflects the warehouse at THIS build\'s time rather than the upstream\'s snapshot, so the two can disagree when their refresh cadences differ. Not a location: it does not name the table the rows came from. Absent for a source that reads no persisted upstream, which has one way to build and no choice to report. A database rollup reports what its build actually read: `reused` only when it built from its base\'s materialized table, and absent when it built from the warehouse, even over a persisted base. Before 0.15.0 every rollup over a persisted base reported `reused`. A `storage=` rollup reports `reused` only when it stacked on a stored table.
1487
+ * For a source that reads another persisted source, how this table\'s rows were computed from it. `reused`: every persisted upstream was read from its already-materialized table, so the rows are a function of those snapshots and consistent with them. `recomputed`: at least one persisted upstream was recomputed from its definition and inlined into this build, because its table could not be read -- on either tier, an upstream this build neither materialized nor was handed by reference; for a database build, an upstream that landed in a `storage=` destination; for a `storage=` build, a source that reaches the warehouse through a non-persisted source, or whose shape does not compile in the destination; on the database tier, an upstream whose table holds other columns than its build recorded (retyped or dropped since), could not be read, or whose build recorded no column types; and always, for a persisted view or named query, which builds from its source\'s definition. `upstreamRecomputeReason` says which. Such a table reflects the warehouse at THIS build\'s time rather than the upstream\'s snapshot, so the two can disagree when their refresh cadences differ. Not a location: it does not name the table the rows came from. Absent for a source that reads no persisted upstream, which has one way to build and no choice to report. A database rollup reports what its build actually read: `reused` only when it built from its base\'s materialized table, `recomputed` when it could not because that table holds other columns than its build recorded, could not be read, or recorded no column types, and absent when it built from the warehouse for any other reason. Before 0.15.0 every rollup over a persisted base reported `reused`. A `storage=` rollup reports `reused` only when it stacked on a stored table.
1488
1488
  */
1489
1489
  'upstreamReuse'?: ManifestEntryUpstreamReuseEnum;
1490
1490
  /**
@@ -1576,6 +1576,10 @@ export interface ManifestReference {
1576
1576
  * The storage destination the upstream table lives in, for a table a `storage=` build wrote; omit it for a table in the source\'s own warehouse. A stored table\'s `connectionName` is the source\'s warehouse connection, so without this field a reference to a stored table reads as a warehouse table. The publisher uses a reference as an upstream only where this agrees with where the upstream source is declared now (a source that moved to or from `storage=` keeps its content address): a stored upstream is stacked on in its destination, and never rendered into warehouse SQL. Optional and additive: a reference without it still serves a database upstream.
1577
1577
  */
1578
1578
  'storageDestinationName'?: string;
1579
+ /**
1580
+ * For a database upstream (no `storageDestinationName`): the `nativeSchema` the upstream\'s build reported on its manifest entry, sent back as it came. Before a build reads the referenced table in place of its source, it reads the table\'s columns from the warehouse and compares each with this type (case and spacing aside). If a column was retyped or dropped since, or cannot be read, a strict build is refused and any other build recomputes the upstream from its definition. Without it nothing can be checked: a strict build reads the table unchecked, with a warning and a count (`publisher_materialization_upstream_recompute_total`, `reason=\"reference_types_unrecorded\"`), and any other build recomputes the upstream. Ignored for a `storage=` upstream: omit it there. Optional and additive.
1581
+ */
1582
+ 'nativeSchema'?: Array<Column>;
1579
1583
  }
1580
1584
  /**
1581
1585
  * A record of one materialization run for a package.
@@ -3629,13 +3633,17 @@ export interface ServeVerdict {
3629
3633
  */
3630
3634
  'verdict': string;
3631
3635
  /**
3632
- * For a `live` verdict, why: `refused` (the plan refused to build it), `storage_mode` (`storage=` while `PERSIST_STORAGE_MODE` is not `on`), `unreachable` (no source on the package\'s published surface reads it), `row_level_gate` (every query through it carries an `#(authorize)` or `#(access_filter)` gate its table cannot keep yet, on either tier), `stale` (its table is past its freshness window, and its fallback does not serve stale), `shadowed` (its storage table is bound, but every model\'s source of that name is another source), `destination_missing` (`storage=` names a destination the environment does not configure), `connection_cannot_hold_table` (database, on a connection whose type creates no tables), `materialization_off` (a `#(materialize)` source, which only the served copy reads, and the served copy is off: `PUBLISHER_MATERIALIZE`, and for `storage=` `PERSIST_STORAGE_MODE`), `served_copy` (a source the served copy reads, `#(materialize)` or `#@ persist`, whose table is bound and built, but no model\'s served copy re-roots it, so its queries are answered live; `notServedIn` says where and why). An open set.
3636
+ * For a `live` verdict, why: `refused` (the plan refused to build it), `storage_mode` (`storage=` while `PERSIST_STORAGE_MODE` is not `on`), `unreachable` (no source on the package\'s published surface reads it), `row_level_gate` (every query through it carries an `#(authorize)` or `#(access_filter)` gate its table cannot keep yet, on either tier), `stale` (its table is past its freshness window, and its fallback does not serve stale), `shadowed` (its storage table is bound, but every model\'s source of that name is another source), `destination_missing` (`storage=` names a destination the environment does not configure), `connection_cannot_hold_table` (database, on a connection whose type creates no tables), `types_unrecorded` (database, bound, but its manifest entry records no column types, neither `schema` nor `nativeSchema`, so a change since the build cannot be ruled out; rebuild it), `materialization_off` (a `#(materialize)` source, which only the served copy reads, and the served copy is off: `PUBLISHER_MATERIALIZE`, and for `storage=` `PERSIST_STORAGE_MODE`), `served_copy` (a source the served copy reads, `#(materialize)` or `#@ persist`, whose table is bound and built, but no model\'s served copy re-roots it, so its queries are answered live; `notServedIn` says where and why). An open set.
3633
3637
  */
3634
3638
  'reason'?: string;
3635
3639
  /**
3636
3640
  * Each model file whose served copy holds this source (declares or imports it) but does not read its table, sorted by model, the same for a `#(materialize)` source and a `#@ persist` one. Present exactly when some model that holds the source does not read its table. With a `served_copy` reason it lists every such model (a model whose whole copy is off lists every stored source it holds, not only the one whose join failed it; a source no model\'s copy holds lists its declaring model, `not_rerooted`). On a `serves` verdict it lists the models that answer the source\'s queries live while another model serves it, so a consumer must read it: `serves` alone does not mean every model reads the table. Absent while a served copy has yet to compile. Read from the same compile of record as the `served-copy-not-served` warnings, never by running a query.
3637
3641
  */
3638
3642
  'notServedIn'?: Array<NotServedIn>;
3643
+ /**
3644
+ * Present, and always `true`, while some model that holds this source, which its served copy reads (`#(materialize)` or `#@ persist`), has yet to compile its served copy over the tables bound now. A bind returns before that compile, so the verdict carries no served-copy judgement yet: it may read `serves` for a table the compile will leave unread. A host must re-read the verdict while it is present; it is absent once every such model\'s copy is current, and then `notServedIn` and a `served_copy` reason are final for the bind.
3645
+ */
3646
+ 'servedCopyPending'?: boolean;
3639
3647
  /**
3640
3648
  * What the verdict means for this source, in a sentence.
3641
3649
  */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@malloy-publisher/sdk",
3
3
  "description": "Malloy Publisher SDK",
4
- "version": "0.17.1",
4
+ "version": "0.17.2",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs.js",
7
7
  "module": "dist/index.es.js",