@malloy-publisher/server 0.16.0 → 0.17.0

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.
Files changed (28) hide show
  1. package/dist/app/api-doc.yaml +266 -43
  2. package/dist/app/assets/{EnvironmentPage-Y9IWPC9J.js → EnvironmentPage-D2-0ts2G.js} +1 -1
  3. package/dist/app/assets/{HomePage-BOUo0MEl.js → HomePage-S_Bkczsx.js} +1 -1
  4. package/dist/app/assets/{MainPage-BkM5UDRU.js → MainPage-DEy4SyjJ.js} +1 -1
  5. package/dist/app/assets/{ModelPage-PgDTkS5C.js → ModelPage-BVHjDM-u.js} +2 -2
  6. package/dist/app/assets/{PackagePage-Dn7FrQ5r.js → PackagePage-Cbrg7o1X.js} +1 -1
  7. package/dist/app/assets/{PackageSplatRoute-BLC29ek-.js → PackageSplatRoute-ChFCJOWE.js} +2 -2
  8. package/dist/app/assets/{RenderedResult-vyM2wQbC.es-ha8dF24T.js → RenderedResult-BcEDcw0V.es-BD6PNbt6.js} +1 -1
  9. package/dist/app/assets/{RouteError-BolMqTuz.js → RouteError-CDSSYdLB.js} +1 -1
  10. package/dist/app/assets/{ThemeEditorPage-CPv1eHkI.js → ThemeEditorPage-DO2JWYOR.js} +1 -1
  11. package/dist/app/assets/{ToggleButtonGroup-DZtImN0S.js → ToggleButtonGroup-BylAiUaK.js} +1 -1
  12. package/dist/app/assets/{documentRoutes-DI5cX3ty.js → documentRoutes-CaOt2rpR.js} +1 -1
  13. package/dist/app/assets/{editPageMounted-C--4kcld.js → editPageMounted-79YCIKgP.js} +2 -2
  14. package/dist/app/assets/{index-DLToSg1f.js → index-BKjEX4_C.js} +10 -10
  15. package/dist/app/assets/{index-DyYEltlF.js → index-BOCBPBsi.js} +1 -1
  16. package/dist/app/assets/{index-D9wSfMZN.js → index-CPSEdm5f.js} +1 -1
  17. package/dist/app/assets/{index-CbsrzNSp.js → index-keJ8KKBp.js} +1 -1
  18. package/dist/app/assets/{index.es-D8SVyfmS.js → index.es-DTreXoC5.js} +1 -1
  19. package/dist/app/assets/usePackageLinkNavigate-BfSAqkJS.js +1 -0
  20. package/dist/app/assets/{usePackageRoute-A_YQMrax.js → usePackageRoute-G6fA1__J.js} +1 -1
  21. package/dist/app/index.html +1 -1
  22. package/dist/app/mcp-app/report.js +4 -4
  23. package/dist/instrumentation.mjs +2 -2
  24. package/dist/package_load_worker.mjs +1523 -456
  25. package/dist/server.mjs +29298 -24269
  26. package/dist/{sshcrypto-fqcyz88x.node → sshcrypto-wf5kpffj.node} +0 -0
  27. package/package.json +1 -1
  28. package/dist/app/assets/usePackageLinkNavigate-DxHGKrmZ.js +0 -1
@@ -1684,7 +1684,7 @@ paths:
1684
1684
  DEPRECATED. In-place mutation of a package contradicts immutable versions, so this
1685
1685
  operation will be removed. On a package that has published versions it changes only
1686
1686
  what is not content: a `manifestLocation` URI is bound to the package's `latest` version
1687
- (as `PUT .../packages/{packageName}/versions/{version}/manifest` does for any version),
1687
+ (as `PUT .../packages/{packageName}/versions/{versionId}/manifest` does for any version),
1688
1688
  while a null or empty one leaves the binding as it is (clear it with that route), and
1689
1689
  `description` is the package's. `name` and the `location` the version was published from
1690
1690
  may be sent back unchanged. Any other change is refused with 409 (`reason`
@@ -1784,8 +1784,8 @@ paths:
1784
1784
  background, cleans up each version as deleting it alone does: its own auto-runs still
1785
1785
  running are stopped and its own `scope: version` tables reclaimed. To take one
1786
1786
  version out of service while keeping the rest, archive it with
1787
- `PATCH .../packages/{packageName}/versions/{version}`; to remove one version for good,
1788
- delete it with `DELETE .../packages/{packageName}/versions/{version}`.
1787
+ `PATCH .../packages/{packageName}/versions/{versionId}`; to remove one version for good,
1788
+ delete it with `DELETE .../packages/{packageName}/versions/{versionId}`.
1789
1789
  parameters:
1790
1790
  - name: environmentName
1791
1791
  in: path
@@ -1850,7 +1850,7 @@ paths:
1850
1850
  "503":
1851
1851
  $ref: "#/components/responses/ServiceUnavailable"
1852
1852
 
1853
- /environments/{environmentName}/packages/{packageName}/versions/{version}:
1853
+ /environments/{environmentName}/packages/{packageName}/versions/{versionId}:
1854
1854
  get:
1855
1855
  tags:
1856
1856
  - versions
@@ -1897,7 +1897,7 @@ paths:
1897
1897
  table is tried once: one that cannot be dropped is left, and its run record goes all
1898
1898
  the same. Its
1899
1899
  files stay on disk, so it can be unarchived. To remove them, delete the version with
1900
- `DELETE .../versions/{version}`.
1900
+ `DELETE .../versions/{versionId}`.
1901
1901
  - `unarchive` puts it back in service. It loads again on its next read, and serves live
1902
1902
  until it is built again.
1903
1903
 
@@ -2000,7 +2000,7 @@ paths:
2000
2000
  "503":
2001
2001
  $ref: "#/components/responses/ServiceUnavailable"
2002
2002
 
2003
- /environments/{environmentName}/packages/{packageName}/versions/{version}/manifest:
2003
+ /environments/{environmentName}/packages/{packageName}/versions/{versionId}/manifest:
2004
2004
  put:
2005
2005
  tags:
2006
2006
  - versions
@@ -2411,6 +2411,10 @@ paths:
2411
2411
  fails only at the grammar and names no source to run (for example `run` with no colon) is also
2412
2412
  a 400, because a grammar error says nothing about the model, unless the model carries any
2413
2413
  `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface.
2414
+
2415
+ The version queried may be named in the body (`QueryRequest.versionId`), in the URL
2416
+ (`?versionId=`), or both. When both name a version and they differ, the request answers
2417
+ 400 with `reason` VERSION_ID_INVALID; an empty value in either names none.
2414
2418
  parameters:
2415
2419
  - name: environmentName
2416
2420
  in: path
@@ -2431,6 +2435,7 @@ paths:
2431
2435
  schema:
2432
2436
  $ref: "#/components/schemas/PathPattern"
2433
2437
  - $ref: "#/components/parameters/includeHiddenFilesAndSources"
2438
+ - $ref: "#/components/parameters/versionId"
2434
2439
  requestBody:
2435
2440
  required: true
2436
2441
  content:
@@ -3956,6 +3961,12 @@ paths:
3956
3961
  plan (read off `Package.buildPlan`). Returns the materialization already building.
3957
3962
  * Auto-run (standalone, default) — omit `buildInstructions`; the publisher
3958
3963
  self-assigns names and runs all phases in one pass.
3964
+
3965
+ The version to build is named in the body (`versionId`). A `?versionId=` in the URL,
3966
+ as every other materialization operation takes, is read too; when both name a version
3967
+ and they differ, the request answers 400 with `reason` VERSION_ID_INVALID, and an empty
3968
+ value in either names none. It is not declared as a parameter here: an optional query
3969
+ parameter would move the optional body argument of every generated client.
3959
3970
  parameters:
3960
3971
  - $ref: "#/components/parameters/environmentName"
3961
3972
  - $ref: "#/components/parameters/packageName"
@@ -4591,6 +4602,13 @@ components:
4591
4602
  succeed. That reason is what marks the customer's database being down
4592
4603
  rather than this server failing. The body carries a fixed message,
4593
4604
  because the driver's text can name an internal host; it is logged.
4605
+ With `reason: RESULT_TRUNCATED` the database answered, but with fewer
4606
+ rows than it reported and no row limit cut them (a BigQuery answer past
4607
+ one results page of about 10 MB); the query is refused rather than
4608
+ answered short, and a retry fails the same way. With
4609
+ `reason: RESULT_SHAPE_MISMATCH` the database answered, but a row does
4610
+ not fit the schema Malloy declared for the result, so the result could
4611
+ not be built; the message is fixed and the cause is logged.
4594
4612
  content:
4595
4613
  application/json:
4596
4614
  schema:
@@ -4659,9 +4677,11 @@ components:
4659
4677
  format: date-time
4660
4678
  expiredSnapshots:
4661
4679
  type: integer
4680
+ format: int64
4662
4681
  description: Snapshots this cleanup expired
4663
4682
  deletedFiles:
4664
4683
  type: integer
4684
+ format: int64
4665
4685
  description: Data and delete files this cleanup removed from storage
4666
4686
 
4667
4687
  VersionIdPattern:
@@ -4771,7 +4791,7 @@ components:
4771
4791
  description: >-
4772
4792
  The build manifest this version is bound to (see
4773
4793
  `Package.manifestLocation`); null when it serves live. Set with
4774
- `PUT .../versions/{version}/manifest`.
4794
+ `PUT .../versions/{versionId}/manifest`.
4775
4795
  gitCommitSha:
4776
4796
  type: ["string", "null"]
4777
4797
  readOnly: true
@@ -6192,9 +6212,9 @@ components:
6192
6212
  the base, or `<base>.<measure>` for one measure). The
6193
6213
  message says why, and `reason` is the refusal record's
6194
6214
  bounded reason. `preaggregate-not-built` is
6195
- `rollup-not-built`'s former name: each `rollup-not-built`
6196
- warning is repeated under it, with the same message, for
6197
- this release only. `persist-source-refused`, the former name
6215
+ `rollup-not-built`'s former name, retained, no longer
6216
+ produced: 0.15.0 and 0.16 repeated each `rollup-not-built`
6217
+ warning under it. `persist-source-refused`, the former name
6198
6218
  of `persist-not-built` repeated beside it in 0.14.0, is no
6199
6219
  longer produced.
6200
6220
  Retained, no longer produced: the rollup sub-family
@@ -6226,9 +6246,9 @@ components:
6226
6246
  `rollup-join-one-key-repeated`: a rollup's last build found
6227
6247
  a `join_one` key repeated in the data, so queries that read
6228
6248
  that join beside other aggregates are answered live
6229
- (`subject` the rollup's base; `warn`). Repeated under its
6230
- former name `preaggregate-join-one-key-repeated` for this
6231
- release only.
6249
+ (`subject` the rollup's base; `warn`). Its former name,
6250
+ `preaggregate-join-one-key-repeated`, is retained, no longer
6251
+ produced.
6232
6252
  `served-copy-not-served`: the served copy (the author's own
6233
6253
  files, each stored source re-rooted on its table) leaves a
6234
6254
  source as written, so it answers live, or serves it with a
@@ -6260,6 +6280,14 @@ components:
6260
6280
  `persist-incremental-no-merge-key`: an incremental source
6261
6281
  with no `merge_key=`, so each refresh replaces its watermark
6262
6282
  range (`subject` the source; `warn`).
6283
+ `persist-reads-current-time`: a `#@ persist` source,
6284
+ persisted view or persisted named query whose stored
6285
+ relation reads the current time (`now`, or a relative time
6286
+ filter string such as `f'last 7 days'`), so its answers are
6287
+ as of its last build and it is rebuilt on every run; the
6288
+ message names where it reads the clock and how to answer as
6289
+ of each query instead (one per table, `subject` the source,
6290
+ the view as `<source> -> <view>`, or the query; `warn`).
6263
6291
  `persist-incremental-shared-address`: sources that compile to
6264
6292
  the same SQL on one connection, so they share one table and
6265
6293
  one boundary, where at least one is incremental (one per
@@ -6345,8 +6373,9 @@ components:
6345
6373
  full rebuild captures the types (one per source, `model` the
6346
6374
  first model binding it, `subject` the source, the message
6347
6375
  naming the columns and which applies; `warn`; see
6348
- docs/materialization.md). Repeated under its former name
6349
- `stored-native-schema-missing` for this release only.
6376
+ docs/materialization.md). Its former name,
6377
+ `stored-native-schema-missing`, is retained, no longer
6378
+ produced.
6350
6379
  `entities-…` (`entities-not-a-dimension`,
6351
6380
  `entities-parameterized-source`,
6352
6381
  `entities-multiple-required-filters`,
@@ -6681,6 +6710,7 @@ components:
6681
6710
  minimum: 1
6682
6711
  llm_tokens:
6683
6712
  type: integer
6713
+ format: int64
6684
6714
  minimum: 1
6685
6715
  job_minutes:
6686
6716
  type: integer
@@ -7379,8 +7409,8 @@ components:
7379
7409
  in `tiles=[…]`, or else from a `# break` on the view or query it
7380
7410
  names; `break=false` on the entry turns off the view's. Named for the tag, so every per-tile field on this
7381
7411
  schema is spelled the way an author writes it. A generated client
7382
- escapes the attribute where the word is reserved (the Python client
7383
- exposes `break_`) while the wire key stays `break`.
7412
+ escapes the attribute where the word is reserved (a generated Python
7413
+ client exposes `break_`) while the wire key stays `break`.
7384
7414
  borderless:
7385
7415
  type: boolean
7386
7416
  description: >-
@@ -8614,10 +8644,9 @@ components:
8614
8644
  empty, the query runs against the package's `latest` version. An unknown version
8615
8645
  answers 404 (`reason` VERSION_NOT_FOUND) and an archived one 410
8616
8646
  (`reason` VERSION_ARCHIVED). A `versionId` in the request's query
8617
- string, as a proxy forwarding a page's URL sends, is read the same way;
8618
- when both name a version they must agree, or the request answers 400.
8619
- It is not declared as a query parameter, so generated clients keep
8620
- their argument order.
8647
+ string (the operation's `versionId` parameter) is read the same way;
8648
+ when both name a version they must agree, or the request answers 400
8649
+ with `reason` VERSION_ID_INVALID.
8621
8650
  filterParams:
8622
8651
  type: object
8623
8652
  deprecated: true
@@ -8906,9 +8935,11 @@ components:
8906
8935
  database `#(materialize)` table the served copy read, or a
8907
8936
  database rollup or persisted view.
8908
8937
 
8909
- `live_fallback` — the query DID route to storage and the store then
8910
- failed underneath it, and the source's freshness fallback allowed it
8911
- to degrade to the live warehouse. **The rows are correct and the
8938
+ `live_fallback` — the query DID route to a stored table (a
8939
+ `storage=` table, a database table the served copy reads, or a
8940
+ rollup on either tier) and that read then failed underneath it, and
8941
+ the source's freshness fallback allowed it to degrade to the live
8942
+ warehouse (a rollup's always does). **The rows are correct and the
8912
8943
  request succeeded**, which is why this needs its own value: it is
8913
8944
  indistinguishable from a storage hit at the call site, and treating it
8914
8945
  as one would report a healthy hit rate for a broken store. On
@@ -8941,6 +8972,7 @@ components:
8941
8972
  histogram for rates and percentiles.
8942
8973
  queryCostBytes:
8943
8974
  type: ["integer", "null"]
8975
+ format: int64
8944
8976
  description: >-
8945
8977
  Warehouse bytes this query SCANNED, as reported by the backend that
8946
8978
  ran it. Not what it is billed — see below.
@@ -9177,11 +9209,14 @@ components:
9177
9209
  description: >-
9178
9210
  For a `NOT_SERVED` skip, the serve verdict's reason the table
9179
9211
  answers no query, from the same set as `QueryPathWarning.code`;
9180
- for a table only the served copy reads, `served_copy` also when
9181
- the served copy does not re-root the queried source (the
9212
+ for a `storage=` table only the served copy reads, `served_copy`
9213
+ also when the served copy declined this query on it, such as
9214
+ when it does not re-root the queried source (the
9182
9215
  `served-copy-not-served` package warning says why). Always
9183
- snake_case. An open set. Absent on any other outcome, and on a
9184
- `NOT_SERVED` skip whose verdict is not known.
9216
+ snake_case. An open set. Absent on any other outcome, on a
9217
+ `NOT_SERVED` skip whose verdict is not known, and on a database
9218
+ table the served copy declined for this query alone (its
9219
+ `detail` says why).
9185
9220
 
9186
9221
 
9187
9222
  Retained, no longer produced (shipped in 0.14.0):
@@ -9258,9 +9293,24 @@ components:
9258
9293
  - RUN_FAILED
9259
9294
  description: >-
9260
9295
  Why a table could not answer a query. `NOT_BUILT`, it is not bound to
9261
- this package yet; `NOT_SERVED`, its serve verdict is `live`, so it
9262
- answers no query, and the candidate's `code` names the verdict's
9263
- reason; `OPTED_OUT`, the queried source opts out of its tables with
9296
+ this package yet; `NOT_SERVED`, either its serve verdict is `live`,
9297
+ so it answers no query, and the candidate's `code` names the
9298
+ verdict's reason, or the table otherwise serves and the served copy
9299
+ declined this one query on it. A `storage=` table only the served
9300
+ copy reads is then `NOT_SERVED` with `code` `served_copy` when the
9301
+ served copy re-roots nothing the query reads, cannot graft a gate on
9302
+ the queried source, would answer without a column a gate or the
9303
+ result (through a wildcard) needs because it leaves that column out
9304
+ of a stored table's type, would expose a field the compile of record
9305
+ does not classify or carry, resolves a composite to another member
9306
+ than live, or the source's ungated `where:` reads a column the table
9307
+ does not hold exactly or does not compare as its source does (a
9308
+ zoned timestamp, or a collation: on Postgres a database table's
9309
+ stored collation that differs from its source's or cannot be read).
9310
+ A database table is `NOT_SERVED` this way only for that last case,
9311
+ with a `detail` and no `code`. A query that itself names a column a
9312
+ stored table leaves out is `MISSING_FIELD`, and a gate the table
9313
+ cannot keep is `ROW_LEVEL_GATE`; `OPTED_OUT`, the queried source opts out of its tables with
9264
9314
  `#@ -persist`; `MISSING_FIELD`, the query reads a field the table
9265
9315
  lacks (or otherwise does not compile against it); `SHAPE_MISMATCH`,
9266
9316
  the query is not the shape the stored result answers: it is not a
@@ -9273,8 +9323,10 @@ components:
9273
9323
  needs a join the table's connection cannot reach; `COUNT_SEMANTICS`,
9274
9324
  an aggregate the table cannot reproduce as the live query computes
9275
9325
  it; `STALE`, it is past its freshness window; `READ_FAILED`, it was
9276
- chosen but reading it failed at run time, and its freshness fallback
9277
- allowed live.
9326
+ chosen but reading it failed at run time and the query was answered
9327
+ live: its freshness fallback allowed live, or the failure answers live
9328
+ whatever the fallback says (DECIMAL arithmetic past what the
9329
+ destination holds, or a destination catalog missing on the worker).
9278
9330
 
9279
9331
 
9280
9332
  Retained, no longer produced (shipped in 0.14.0): `WARNED`, now
@@ -10336,6 +10388,19 @@ components:
10336
10388
  are fine; retrying elsewhere will not help, and neither will
10337
10389
  rewriting the query.
10338
10390
 
10391
+ RESULT_TRUNCATED, on a 502, means the database returned fewer rows
10392
+ than it reported and no row limit cut them: a BigQuery answer
10393
+ larger than one results page (about 10 MB) whose later pages were
10394
+ not read. The query is refused rather than answered short.
10395
+ Retrying returns the same page; select fewer columns, aggregate,
10396
+ or return fewer rows.
10397
+
10398
+ RESULT_SHAPE_MISMATCH, on a 502, means the database answered but a
10399
+ row does not fit the schema Malloy declared for the result (a value
10400
+ of another type than its column's), so the result could not be
10401
+ built. The query is not the caller's to fix; the server logs the
10402
+ cause.
10403
+
10339
10404
  CONNECTION_AUTH_FAILED, on a 424, means the database rejected the
10340
10405
  connection's credentials (a wrong password, an invalid key, an
10341
10406
  expired token), so the query never ran. Whoever configures the
@@ -10445,8 +10510,8 @@ components:
10445
10510
  * VERSION_ARCHIVED (410): the version is archived.
10446
10511
 
10447
10512
  Known values: TABLE_NOT_FOUND, CONNECTION_FAILED,
10448
- CONNECTION_AUTH_FAILED, CONNECTION_NOT_FOUND,
10449
- STORAGE_ACCESS_DENIED, PATH_ACCESS_DENIED, ACCESS_DENIED,
10513
+ CONNECTION_AUTH_FAILED, CONNECTION_NOT_FOUND, RESULT_TRUNCATED,
10514
+ RESULT_SHAPE_MISMATCH, STORAGE_ACCESS_DENIED, PATH_ACCESS_DENIED, ACCESS_DENIED,
10450
10515
  MATERIALIZATION_REFUSED, TABLE_OWNED_ELSEWHERE,
10451
10516
  TABLE_OWNERSHIP_UNVERIFIED, TABLE_IN_USE, BUILD_INSTRUCTIONS_INVALID,
10452
10517
  MATERIALIZATION_CONFLICT, MANIFEST_VERSION_MISSING, MANIFEST_VERSION_INVALID,
@@ -10489,6 +10554,7 @@ components:
10489
10554
  description: Name of the table
10490
10555
  rowCount:
10491
10556
  type: integer
10557
+ format: int64
10492
10558
  description: Number of rows in the table
10493
10559
  columns:
10494
10560
  type: array
@@ -10790,9 +10856,12 @@ components:
10790
10856
  The published version of the package to build. `latest`, omitted or
10791
10857
  empty, the package's `latest` version is built. An unknown version answers 404
10792
10858
  (`reason` VERSION_NOT_FOUND) and an archived one 410 (`reason`
10793
- VERSION_ARCHIVED). Carried in the body rather than the query string
10794
- because the body is optional: a new optional query parameter ahead
10795
- of it would move the body argument of every generated client.
10859
+ VERSION_ARCHIVED). Carried in the body rather than a declared query
10860
+ parameter because the body is optional: a new optional query
10861
+ parameter ahead of it would move the body argument of every
10862
+ generated client. A `?versionId=` in the URL is read too, and must
10863
+ agree with this one when both name a version (400
10864
+ VERSION_ID_INVALID otherwise).
10796
10865
 
10797
10866
  The run records the version it built in `metadata.versionId`, with
10798
10867
  the package's materialization scope in `metadata.scope`, which
@@ -10832,8 +10901,12 @@ components:
10832
10901
  default: false
10833
10902
  description: >-
10834
10903
  Build a new table even when a source's sourceEntityId is unchanged —
10835
- that is, defeat skip-if-unchanged, which would otherwise carry the
10836
- existing table forward and run no SQL for that source.
10904
+ that is, defeat skip-if-unchanged, which would otherwise carry an
10905
+ unchanged table forward and run no SQL for that source. Not every
10906
+ unchanged table is carried: one whose source refreshes
10907
+ incrementally, one past its declared freshness window, and one
10908
+ whose stored relation reads the current time (the plan entry's
10909
+ `asOfBuild`) are rebuilt on every run without this flag.
10837
10910
 
10838
10911
  It means ONLY that. It never re-seeds a source declaring
10839
10912
  `refresh="incremental"`: such a source is exempt from
@@ -11294,6 +11367,7 @@ components:
11294
11367
  partial_name_collision,
11295
11368
  given_where_over_unstored_field,
11296
11369
  unreadable_grain,
11370
+ upstream_unread,
11297
11371
  ]
11298
11372
  description: >-
11299
11373
  The bounded refusal reason; `message` says the specifics.
@@ -11333,7 +11407,12 @@ components:
11333
11407
  give no container; refused at plan, before any warehouse work);
11334
11408
  `storage_source_unsupported` (`storage=` on a
11335
11409
  source whose connection the build cannot pass through to a
11336
- destination, e.g. the package's DuckDB sandbox);
11410
+ destination, e.g. the package's DuckDB sandbox; or a source that
11411
+ carries author SQL, an `.sql()` source, a `sql_*` expression or a
11412
+ file or URL read as a table, whose table would be built inside a
11413
+ catalog, which runs only SQL Malloy generated: a `storage=` source
11414
+ on a DuckLake connection, or a source of any tier on a connection
11415
+ configured `managed`);
11337
11416
  `table_name_collision` (under `PERSIST_COLLISION_ENFORCE=false`, a
11338
11417
  declaration whose `name=` puts it on one table with another, so
11339
11418
  neither is built; by default such a package does not load; a run
@@ -11345,7 +11424,13 @@ components:
11345
11424
  source's own extend block is applied at every read and is
11346
11425
  admitted); `incremental_unsupported` (a valid incremental
11347
11426
  declaration this deployment's dialect or destination cannot
11348
- honour).
11427
+ honour); `upstream_unread` (a table its build reads could not be
11428
+ read from its warehouse's catalog when the package loaded, after
11429
+ retrying, and this process has no earlier reading of it, so its
11430
+ content address is not known: it is not built, no run builds it,
11431
+ and a host's instruction for it is refused, until a reload or a
11432
+ plan refresh reads the catalog and plans it at its address; the
11433
+ `*-not-built` warning names the table).
11349
11434
 
11350
11435
 
11351
11436
  A persisted view or named query: `materialization_off` (persisted
@@ -11424,6 +11509,15 @@ components:
11424
11509
  declaration's `*-not-built` warning. For a `#@ persist` gate
11425
11510
  refusal it is the same text a build attempting the source would
11426
11511
  422 with.
11512
+ freshness:
11513
+ $ref: "#/components/schemas/Freshness"
11514
+ description: >-
11515
+ The freshness the refused source declares, resolved as a planned
11516
+ source's is (source, then model file, then package). A package
11517
+ `materialization.schedule` beside it is refused at publish as
11518
+ beside a planned source's: a refused source declares its window
11519
+ all the same. Absent when it declares none, or when the refusal
11520
+ comes from an annotation finding rather than the plan.
11427
11521
 
11428
11522
  BuildGraph:
11429
11523
  type: object
@@ -11634,6 +11728,19 @@ components:
11634
11728
  advances its serving table by a bounded delta in place instead of
11635
11729
  being rebuilt, so the mode also governs the build path — which is why
11636
11730
  it is validated rather than passed through.
11731
+ asOfBuild:
11732
+ type: boolean
11733
+ description: >-
11734
+ True when this source's stored relation reads the current time
11735
+ (`now`, or a relative time filter string such as
11736
+ `f'last 7 days'`), so its table holds the rows as of its build
11737
+ and its answers are as of that build (a `#@ persist` source, a
11738
+ persisted view or a persisted named query; the package carries a
11739
+ `persist-reads-current-time` warning for it). Unchanged SQL does
11740
+ not mean unchanged rows, so such a table must be rebuilt on every
11741
+ run: a host that reuses a ready table by `sourceEntityId` must
11742
+ not reuse this one, and a standalone run never carries it
11743
+ forward. Absent otherwise.
11637
11744
  freshness:
11638
11745
  oneOf:
11639
11746
  - $ref: "#/components/schemas/Freshness"
@@ -11687,6 +11794,41 @@ components:
11687
11794
  description: Output schema of the source.
11688
11795
  items:
11689
11796
  $ref: "#/components/schemas/Column"
11797
+ reads:
11798
+ type: array
11799
+ items:
11800
+ $ref: "#/components/schemas/TableRead"
11801
+ description: >-
11802
+ The warehouse tables this entry's build reads, distinct and sorted
11803
+ by connection then table: each `connection.table('...')` in the
11804
+ source's lineage, read off the same fully inlined definition `sql`
11805
+ and `sourceEntityId` are computed from. A table a persisted
11806
+ upstream reads is therefore listed here too, since this source's
11807
+ rows derive from it. A join is listed only when the build reads it
11808
+ (a field, filter or nest of the build reaches it); a join the
11809
+ source declares and the build never uses is not.
11810
+
11811
+
11812
+ Absent when the tables cannot be known: the lineage holds an
11813
+ `.sql()` source (its SQL text names tables Malloy does not parse)
11814
+ or a raw SQL expression such as `sql_number()` (which may hold a
11815
+ subquery). A host that rebuilds only the entries reading a replaced
11816
+ table MUST treat an absent `reads` as possibly reading any table on
11817
+ its connection, and an empty one as reading none. Not part of
11818
+ `sourceEntityId`.
11819
+ upstreamSchemas:
11820
+ type: array
11821
+ items:
11822
+ $ref: "#/components/schemas/UpstreamTableSchema"
11823
+ description: >-
11824
+ Each table in `reads` with its columns' types as its warehouse's
11825
+ catalog named them when this package was loaded (or why it could
11826
+ not be read). Part of `sourceEntityId`: a table whose columns or
11827
+ types change re-addresses every source that reads it, so its table
11828
+ is rebuilt rather than carried or reused. Read at the package's
11829
+ first load in a process and again on every explicit reload or
11830
+ publish. Absent when `reads` is absent: such a source's address is
11831
+ its SQL's alone.
11690
11832
  annotationFields:
11691
11833
  type: object
11692
11834
  additionalProperties:
@@ -11758,6 +11900,68 @@ components:
11758
11900
  `#@ preaggregate` annotations it was synthesized from, which is where
11759
11901
  an author would go to change it.
11760
11902
 
11903
+ UpstreamTableSchema:
11904
+ type: object
11905
+ required: [connectionName, table]
11906
+ description: >-
11907
+ One warehouse table a persist source's build reads, with its columns'
11908
+ types as the warehouse's own catalog names them (`NUMERIC(12,4)`,
11909
+ `FLOAT64`, `DOUBLE`), read when the package was loaded. Exactly one of
11910
+ `columns` and `unread` is present.
11911
+ properties:
11912
+ connectionName:
11913
+ type: string
11914
+ description: The Malloy connection the table is read through, as in `TableRead`.
11915
+ table:
11916
+ type: string
11917
+ description: The table path exactly as the model wrote it, as in `TableRead`.
11918
+ dialect:
11919
+ type: string
11920
+ description: >-
11921
+ The dialect of the connection the types are named in (`snowflake`,
11922
+ `postgres`, `standardsql`, `duckdb`, ...): one type name means
11923
+ different types on different dialects (Snowflake's `FLOAT` is a
11924
+ double, DuckDB's a 4-byte float). Present with `columns`.
11925
+ columns:
11926
+ type: array
11927
+ description: Each column, in catalog order, with its native type.
11928
+ items:
11929
+ type: object
11930
+ required: [name, nativeType]
11931
+ properties:
11932
+ name:
11933
+ type: string
11934
+ nativeType:
11935
+ type: string
11936
+ unread:
11937
+ type: string
11938
+ enum: [no_catalog, not_found, ambiguous, read_failed]
11939
+ description: >-
11940
+ Why the table has no columns here. `no_catalog`: its dialect gives
11941
+ this table no catalog to read (an unqualified BigQuery name, a path
11942
+ the catalog cannot parse). `not_found`: the catalog holds no such
11943
+ table (a BigQuery wildcard table, a table not created yet).
11944
+ `ambiguous`: an unqualified name the catalog holds in more than one
11945
+ schema. These three are stable and fold into the address.
11946
+ `read_failed`: the catalog read failed and no earlier reading of
11947
+ the table was known in this process; the plan refuses each source
11948
+ that reads it (`upstream_unread`), so no address folds it.
11949
+ TableRead:
11950
+ type: object
11951
+ required: [connectionName, table]
11952
+ description: One warehouse table a persist source's build reads.
11953
+ properties:
11954
+ connectionName:
11955
+ type: string
11956
+ description: >-
11957
+ The Malloy connection the table is read through, as the model names
11958
+ it (the `lake` of `lake.table('orders')`).
11959
+ table:
11960
+ type: string
11961
+ description: >-
11962
+ The table path exactly as the model wrote it inside `.table('...')`
11963
+ (e.g. `analytics.orders`), unquoted and unqualified by anything the
11964
+ connection adds; on DuckDB it may be a file path or URL.
11761
11965
  PreaggregatePlan:
11762
11966
  type: object
11763
11967
  description: >-
@@ -12426,12 +12630,25 @@ components:
12426
12630
  producer did not record it.
12427
12631
  items:
12428
12632
  $ref: "#/components/schemas/Column"
12633
+ upstreamSchemas:
12634
+ type: array
12635
+ description: >-
12636
+ The warehouse tables this table's build read, each with its columns'
12637
+ native types as the build's plan read them from the catalog (the
12638
+ plan's `PersistSourcePlan.upstreamSchemas`), on both tiers. The
12639
+ `sourceEntityId` folds them in, so an entry whose upstream was
12640
+ retyped since is never the current address's. A host that stores
12641
+ entries keeps this field as written. Absent on an entry built
12642
+ before 0.17.0, and for a source whose tables cannot be known.
12643
+ items:
12644
+ $ref: "#/components/schemas/UpstreamTableSchema"
12429
12645
  realization:
12430
12646
  allOf:
12431
12647
  - $ref: "#/components/schemas/Realization"
12432
12648
  description: Retained; always `COPY`.
12433
12649
  rowCount:
12434
12650
  type: ["integer", "null"]
12651
+ format: int64
12435
12652
  buildDurationMs:
12436
12653
  type: ["integer", "null"]
12437
12654
  description: >-
@@ -12449,6 +12666,7 @@ components:
12449
12666
  the run's duration by whatever the orchestration cost.
12450
12667
  queryCostBytes:
12451
12668
  type: ["integer", "null"]
12669
+ format: int64
12452
12670
  description: >-
12453
12671
  Warehouse bytes SCANNED by the read that produced this table — the
12454
12672
  recurring cost of keeping the source materialized, and the debit
@@ -12618,6 +12836,7 @@ components:
12618
12836
  properties:
12619
12837
  count:
12620
12838
  type: integer
12839
+ format: int64
12621
12840
  description: Source rows in the window the stored table lacks.
12622
12841
  from:
12623
12842
  type: string
@@ -12729,10 +12948,14 @@ components:
12729
12948
 
12730
12949
  Build metadata must be percent-encoded: send `1.2.0+build.5` as
12731
12950
  `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space.
12951
+
12952
+ Accepted: `latest`, empty, or a semantic version. The schema carries no
12953
+ pattern on purpose: a validator generated from one would refuse `latest`
12954
+ and the empty value.
12732
12955
  schema:
12733
12956
  type: string
12734
12957
  versionPath:
12735
- name: version
12958
+ name: versionId
12736
12959
  in: path
12737
12960
  required: true
12738
12961
  description: |
@@ -1 +1 @@
1
- import{y as r,C as t,j as e,a7 as i,aa as o}from"./index-DLToSg1f.js";function m(){const s=r(),{environmentName:n}=t();if(n){const a=i({environmentName:n});return e.jsx(o,{onSelectPackage:s,resourceUri:a})}else return e.jsx("div",{children:e.jsx("h2",{children:"Missing environment name"})})}export{m as default};
1
+ import{y as r,C as t,j as e,a7 as i,aa as o}from"./index-BKjEX4_C.js";function m(){const s=r(),{environmentName:n}=t();if(n){const a=i({environmentName:n});return e.jsx(o,{onSelectPackage:s,resourceUri:a})}else return e.jsx("div",{children:e.jsx("h2",{children:"Missing environment name"})})}export{m as default};
@@ -1 +1 @@
1
- import{y as t,j as o,I as a}from"./index-DLToSg1f.js";function s(){const n=t();return o.jsx(a,{onClickEnvironment:n})}export{s as default};
1
+ import{y as t,j as o,I as a}from"./index-BKjEX4_C.js";function s(){const n=t();return o.jsx(a,{onClickEnvironment:n})}export{s as default};