@malloy-publisher/sdk 0.18.5 → 0.18.7
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.
- package/dist/{RenderedResult-D0SdTDx-.cjs.js → RenderedResult-B7Vw2U4r.cjs.js} +1 -1
- package/dist/{RenderedResult-cJiP774J.es.js → RenderedResult-BkBdGb49.es.js} +35 -35
- package/dist/{ServerProvider-BRGSDxay.es.js → ServerProvider-Caw1M640.es.js} +1386 -1162
- package/dist/ServerProvider-DorQnQ-Q.cjs.js +1 -0
- package/dist/builder/index.cjs.js +1 -1
- package/dist/builder/index.es.js +3 -3
- package/dist/client/api.d.ts +455 -30
- package/dist/client/index.cjs.js +1 -1
- package/dist/client/index.es.js +146 -131
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +344 -344
- package/dist/{useCompiledDocument-BNtiFhPK.es.js → useCompiledDocument-C3k5Ro8W.es.js} +2 -2
- package/dist/{useCompiledDocument-DanZRwMi.cjs.js → useCompiledDocument-CqI1slum.cjs.js} +2 -2
- package/package.json +1 -1
- package/dist/ServerProvider-BexMzLld.cjs.js +0 -1
package/dist/client/api.d.ts
CHANGED
|
@@ -445,6 +445,18 @@ export interface Column {
|
|
|
445
445
|
* Data type of the column
|
|
446
446
|
*/
|
|
447
447
|
'type'?: string;
|
|
448
|
+
/**
|
|
449
|
+
* With `include=collations`: the column\'s type as the warehouse\'s catalog names it (`character varying(20)`, `STRING`, `VARCHAR`). Unlike `type`, always the warehouse\'s own name.
|
|
450
|
+
*/
|
|
451
|
+
'nativeType'?: string;
|
|
452
|
+
/**
|
|
453
|
+
* With `include=collations`: the column\'s collation identity, as a materialization\'s column contract records it: `binary` for byte order, else the engine\'s identity (`postgres:…`, `bigquery:und:ci`, `duckdb:nocase`). Null for a column that is not a string. A record\'s members carry neither field.
|
|
454
|
+
*/
|
|
455
|
+
'collation'?: string | null;
|
|
456
|
+
/**
|
|
457
|
+
* With `include=collations`, present and true on a DuckLake 128-bit integer column, whose files hold it as a DOUBLE.
|
|
458
|
+
*/
|
|
459
|
+
'storedAsDouble'?: boolean;
|
|
448
460
|
}
|
|
449
461
|
/**
|
|
450
462
|
* What a materialized table\'s build recorded about each of its columns, so a stored read is judged against facts recorded once at build rather than probed per query. A host that stores entries keeps it as written (as text is fine) and sends it back unparsed. Readers ignore keys they do not know, at every level, so later releases may add keys. An entry with no `contract`, an empty one, or one without `v` has no contract: its table is not served from until it is rebuilt (serve verdict reason `contract_missing`). A column the contract does not list is treated as unknown: `compare` `none`, `gateExact` false.
|
|
@@ -456,7 +468,7 @@ export interface ColumnContract {
|
|
|
456
468
|
*/
|
|
457
469
|
'v'?: number;
|
|
458
470
|
/**
|
|
459
|
-
* The Publisher version whose build wrote it
|
|
471
|
+
* The Publisher version whose build wrote it. Read only to judge a string column recorded before `ContractColumn.compareFrom` was, on any dialect: its `none` is taken as unread when this is a semantic version before 0.18.5 by semver precedence (`0.18.5-rc.1` is before), the column is stored `binary` under a binary `defaultCollation`, and its source\'s dialect has collations Publisher reads (DuckDB, Postgres, BigQuery). Otherwise, including when this is absent or not a semantic version, it is taken as read.
|
|
460
472
|
*/
|
|
461
473
|
'producer'?: string;
|
|
462
474
|
/**
|
|
@@ -535,7 +547,7 @@ export interface CompileRequest {
|
|
|
535
547
|
*/
|
|
536
548
|
'source'?: string;
|
|
537
549
|
/**
|
|
538
|
-
* What the source means, and how far the check reaches. \"append\" (default) appends the source to the model in the URL and compiles it in that namespace — right for NEW definitions; an edit to an existing definition collides (\"Cannot redefine\"), and diagnostic positions land in the concatenated virtual file. \"file\" compiles the source AS that model, replacing its on-disk content for the check — validates an edit before saving, at true file coordinates. \"package\" runs the same worker compiler and file selection as reload over every .malloy and .malloynb file, without swapping the result into the served package; with a source, importers compile against the replacement. It also reports the render-tag findings (code \"render-tag\"), the dashboard, given and drill findings (code \"dashboard-lint\") and each .malloynb code cell the query route would refuse (code \"malloynb-cell-refused\", at most 10 per notebook and 50 per package, with the rest named in \"malloynb-cells-unlisted\" summaries, one per notebook that lists some and one for the notebooks past the package limit, and \"malloynb-cell-check-failed\" for a notebook that could not be checked) a reload would put on the package\'s warnings, at their own severity and with no position, and the load\'s verdict on the materialization annotations: each line a load fails with as an error with its code, each annotation the load leaves unbuilt as a warning (\"file\" reports the same verdict when the file names a materialization route or the package plans a table). The package\'s other warnings (storage, bound tables, explores, surface and discovery warnings, among others) are not reported. Package diagnostics can name files hidden from discovery. No rows or SQL are returned, and caller-provided source remains subject to authorize gates. includeSql is not available at \"package\". \"append\" text is checked against the model\'s PUBLISHED surface, so it may not declare its own data roots: import, connection.table(…), connection.sql(…), given:, ##! compiler flags and the raw-SQL function forms (name!type(…), sql_number, sql_string and the rest of that family) are refused with a 400. Those belong in a model file, so validate text declaring them at \"file\" or \"package\", which are not restricted. \"append\" text must also stand alone as top-level Malloy: a bare view:, dimension: or measure:, and anything that only parses as a continuation of the model\'s last statement, is refused with a 400, because the check reads the submitted text by itself. Wrap a view body in a top-level query:, or a field in a throwaway source: check is <source> extend { … }. Compiling at \"append\" also requires the model named in the URL to load: a model that does not compile is a 400 carrying that model\'s own problems, and a model that does not exist is a 400 that deliberately says only that it could not be loaded. An invalid scope value is rejected with a 400 naming the valid set. \"append\" text that carries a model-level `## artifact` tag is a document, which other viewers run, and is also refused with a 400 for `# image`, `# link`, markup in a `# label`, `@env.` in an annotation, an annotation the tag parser rejects or that exceeds 8,192 characters, `except:` or `rename:` followed by a declaration of the same name in the same extend chain, and more than 1,000 annotations or 64 KB of them. Plain \"append\" text without that tag keeps those tags; a model file defines them itself, and its edit is checked at \"file\".
|
|
550
|
+
* What the source means, and how far the check reaches. \"append\" (default) appends the source to the model in the URL and compiles it in that namespace — right for NEW definitions; an edit to an existing definition collides (\"Cannot redefine\"), and diagnostic positions land in the concatenated virtual file. \"file\" compiles the source AS that model, replacing its on-disk content for the check — validates an edit before saving, at true file coordinates. \"package\" runs the same worker compiler and file selection as reload over every .malloy and .malloynb file, without swapping the result into the served package; with a source, importers compile against the replacement. It also reports the render-tag findings (code \"render-tag\", or \"render-tag-check-failed\" for a model whose check did not finish), the dashboard, given and drill findings (code \"dashboard-lint\") and each .malloynb code cell the query route would refuse (code \"malloynb-cell-refused\", at most 10 per notebook and 50 per package, with the rest named in \"malloynb-cells-unlisted\" summaries, one per notebook that lists some and one for the notebooks past the package limit, and \"malloynb-cell-check-failed\" for a notebook that could not be checked) a reload would put on the package\'s warnings, at their own severity and with no position, and the load\'s verdict on the materialization annotations: each line a load fails with as an error with its code, each annotation the load leaves unbuilt as a warning (\"file\" reports the same verdict when the file names a materialization route or the package plans a table). The package\'s other warnings (storage, bound tables, explores, surface and discovery warnings, among others) are not reported. Package diagnostics can name files hidden from discovery. No rows or SQL are returned, and caller-provided source remains subject to authorize gates. includeSql is not available at \"package\". \"append\" text is checked against the model\'s PUBLISHED surface, so it may not declare its own data roots: import, connection.table(…), connection.sql(…), given:, ##! compiler flags and the raw-SQL function forms (name!type(…), sql_number, sql_string and the rest of that family) are refused with a 400. Those belong in a model file, so validate text declaring them at \"file\" or \"package\", which are not restricted. \"append\" text must also stand alone as top-level Malloy: a bare view:, dimension: or measure:, and anything that only parses as a continuation of the model\'s last statement, is refused with a 400, because the check reads the submitted text by itself. Wrap a view body in a top-level query:, or a field in a throwaway source: check is <source> extend { … }. Compiling at \"append\" also requires the model named in the URL to load: a model that does not compile is a 400 carrying that model\'s own problems, and a model that does not exist is a 400 that deliberately says only that it could not be loaded. An invalid scope value is rejected with a 400 naming the valid set. \"append\" text that carries a model-level `## artifact` tag is a document, which other viewers run, and is also refused with a 400 for `# image`, `# link`, markup in a `# label`, `@env.` in an annotation, an annotation the tag parser rejects or that exceeds 8,192 characters, `except:` or `rename:` followed by a declaration of the same name in the same extend chain, and more than 1,000 annotations or 64 KB of them. Plain \"append\" text without that tag keeps those tags; a model file defines them itself, and its edit is checked at \"file\".
|
|
539
551
|
*/
|
|
540
552
|
'scope'?: CompileRequestScopeEnum;
|
|
541
553
|
/**
|
|
@@ -576,6 +588,10 @@ export interface CompileResult {
|
|
|
576
588
|
*/
|
|
577
589
|
'sql'?: string;
|
|
578
590
|
'document'?: CompiledDocument;
|
|
591
|
+
/**
|
|
592
|
+
* Scope `package` only, when the package materializes anything: each materialized item of the package as the dry run plans it. Its `serves` is `not_judged`, since a compile binds nothing; `built` and `failed` read the tables the served package has bound and its last build\'s failures at the same address. Reload to judge serving.
|
|
593
|
+
*/
|
|
594
|
+
'materializationSummary'?: MaterializationSummary;
|
|
579
595
|
}
|
|
580
596
|
export declare const CompileResultStatusEnum: {
|
|
581
597
|
readonly Success: "success";
|
|
@@ -803,6 +819,14 @@ export interface ContractColumn {
|
|
|
803
819
|
* What a stored read of this column may answer in place of live: `exact` (equality, grouping, filters and ordering all match live), `equality` (equality, grouping, equality filters and joins match; ordering and ranges may not), or `none` (no string comparison is known to match). Every non-string column is `exact`. An open set: read an unknown value as `none`.
|
|
804
820
|
*/
|
|
805
821
|
'compare'?: string;
|
|
822
|
+
/**
|
|
823
|
+
* A string column of a `storage=` table: how its `compare` was obtained. `read`: the verdict a rebuild records again unchanged, because the catalog answered it, or because nothing a read returns can change it: a `COLLATE` in the build\'s SQL, a dialect whose collations Publisher does not read, a stored collation that is not binary, a Postgres or DuckDB read that failed in a way every retry fails too (a rejected credential, the warehouse\'s own error for a statement wrong in itself, a Postgres missing privilege), and, on BigQuery, a project that holds a collated dataset, a table no read can place, or the project-wide read of that project refused for want of a permission (an error whose reason is `accessDenied`, as a dataset-scoped account gets) for an `.sql()` source, a view, or more datasets than are read one by one. `unread`: the fail-closed `none` recorded because a catalog read failed in a way a rebuild may not repeat: a Postgres or DuckDB read that failed transiently or for an unrecognized reason, or a BigQuery read that failed (including a 403 for a rate limit or a quota, and an \"Access Denied\" that names no reason), did not list a table, or was refused one dataset\'s catalog. A downstream that compares such a string fails with `upstream_contract_unread`, naming this table to rebuild, rather than being refused. A table built over stored tables takes `unread` only when every `none` it inherits is unread. Absent on a contract written before it was recorded (see `ColumnContract.producer`) and on a non-string column; a reader treats an unknown value as absent.
|
|
824
|
+
*/
|
|
825
|
+
'compareFrom'?: ContractColumnCompareFromEnum;
|
|
826
|
+
/**
|
|
827
|
+
* With `compareFrom: unread` on a table built over stored tables: the upstreams (`sourceEntityId`) whose unread verdicts it inherited, and the tables theirs came from, which are rebuilt before it can read otherwise.
|
|
828
|
+
*/
|
|
829
|
+
'unreadUpstreams'?: Array<string>;
|
|
806
830
|
/**
|
|
807
831
|
* Whether a row-level gate comparing this column reads the same rows from the stored table as live (a binary64 double read from a binary64 source, never a DECIMAL or float4 stored as a double, nor a 128-bit integer).
|
|
808
832
|
*/
|
|
@@ -812,6 +836,11 @@ export interface ContractColumn {
|
|
|
812
836
|
*/
|
|
813
837
|
'declaredType'?: string;
|
|
814
838
|
}
|
|
839
|
+
export declare const ContractColumnCompareFromEnum: {
|
|
840
|
+
readonly Read: "read";
|
|
841
|
+
readonly Unread: "unread";
|
|
842
|
+
};
|
|
843
|
+
export type ContractColumnCompareFromEnum = typeof ContractColumnCompareFromEnum[keyof typeof ContractColumnCompareFromEnum];
|
|
815
844
|
export interface CreateConnection201Response {
|
|
816
845
|
'message'?: string;
|
|
817
846
|
}
|
|
@@ -1776,6 +1805,167 @@ export interface Materialization {
|
|
|
1776
1805
|
'createdAt'?: string;
|
|
1777
1806
|
'updatedAt'?: string;
|
|
1778
1807
|
}
|
|
1808
|
+
/**
|
|
1809
|
+
* A package\'s `MaterializationSummary` cut down for a poll: counts of every item by state, and the items that are not `built`, or are built and answered live, each with its reason code. An item off the package\'s published surface is counted in `hiddenNotServed` rather than named. Built from the same function as the summary.
|
|
1810
|
+
*/
|
|
1811
|
+
export interface MaterializationDigest {
|
|
1812
|
+
'mode': MaterializationMode;
|
|
1813
|
+
'counts': MaterializationStateCounts;
|
|
1814
|
+
/**
|
|
1815
|
+
* Items not answered from a table that `notServed` leaves out because they are not on the package\'s published surface: no `index.malloy` export names their source (a view\'s source, a rollup\'s base, a named query) as declared in their file, so a hidden source sharing an exported source\'s name elsewhere is counted here. Counted, never named, since `/status` is unauthenticated. A package that curates nothing, or declares `queryableSources: \"all\"`, makes every source queryable by name, so every item is named and this is 0.
|
|
1816
|
+
*/
|
|
1817
|
+
'hiddenNotServed': number;
|
|
1818
|
+
'notServed': Array<MaterializationDigestNotServedInner>;
|
|
1819
|
+
}
|
|
1820
|
+
export interface MaterializationDigestNotServedInner {
|
|
1821
|
+
'name': string;
|
|
1822
|
+
'kind': MaterializationDigestNotServedInnerKindEnum;
|
|
1823
|
+
'sourceID': string;
|
|
1824
|
+
'modelPath'?: string;
|
|
1825
|
+
'tier'?: MaterializationDigestNotServedInnerTierEnum;
|
|
1826
|
+
'state': MaterializationDigestNotServedInnerStateEnum;
|
|
1827
|
+
'serves': MaterializationDigestNotServedInnerServesEnum;
|
|
1828
|
+
/**
|
|
1829
|
+
* As `MaterializationItem.reason`; absent for an item simply awaiting its build.
|
|
1830
|
+
*/
|
|
1831
|
+
'reason'?: string;
|
|
1832
|
+
}
|
|
1833
|
+
export declare const MaterializationDigestNotServedInnerKindEnum: {
|
|
1834
|
+
readonly Persist: "persist";
|
|
1835
|
+
readonly Materialize: "materialize";
|
|
1836
|
+
readonly View: "view";
|
|
1837
|
+
readonly Query: "query";
|
|
1838
|
+
readonly Rollup: "rollup";
|
|
1839
|
+
};
|
|
1840
|
+
export type MaterializationDigestNotServedInnerKindEnum = typeof MaterializationDigestNotServedInnerKindEnum[keyof typeof MaterializationDigestNotServedInnerKindEnum];
|
|
1841
|
+
export declare const MaterializationDigestNotServedInnerTierEnum: {
|
|
1842
|
+
readonly Database: "database";
|
|
1843
|
+
readonly Storage: "storage";
|
|
1844
|
+
};
|
|
1845
|
+
export type MaterializationDigestNotServedInnerTierEnum = typeof MaterializationDigestNotServedInnerTierEnum[keyof typeof MaterializationDigestNotServedInnerTierEnum];
|
|
1846
|
+
export declare const MaterializationDigestNotServedInnerStateEnum: {
|
|
1847
|
+
readonly Built: "built";
|
|
1848
|
+
readonly AwaitingBuild: "awaiting_build";
|
|
1849
|
+
readonly NotBuildable: "not_buildable";
|
|
1850
|
+
readonly Refused: "refused";
|
|
1851
|
+
readonly Failed: "failed";
|
|
1852
|
+
};
|
|
1853
|
+
export type MaterializationDigestNotServedInnerStateEnum = typeof MaterializationDigestNotServedInnerStateEnum[keyof typeof MaterializationDigestNotServedInnerStateEnum];
|
|
1854
|
+
export declare const MaterializationDigestNotServedInnerServesEnum: {
|
|
1855
|
+
readonly Serves: "serves";
|
|
1856
|
+
readonly AfterBuild: "after_build";
|
|
1857
|
+
readonly Live: "live";
|
|
1858
|
+
readonly NotJudged: "not_judged";
|
|
1859
|
+
};
|
|
1860
|
+
export type MaterializationDigestNotServedInnerServesEnum = typeof MaterializationDigestNotServedInnerServesEnum[keyof typeof MaterializationDigestNotServedInnerServesEnum];
|
|
1861
|
+
/**
|
|
1862
|
+
* One fact about an item\'s table, and how it is known. `basis` is `exact` for a fact read off a table that exists; `predicted` and `not_knowable_locally` are reserved for facts a later release predicts without building.
|
|
1863
|
+
*/
|
|
1864
|
+
export interface MaterializationFact {
|
|
1865
|
+
/**
|
|
1866
|
+
* Which fact: `table` (the physical table a query reads, present once built) or `builtAt` (when that table was built). An open string: a client must skip a fact it does not know.
|
|
1867
|
+
*/
|
|
1868
|
+
'fact': string;
|
|
1869
|
+
'value': string;
|
|
1870
|
+
'basis': MaterializationFactBasisEnum;
|
|
1871
|
+
}
|
|
1872
|
+
export declare const MaterializationFactBasisEnum: {
|
|
1873
|
+
readonly Exact: "exact";
|
|
1874
|
+
readonly Predicted: "predicted";
|
|
1875
|
+
readonly NotKnowableLocally: "not_knowable_locally";
|
|
1876
|
+
};
|
|
1877
|
+
export type MaterializationFactBasisEnum = typeof MaterializationFactBasisEnum[keyof typeof MaterializationFactBasisEnum];
|
|
1878
|
+
/**
|
|
1879
|
+
* One thing a package materializes (a `#(materialize)` or `#@ persist` source, a `#@ persist` view or named query, or a `#(rollup)`), and its fate: the one row the build plan\'s refusals, the last build\'s failures and the serve verdicts are joined into.
|
|
1880
|
+
*/
|
|
1881
|
+
export interface MaterializationItem {
|
|
1882
|
+
/**
|
|
1883
|
+
* The declared name: the source\'s, the view\'s (on `source`), or the named query\'s. A rollup has no declared name, so this is the name the plan generated for it, and `source` and `grain` say what it rolls up.
|
|
1884
|
+
*/
|
|
1885
|
+
'name': string;
|
|
1886
|
+
/**
|
|
1887
|
+
* The annotation that declared it.
|
|
1888
|
+
*/
|
|
1889
|
+
'kind': MaterializationItemKindEnum;
|
|
1890
|
+
/**
|
|
1891
|
+
* A view\'s source, or a rollup\'s base source.
|
|
1892
|
+
*/
|
|
1893
|
+
'source'?: string;
|
|
1894
|
+
/**
|
|
1895
|
+
* A rollup\'s grain dimensions.
|
|
1896
|
+
*/
|
|
1897
|
+
'grain'?: Array<string>;
|
|
1898
|
+
/**
|
|
1899
|
+
* `sourceName@modelPath`, package-relative: the `BuildPlan.sources` key with its file URL read relative to the package, so it names no place the server keeps files.
|
|
1900
|
+
*/
|
|
1901
|
+
'sourceID': string;
|
|
1902
|
+
/**
|
|
1903
|
+
* The package-relative model that declares it.
|
|
1904
|
+
*/
|
|
1905
|
+
'modelPath'?: string;
|
|
1906
|
+
/**
|
|
1907
|
+
* Where its table lives: the source\'s own connection (`database`), or a storage destination (`storage`).
|
|
1908
|
+
*/
|
|
1909
|
+
'tier': MaterializationItemTierEnum;
|
|
1910
|
+
/**
|
|
1911
|
+
* The storage destination\'s name on the storage tier, else the connection the table is built on. Absent when not known (a refused `storage=` item the plan never placed).
|
|
1912
|
+
*/
|
|
1913
|
+
'destination'?: string;
|
|
1914
|
+
'mode': MaterializationMode;
|
|
1915
|
+
/**
|
|
1916
|
+
* `built`: a table for it is bound. `awaiting_build`: it is valid and planned, no table is bound yet, and a build would make one. `not_buildable`: it is planned, but a build skips it here for `reason` (`destination_missing`, `connection_cannot_hold_table`, `materialization_off` or `upstream_unread`), so it is answered live until that changes. `refused`: it is valid and the plan or the bind does not build or serve it here, for `reason`. `failed`: this server\'s last build of it failed, for `reason` (an older table may still be bound and serving; `serves` says). Known only for builds this server ran since the package last loaded; a host\'s manifest that binds a table at its address clears it.
|
|
1917
|
+
*/
|
|
1918
|
+
'state': MaterializationItemStateEnum;
|
|
1919
|
+
/**
|
|
1920
|
+
* How queries on it are answered right now. `serves`: from its bound table. `after_build`: nothing is bound yet; they are answered live now and from its table once a build binds one. `live`: answered live, for `reason`, and a build alone does not change that (a failed item with nothing bound is `live`). `not_judged`: no serve verdict was computed: a refused item, or a draft a compile planned without binding.
|
|
1921
|
+
*/
|
|
1922
|
+
'serves': MaterializationItemServesEnum;
|
|
1923
|
+
/**
|
|
1924
|
+
* What a query names to be answered from this table, as far as is known without compiling queries: the source (or a rollup\'s base), `source -> view` for a persisted view, or the named query.
|
|
1925
|
+
*/
|
|
1926
|
+
'queries'?: Array<string>;
|
|
1927
|
+
/**
|
|
1928
|
+
* Why it is not built, failed, or is answered live: a `RefusedSource.reason` for a refused item, `build_failed` for a failed one, else the `ServeVerdict.reason`. An open string.
|
|
1929
|
+
*/
|
|
1930
|
+
'reason'?: string;
|
|
1931
|
+
/**
|
|
1932
|
+
* What the state and verdict mean for it, in a sentence or two.
|
|
1933
|
+
*/
|
|
1934
|
+
'message'?: string;
|
|
1935
|
+
/**
|
|
1936
|
+
* The changes that would let it build or serve, from the verdict.
|
|
1937
|
+
*/
|
|
1938
|
+
'fixes'?: Array<string>;
|
|
1939
|
+
'facts'?: Array<MaterializationFact>;
|
|
1940
|
+
}
|
|
1941
|
+
export declare const MaterializationItemKindEnum: {
|
|
1942
|
+
readonly Persist: "persist";
|
|
1943
|
+
readonly Materialize: "materialize";
|
|
1944
|
+
readonly View: "view";
|
|
1945
|
+
readonly Query: "query";
|
|
1946
|
+
readonly Rollup: "rollup";
|
|
1947
|
+
};
|
|
1948
|
+
export type MaterializationItemKindEnum = typeof MaterializationItemKindEnum[keyof typeof MaterializationItemKindEnum];
|
|
1949
|
+
export declare const MaterializationItemTierEnum: {
|
|
1950
|
+
readonly Database: "database";
|
|
1951
|
+
readonly Storage: "storage";
|
|
1952
|
+
};
|
|
1953
|
+
export type MaterializationItemTierEnum = typeof MaterializationItemTierEnum[keyof typeof MaterializationItemTierEnum];
|
|
1954
|
+
export declare const MaterializationItemStateEnum: {
|
|
1955
|
+
readonly Built: "built";
|
|
1956
|
+
readonly AwaitingBuild: "awaiting_build";
|
|
1957
|
+
readonly NotBuildable: "not_buildable";
|
|
1958
|
+
readonly Refused: "refused";
|
|
1959
|
+
readonly Failed: "failed";
|
|
1960
|
+
};
|
|
1961
|
+
export type MaterializationItemStateEnum = typeof MaterializationItemStateEnum[keyof typeof MaterializationItemStateEnum];
|
|
1962
|
+
export declare const MaterializationItemServesEnum: {
|
|
1963
|
+
readonly Serves: "serves";
|
|
1964
|
+
readonly AfterBuild: "after_build";
|
|
1965
|
+
readonly Live: "live";
|
|
1966
|
+
readonly NotJudged: "not_judged";
|
|
1967
|
+
};
|
|
1968
|
+
export type MaterializationItemServesEnum = typeof MaterializationItemServesEnum[keyof typeof MaterializationItemServesEnum];
|
|
1779
1969
|
/**
|
|
1780
1970
|
* Materialization metadata including build options, source counts, and durations. Free-form object — fields such as `trigger` (`on_demand` | `scheduler`, the words `RunContext.trigger` uses; releases before this one wrote `ON_DEMAND` | `SCHEDULER`, which a reader of older runs must still accept) live here deliberately, so a strict-schema client does not need to know them. Promoting any such field to a top-level `Materialization` property is a breaking schema change that orchestrated clients must adopt first; do not do it casually. `errorRetryable` (boolean) is set on a FAILED run that built nothing, the whole run\'s answer beside each source\'s own in `manifest.failures`: `false` when every source failed deterministically or was refused, `true` when any failure was transient, with the same rules as `SourceFailure.retryable`. Absent when unclassified, for a cancelled run, and from a Publisher that predates it. `errorAtCancel` (string) is set on a CANCELLED run whose last error was not the cancellation itself: the message of the failure the cancel raced, which `error` reports only as \"Cancelled\". `keptTables` (array) is set on an auto-run that lists the tables a rename or move left and Publisher keeps rather than drops (see the `table-kept` warning).
|
|
1781
1971
|
*/
|
|
@@ -1818,6 +2008,26 @@ export declare const MaterializationMetadataKeptTablesInnerReasonEnum: {
|
|
|
1818
2008
|
readonly MayBeServed: "may_be_served";
|
|
1819
2009
|
};
|
|
1820
2010
|
export type MaterializationMetadataKeptTablesInnerReasonEnum = typeof MaterializationMetadataKeptTablesInnerReasonEnum[keyof typeof MaterializationMetadataKeptTablesInnerReasonEnum];
|
|
2011
|
+
/**
|
|
2012
|
+
* How a package\'s tables came to be, so a reader never mistakes one kind for another. `local`: an unversioned package (a watched one, or one installed in place) whose tables this server builds itself. `published`: a published version, or a package whose tables a host\'s manifest bound. `simulated`: a package simulated materialization serves, its tables predicted and never built; not produced yet. `draft` is reserved for a later release. A client must accept a value it does not know.
|
|
2013
|
+
*/
|
|
2014
|
+
export declare const MaterializationMode: {
|
|
2015
|
+
readonly Simulated: "simulated";
|
|
2016
|
+
readonly Local: "local";
|
|
2017
|
+
readonly Draft: "draft";
|
|
2018
|
+
readonly Published: "published";
|
|
2019
|
+
};
|
|
2020
|
+
export type MaterializationMode = typeof MaterializationMode[keyof typeof MaterializationMode];
|
|
2021
|
+
/**
|
|
2022
|
+
* How many items are in each `MaterializationItem.state`.
|
|
2023
|
+
*/
|
|
2024
|
+
export interface MaterializationStateCounts {
|
|
2025
|
+
'built': number;
|
|
2026
|
+
'awaiting_build': number;
|
|
2027
|
+
'not_buildable': number;
|
|
2028
|
+
'refused': number;
|
|
2029
|
+
'failed': number;
|
|
2030
|
+
}
|
|
1821
2031
|
/**
|
|
1822
2032
|
* Phase-aware status of a materialization run. `MANIFEST_ROWS_READY`: the tables are built and the manifest is recorded. `MANIFEST_FILE_READY`: the run is done; an auto-run reaches it only after its manifest is loaded into the package it built, so a query sent after it is answered from the new tables (`metadata.autoLoad` is `loaded`). When that load does not take, the run still reaches `MANIFEST_FILE_READY`, since its tables were built, with `metadata.autoLoad` `failed`, `metadata.autoLoadStep` (`reload`, `bind` or `timeout`), `metadata.autoLoadError`, and `error` set; the package\'s next reload or restart binds the run\'s manifest. An orchestrated run never loads its manifest, so for it `MANIFEST_FILE_READY` means built.
|
|
1823
2033
|
*/
|
|
@@ -1829,6 +2039,25 @@ export declare const MaterializationStatus: {
|
|
|
1829
2039
|
readonly Cancelled: "CANCELLED";
|
|
1830
2040
|
};
|
|
1831
2041
|
export type MaterializationStatus = typeof MaterializationStatus[keyof typeof MaterializationStatus];
|
|
2042
|
+
/**
|
|
2043
|
+
* One row per thing a package materializes, with counts by state. Read off the build plan, the bound tables and the serve verdicts as they stand; absent when the package materializes nothing.
|
|
2044
|
+
*/
|
|
2045
|
+
export interface MaterializationSummary {
|
|
2046
|
+
'mode': MaterializationMode;
|
|
2047
|
+
'counts': MaterializationStateCounts;
|
|
2048
|
+
'items': Array<MaterializationItem>;
|
|
2049
|
+
}
|
|
2050
|
+
/**
|
|
2051
|
+
* How a connection metadata answer was read: `catalog`, from the warehouse\'s catalog or metadata tables; `counted`, by an aggregate `count(*)` over the table; `sampled`, from a sample; `history`, from query history; `host`, relayed from the remote connection a `publisher` proxy names, which read it with its own credentials.
|
|
2052
|
+
*/
|
|
2053
|
+
export declare const MetadataMethod: {
|
|
2054
|
+
readonly Catalog: "catalog";
|
|
2055
|
+
readonly Counted: "counted";
|
|
2056
|
+
readonly Sampled: "sampled";
|
|
2057
|
+
readonly History: "history";
|
|
2058
|
+
readonly Host: "host";
|
|
2059
|
+
};
|
|
2060
|
+
export type MetadataMethod = typeof MetadataMethod[keyof typeof MetadataMethod];
|
|
1832
2061
|
/**
|
|
1833
2062
|
* Malloy model metadata and status information
|
|
1834
2063
|
*/
|
|
@@ -1913,7 +2142,11 @@ export interface ModelError {
|
|
|
1913
2142
|
*/
|
|
1914
2143
|
'refusalReason'?: string;
|
|
1915
2144
|
/**
|
|
1916
|
-
*
|
|
2145
|
+
* With `reason: INDEX_SOURCE_UNBUILT`: why the queried source\'s stored table is not ready. `unbuilt` (none is built yet, or none is bound to the version that answered), `building` (a build of it is in progress), `failed` (its last build failed) or `refused` (the package\'s build plan refuses to build it; `refusedSources` says why). An open set: read an absent or unrecognized value as `unbuilt`. Absent otherwise.
|
|
2146
|
+
*/
|
|
2147
|
+
'unbuiltReason'?: string;
|
|
2148
|
+
/**
|
|
2149
|
+
* Machine-readable discriminator, for callers that must branch on which error they got rather than on prose. Absent unless a caller is expected to act on it, so treat absence as \"no special handling\". TABLE_NOT_FOUND distinguishes a table that is not in the database from the other conditions that also answer 404 on these routes -- an environment or connection this server does not host. The former says nothing about whether the caller reached the right server; the latter is a routing problem worth retrying elsewhere. CONNECTION_FAILED, on a 502, means the database could not be reached (the connection was refused, reset or timed out, or the server closed it), so the query never ran. The query and the model are fine; retrying elsewhere will not help, and neither will rewriting the query. RESULT_TRUNCATED, on a 502, means the database returned fewer rows than it reported and no row limit cut them: a BigQuery answer larger than one results page (about 10 MB) whose later pages were not read. The query is refused rather than answered short. Retrying returns the same page; select fewer columns, aggregate, or return fewer rows. RESULT_SHAPE_MISMATCH, on a 502, means the database answered but a row does not fit the schema Malloy declared for the result (a value of another type than its column\'s), so the result could not be built. The query is not the caller\'s to fix; the server logs the cause. CONNECTION_AUTH_FAILED, on a 424, means the database rejected the connection\'s credentials (a wrong password, an invalid key, an expired token), so the query never ran. Whoever configures the connection has to fix it; retrying fails the same way. CONNECTION_NOT_FOUND, on a 424, means the model names a connection the environment does not have, usually one deleted after the package was loaded. STORAGE_ACCESS_DENIED, on a 403, means an object store refused the database\'s read under a data path the environment configures (a DuckLake catalog\'s, a storage destination\'s): the query and the model are fine, and whoever configures the database\'s storage credentials has to fix it. PATH_ACCESS_DENIED, on a 403, means the object store at a path the query or the model reads itself (a file or table URL) refused access: change the path, or get the caller a grant to it. Retrying either fails the same way. The body names the source or connection the caller read and no storage path. ACCESS_DENIED, on a 403, means a gate (`#(authorize)` or `#(access_filter)`) refused the caller. Every gate refusal carries it, including a gate that could not be decided, which fails closed and answers the same: only the server\'s metrics and log tell those apart. The one 403 an `#(access_filter)` answers with another reason is INHERITED_FILTER_UNVERIFIED, below, when the model\'s own text moved a field the filter reads: that is no refusal of the caller. A 403 with any other reason is not a gate\'s. INHERITED_FILTER_UNVERIFIED, on a 403, means a `where:` the queried source inherits from a source it is built from could not be verified to read the fields it was written against there: a field it reads is defined again on the way (`rename:`, `except:`, a new definition), or the check could not follow it. It also answers an inherited `#(access_filter)` whose condition the model\'s own text moved (`rename:`, `except:`, a new definition) once the caller has supplied every given it reads; a caller missing one gets ACCESS_DENIED, and so does a rebind written in the caller\'s own query. It is the model\'s own text, not a permission rule, so givens and a rewritten query do not help. The message names the source and the reason class (`redefined_field`, `unrecorded_join`, `unresolved_declaration`, `resolution_bound`, or `check_failed` when the check itself failed unexpectedly), never the filter or the file; the server log names both. INDEX_SOURCE_UNBUILT, on a 409 from a model query, means a query with `queryClass: index` was refused because the source it queries declares a stored table of its own (`#(materialize)`, or its own `#@ persist`, not one it only inherits) and no ready table of it is bound. An index query on such a source is answered from that table or not at all, never run live against the warehouse; it is deferred, not wrong, and the same query succeeds once the table is built. The body\'s `unbuiltReason` says why the table is not ready. Only `queryClass: index` is refused this way: the same query in any other class is answered as before. Every governance check (the package\'s published surface, `#(authorize)`, row-level gates) decides first, so a caller who may not query the source gets that 404 or 403 instead, never this. The message names the source as the caller queried it, never a table, a path or a connection. MATERIALIZATION_REFUSED means a valid materialization declaration this server will not build, and the body\'s `refusalReason` is the refusal\'s `RefusedSource.reason`. Reserved: no route answers with it today. The eligibility gate runs inside a materialization run, after `POST …/materializations` has answered 201, so a refusal is recorded on the run instead: as a `SourceFailure` with `refused` and `refusalReason` on a run with `buildInstructions`, otherwise in the run\'s `metadata.refusedSources`, or its `error` when nothing else was left to build. `failures` holds one outcome per address, so on a run with `buildInstructions` a refused source whose address holds another outcome (a table an eligible source built, another source\'s build failure, or another source\'s refusal) is in `metadata.refusedSources` instead, with its own reason, on a FAILED run too. TABLE_OWNED_ELSEWHERE and TABLE_OWNERSHIP_UNVERIFIED, on a 400, mean a build was refused before it wrote because its `name=` is held by a table this package does not own, or because who holds it could not be read. On a 409 from dropping a materialized table (`drop-materialized-table`), they mean the drop was refused for the same reasons: the table is another\'s, or nothing proves it is this package\'s. TABLE_IN_USE, on a 409 from dropping a materialized table, means the table may still be read: a committed run of the package, of any version, names a table with that name (other than the run the caller named, unless that run is the one a version or the package serves); a loaded copy of any package in the environment, or any loaded version of one, is bound to a table with that name; or the warehouse refused the drop because other objects depend on the table. Delete or replace that run, rebind that copy, or drop those objects first. BUILD_INSTRUCTIONS_INVALID, on a 400 from creating a materialization, means its body or build instructions are not a run this package can take (a field of the wrong shape, an unknown source, a table named twice, a ledger entry that does not fit); the message names which. Retrying unchanged fails the same way. MATERIALIZATION_CONFLICT, on a 409, means a materialization run conflicts with another run or with the package\'s binding. Two of its cases clear on their own, so retry later: a run already active for the package, and a table another run is writing. Two do not clear until something changes, so a retry fails the same way: an auto-run of a package or version a host manifest serves (pass `buildInstructions`, or clear the binding), and a run of a version that is not latest touching the tables a `scope: package` package\'s versions share (name tables of its own in `buildInstructions`). The message says which. MANIFEST_BIND_FAILED, on a 500 from `set-package-version-manifest` or the deprecated `update-package` PATCH that names a `manifestLocation` (on a versioned or an unversioned package), means the manifest could not be fetched or bound, so nothing of it was applied: the `manifestLocation` stays what it was (an unversioned package\'s whole PATCH is undone, publisher.json included), and the package or version serves what it served before. The message carries the cause. SIMULATION_ACTIVE, on a 409, means the server runs simulated materialization (`PUBLISHER_MATERIALIZE_SIMULATE`), an authoring mode that makes no materialization write. It refuses a materialization create, stop or delete, a materialized table drop, a storage destination\'s table drop and file cleanup, a version delete or archive, the delete of an environment or of a package that has versions, run records or incremental-ledger rows, a publish of a version whose id a deleted version left run records under, a watch-mode change, and a manifest binding (`update-package` or `create-package` with a `manifestLocation`, `set-package-version-manifest`). It fails the same way until the server restarts without simulation. MANIFEST_NOT_FOUND, on a 400 from the same routes, means nothing is at the `manifestLocation` (no such file, object or bucket), and MANIFEST_INVALID, on a 422, that what is there does not parse or is not a build manifest. Both are the caller\'s input: nothing of the manifest was applied, as with MANIFEST_BIND_FAILED, and sending it unchanged fails the same way. Deliberately an open string rather than an enum. Generators render an enum closed, so adding a second value here would break every client generated before it -- on the one field whose purpose is to grow. Callers must treat an unrecognized value as absent. The package-version values let a caller tell \"forgot to bump the version\" from \"the model is broken\", which share a status code: * MANIFEST_VERSION_MISSING (400): with package versioning on, a publish whose publisher.json has no `version`. * MANIFEST_VERSION_INVALID (400): such a publish whose `version` is not a semantic version. * VERSION_CONFLICT (409): that version is already published with different content. * PACKAGE_IS_VERSIONED (409): the package has published versions, so it cannot be changed in place (a write, or a publish with package versioning off). * PACKAGE_INSTALLED_FROM_LOCATION (409): the package is fetched again from a `location` on reload, which would discard a report write or a package update\'s change to its settings. * FILE_EXISTS (409): a report write with no `expectedHash` (a create) found a file already at the path; another path may be free. A stale `expectedHash` answers 409 with no `reason`. * VERSION_IS_LATEST (409): the package\'s `latest` version cannot be archived, or deleted while other versions remain. * VERSION_IS_LAST_ACTIVE (409): the package\'s last version in service cannot be archived, or deleted while archived versions remain. * VERSION_BUILDING (409): a materialization of the version is running, so it cannot be archived or deleted yet. * VERSION_ID_INVALID (400): a requested `versionId` is not a semantic version. * VERSION_NOT_LATEST (400): an auto-run of a version other than `latest`, in a package whose versions share their tables. A package with no `latest` yet refuses none. * VERSION_NOT_FOUND (404): the package has no such version. * VERSION_ARCHIVED (410): the version is archived. Known values: TABLE_NOT_FOUND, CONNECTION_FAILED, CONNECTION_AUTH_FAILED, CONNECTION_NOT_FOUND, RESULT_TRUNCATED, RESULT_SHAPE_MISMATCH, STORAGE_ACCESS_DENIED, PATH_ACCESS_DENIED, ACCESS_DENIED, INHERITED_FILTER_UNVERIFIED, INDEX_SOURCE_UNBUILT, MATERIALIZATION_REFUSED, TABLE_OWNED_ELSEWHERE, TABLE_OWNERSHIP_UNVERIFIED, TABLE_IN_USE, BUILD_INSTRUCTIONS_INVALID, MATERIALIZATION_CONFLICT, MANIFEST_VERSION_MISSING, MANIFEST_VERSION_INVALID, VERSION_CONFLICT, PACKAGE_IS_VERSIONED, PACKAGE_INSTALLED_FROM_LOCATION, FILE_EXISTS, VERSION_IS_LATEST, VERSION_IS_LAST_ACTIVE, VERSION_BUILDING, VERSION_ID_INVALID, VERSION_NOT_LATEST, VERSION_NOT_FOUND, VERSION_ARCHIVED, SIMULATION_ACTIVE.
|
|
1917
2150
|
*/
|
|
1918
2151
|
'reason'?: string;
|
|
1919
2152
|
/**
|
|
@@ -2002,7 +2235,7 @@ export interface NotServedIn {
|
|
|
2002
2235
|
*/
|
|
2003
2236
|
'model': string;
|
|
2004
2237
|
/**
|
|
2005
|
-
* Every reason the served copy gives for not reading the source\'s table in this model: the `reason` of each `served-copy-not-served` package warning on that model that names the source or the model\'s whole copy, the codes `publisher_served_copy_bind_total` counts, most actionable first (for example `cross_connection_join` before `fields_not_carried`): `cross_connection_join`, `cross_connection_unbuilt`, `inline_join_kept`, `read_terms_not_kept`, `fields_not_carried`, `column_types`, `classification_not_kept`, `pair_join_not_found`, `pair_not_compiled`, `definition_not_parsed`, `compile_failed`, `no_declaration`, `reroot_not_compiled`. `not_rerooted` alone when no warning names one (also `servePathReason`\'s value for that case). Never empty. An open set: treat an unknown value as `not_rerooted`.
|
|
2238
|
+
* Every reason the served copy gives for not reading the source\'s table in this model: the `reason` of each `served-copy-not-served` package warning on that model that names the source or the model\'s whole copy, the codes `publisher_served_copy_bind_total` counts, most actionable first (for example `cross_connection_join` before `fields_not_carried`): `cross_connection_join`, `cross_connection_unbuilt`, `sql_embed_cross_connection` (a `.sql()` source reads it through `%{}` on another connection than its table is read on: a storage destination, or a managed catalog read through one), `sql_embed_bare` (a `.sql()` source embeds it bare, `%{ x }`, which its stored table cannot be embedded as), `inline_join_kept`, `read_terms_not_kept`, `fields_not_carried`, `column_types`, `classification_not_kept`, `pair_join_not_found`, `pair_not_compiled`, `definition_not_parsed`, `compile_failed`, `no_declaration`, `reroot_not_compiled`. `not_rerooted` alone when no warning names one (also `servePathReason`\'s value for that case). Never empty. An open set: treat an unknown value as `not_rerooted`.
|
|
2006
2239
|
*/
|
|
2007
2240
|
'reasons': Array<string>;
|
|
2008
2241
|
}
|
|
@@ -2088,7 +2321,7 @@ export interface OmittedSource {
|
|
|
2088
2321
|
*/
|
|
2089
2322
|
'sourceID': string;
|
|
2090
2323
|
/**
|
|
2091
|
-
* Why the source was left out, as a code. An OPEN set: a client must accept a code it does not know (read it as a failure) rather than reject the plan. Today\'s codes: `unkeyable` (Malloy could not key the source\'s build: an unbound parameter or a given with no value); `eligibility_check_failed` (an eligibility gate failed with an error rather than a refusal); `projection_failed` (the plan entry could not otherwise be computed); `rollup_companion_failed` (the generated `#(rollup)` rollup companion, which also plans v1 `#@ preaggregate` rollups, did not plan or compile); `rollup_companion_blanking_failed` (that companion was not built because a `#@` line of the author\'s files could not be set aside); `materialize_companion_failed` (the generated `#(materialize)` companion did not plan or compile); `persisted_view_companion_failed` (the persisted-view companion did not plan or compile); `v1_build_companion_failed` (the build copy of a model file without `##! experimental.persistence` did not compile, so none of its `#@ persist` sources were planned); `persist_annotation_unparseable` is retained and no longer produced: a `#@` line that does not parse is an invalid annotation (`persist-unparseable`), which fails the publish and the load, so no served plan carries it.
|
|
2324
|
+
* Why the source was left out, as a code. An OPEN set: a client must accept a code it does not know (read it as a failure) rather than reject the plan. Today\'s codes: `unkeyable` (Malloy could not key the source\'s build: an unbound parameter or a given with no value); `eligibility_check_failed` (an eligibility gate failed with an error rather than a refusal); `projection_failed` (the plan entry could not otherwise be computed); `rollup_companion_failed` (the generated `#(rollup)` rollup companion, which also plans v1 `#@ preaggregate` rollups, did not plan or compile); `rollup_companion_blanking_failed` (that companion was not built because a `#@` line of the author\'s files could not be set aside); `materialize_companion_failed` (the generated `#(materialize)` companion did not plan or compile); `persisted_view_companion_failed` (the persisted-view companion did not plan or compile); `v1_build_companion_failed` (the build copy of a model file without `##! experimental.persistence` did not compile, so none of its `#@ persist` sources were planned); `persist_companion_failed` (planning a model file\'s `#@ persist` sources failed, so none of the ones it declares were planned; the file\'s other legs and the package\'s other files still plan); `persist_annotation_unparseable` is retained and no longer produced: a `#@` line that does not parse is an invalid annotation (`persist-unparseable`), which fails the publish and the load, so no served plan carries it.
|
|
2092
2325
|
*/
|
|
2093
2326
|
'reason': string;
|
|
2094
2327
|
}
|
|
@@ -2156,6 +2389,10 @@ export interface Package {
|
|
|
2156
2389
|
* Actionable messages for declared explores that do not resolve to a real model in this package (e.g. a misspelled path, or a notebook listed as an explore). Server-computed and read-only: it is ignored on create/update requests and only ever returned in responses. Present only when there are such problems. Loading is fail-safe — the unresolved entry simply lists nothing rather than exposing everything — so this is the signal that a package is misconfigured; publishing such a package is rejected.
|
|
2157
2390
|
*/
|
|
2158
2391
|
'exploresWarnings'?: Array<string>;
|
|
2392
|
+
/**
|
|
2393
|
+
* Set only on the response of a reload (`?reload=true`), when the package materializes anything: each materialized item, with its tier, destination, state, whether queries are answered from it, and why not. Ignored on create and update requests.
|
|
2394
|
+
*/
|
|
2395
|
+
'materializationSummary'?: MaterializationSummary;
|
|
2159
2396
|
/**
|
|
2160
2397
|
* Non-fatal findings collected when the package loaded, none of which stop the model compiling or the package loading. Render-tag findings: a render annotation (e.g. `# big_value`, `# currency` or `# colspan`) the renderer cannot apply as written, either malformed for the field it sits on, so it renders as \"[object Object]\" or an inline error at query time, or inert where it sits and silently ignored. Materialization findings: a `storage=` source not served from storage, a `#@ persist` source that was not recognized as materializable, a `#@ persist` REFUSED by the compile-time eligibility gate (one entry per `BuildPlan.refusedSources` member, carrying that gate\'s own message), a persist-target collision, and materialization-config problems that degrade attribution. A refusal is the one materialization finding the build plan cannot also be read for: a refused `storage`/`database` source is ABSENT from `BuildPlan.sources`, so nothing there records that the annotation was written at all. Discovery findings: a model on the package\'s surface whose export closure surfaces no sources or named queries, so it lists as empty and renders a blank page; a surface whose every model failed to compile, so every model in the package answers 404 by name; and, on the reload that caused it, a package that had a surface and now has none, so every source that surface hid is listed and queryable by name again. Manifest findings: each deprecated use of `explores` or of `queryableSources: \"declared\"`, and a root file such as `Index.malloy` that differs from `index.malloy` only in case and so is ignored. A root `index.malloy` with no manifest keys gets no warning. Report findings (one lint pass per report, of either layout, wherever it lives): a file whose artifact tag does not parse or does not describe a report, a tile or suggest query that does not resolve, a `# drill` naming a destination that is not a report, and a tile, single query or filter suggest that reads a source the surface does not export, so it won\'t load. A `# drill` destination is a path from the package root (a bare name is a file at the root); one that names no report is unresolved (`error`). Curation findings: a root `index.malloy` carrying an artifact tag, which is ignored (`index-is-not-a-report`, `error`); and a report that `index.malloy` imports or `explores` lists (`report-on-surface`, `warn`). Two report findings are about Publisher rather than about the package: one when a file carrying an artifact tag could not be read and so is not served at all, and one when the lint stops early, in which case the list must be read as incomplete rather than as a clean package. A linear report whose cells could not be read gets a finding that names the line and the fix and is reported with severity `error`, because it is served with that error instead of opening. The per-file report findings each name their line and the fix and carry a `code`; they are computed at discovery and are also returned by `/compile` at file and package scope. These codes are `error` and fail `/compile`: `notebook-markdown-opener-text` (more than a name after `(markdown)` on a block\'s opener), `notebook-markdown-attached-nowhere` (a `#(markdown)` annotation with no statement to take it), `notebook-artifact-unparsed` (an `## artifact` tag does not parse), and `notebook-cells-unreadable` (the reader could not read a linear report\'s cells), plus `report-kind-removed` (a tag that sets `kind=`, which is no longer read, so the file is not a report; the finding names the `layout=` to write), `report-cells-removed` (a linear tag that lists no `tiles`, the retired `run:` cell format, so the file is not a report; the fix is to list its tiles in `tiles=[…]`) and `report-layout-unknown` (a `layout=` other than `grid` or `linear`). The rest are `warn` (a mistyped `(markdown)` opener, a block that never closes, and similar). Skill and agent findings, all `warn`: a package skill under `skills/` that is not served (unreadable or linked-out `SKILL.md`, a frontmatter `name` that is not its directory name, a `skills/` directory that links out of the package) or served with a gap (no `description`, a `reference/` that cannot be listed or read); and each agent the manifest declares that is not served, or is served with a finding (an agent skill with no `description`, a skills directory with no skills, an unreadable reference). Deprecated-format findings, all `warn`: each `.malloynb` notebook (`model` is its path), and each source a file declares deprecated `#(filter)` annotations on (`model` is that file, `subject` the source; a source that only inherits or imports a filter is not reported). Both still load and run. Server-computed and read-only: ignored on create/update requests and only returned in responses. Present only when there are such findings. **Almost every `#@ preaggregate` that cannot be honored REJECTS A PUBLISH — a 400 at publish or PATCH — and fails a load thereafter.** The two access-modifier violations are the exception: they warn at BOTH gates and appear in this array. See the split below. Rejected are a `#@ preaggregate` anywhere but on a measure; a `#@ preaggregate` with no `grain=`; a grain naming anything but a dimension the base source itself declares, which rules out an inline time truncation such as `order_time.day`; a measure that cannot be correctly re-aggregated to a coarser grain, whether because its aggregate has no exact merge function (`count(distinct)`, `median`, percentiles, `mode`, and `avg` until it is decomposed) or because it carries its own filter, an ungrouping (`all`, `exclude`), or a required group-by; a measure whose expression cannot be POSITIVELY classified as re-aggregatable, which fails closed rather than being guessed at; a base source with a FAN-OUT join (`join_many` or `join_cross`), which can multiply rows, while a `join_one` is permitted and a measure aggregating through one is served normally; a base source that already fails persist eligibility (unbound parameters, `given` references, authorize gates); `sharing=` or `schedule=` at the resource level; and a synthesized rollup name that collides with an existing model object. WARNED rather than rejected, at publish and at load alike, is a `#@ preaggregate` on a measure the source does not publicly expose, or a grain naming a hidden dimension — a rollup STORES its grain and each measure\'s partial, and the stored table is served under the base\'s name without the source\'s field visibility applying to it. Each names the measure and the fix. Refusing rather than silently dropping the measure is the deliberate choice. A dropped measure is not served from the rollup at ANY grain, so the declaration would have no effect whatsoever while still reading as applied — and the build cost of the rollup would still be paid. An author who writes `#@ preaggregate` on a measure that cannot be rolled up has made a modeling mistake, and an error is where a mistake belongs. The same verdict is enforced at LOAD for every violation EXCEPT the two access-modifier ones, so a package whose declarations stopped being honorable does not load at all: it is absent from its environment and reported in `ServerStatus.loadErrors`. Worth knowing because whether a measure can be re-aggregated is derived from the compiled model, so a Malloy version change can in principle reclassify a measure that published cleanly long before. That surfaces as a package that stops loading rather than as a package quietly serving without its rollups — louder, and deliberately so, since the alternative is paying for rollups that answer nothing. The two access-modifier violations are the deliberate exception, and for two reasons rather than a lesser severity. They WARN at publish and at load alike and appear in this array. First, a package annotating a hidden field published and loaded before this rule existed — refusing it would stop an already-published package from doing either because a new validation was added, which is not a thing a server upgrade may do. Second, the refusal was unfollowable: an annotation INHERITED onto a source that then hides the measure raises it, while that source produces no plan at all and nothing is exposed, so the advice to make the field public or drop the annotation asks an author to give up either the hiding or the rollup over a model that was already safe. Warning is safe here and would not be for the others: what keeps a hidden field out of a rollup is that the planner refuses to plan one at all, so no table is built and nothing can be served whether or not anyone reads the message. For the other violations the refusal IS the enforcement, which is why they stay fatal.
|
|
2161
2398
|
*/
|
|
@@ -2436,7 +2673,7 @@ export interface PackageServingState {
|
|
|
2436
2673
|
*/
|
|
2437
2674
|
'sourceContentSha'?: string;
|
|
2438
2675
|
/**
|
|
2439
|
-
* Server-computed, read-only: whether the CONFIGURED build manifest is currently bound to this package\'s served models. `unbound` = no manifest configured, so the package serves live. `bound` = the configured manifest was fetched and applied. `bind_failed` = a `manifestLocation` is configured but its fetch/bind failed or timed out, so the configured manifest is NOT applied. `live_fallback` is retained, no longer produced: releases before this one said it for `bind_failed`, so a client should read both the same. Lets the caller confirm the publisher actually bound the configured manifest rather than inferring it from logs. `bound` reports that the bind ran to completion, NOT that any query routes to a materialized table: an entry whose source fails the eligibility gate is dropped
|
|
2676
|
+
* Server-computed, read-only: whether the CONFIGURED build manifest is currently bound to this package\'s served models. `unbound` = no manifest configured, so the package serves live. `bound` = the configured manifest was fetched and applied. `bind_failed` = a `manifestLocation` is configured but its fetch/bind failed or timed out, so the configured manifest is NOT applied. `live_fallback` is retained, no longer produced: releases before this one said it for `bind_failed`, so a client should read both the same. Lets the caller confirm the publisher actually bound the configured manifest rather than inferring it from logs. `bound` reports that the bind ran to completion, NOT that any query routes to a materialized table: an entry whose source fails the eligibility gate is dropped. Read `manifestEntryCount` and `storageServeBindings` for what actually bound. An EMPTY manifest is a bind like any other: it is fetched and applied, binds nothing, and reports `bound` with `manifestEntryCount` 0 and no `storageServeBindings`, while the package serves entirely live. That combination is the signature — `bound` with neither tier populated means the manifest carried nothing, not that the bind was missed. `bind_failed` does NOT imply the package is serving live. It says the configured manifest was not applied — not that nothing is. A failed FIRST bind leaves nothing bound (`boundManifestUri` null), but a failed REBIND leaves the previously bound manifest in place: its database substitutions stay compiled in, its storage serve bindings stay installed, and `boundManifestUri`, `manifestEntryCount` and `storageServeBindings` all continue to describe it. That rebind guarantee covers a failure BEFORE either tier applies — the manifest fetch failing or timing out, which is what produces `bind_failed` in practice. A failure partway through the recompile, after the new models are installed but before the binding is recorded, is out of scope: the new substitutions would be live while these fields still described the previous manifest. So the invariant to hold, whatever the status says: a non-null `boundManifestUri` is a LIVE reference to the manifest whose tables this package is currently serving from. A caller reclaiming superseded physical tables must treat it as one regardless of `manifestBindingStatus` — reading `bind_failed` as \"not serving from manifest tables\" and reclaiming that generation would drop tables out from under a package actively serving them. It is named apart from the `live_fallback` on a query result\'s `servedFrom`, which reports that ONE query degraded to the warehouse. This one is about the package\'s binding, and as above does not imply any query ran live.
|
|
2440
2677
|
*/
|
|
2441
2678
|
'manifestBindingStatus'?: PackageServingStateManifestBindingStatusEnum;
|
|
2442
2679
|
/**
|
|
@@ -2448,11 +2685,11 @@ export interface PackageServingState {
|
|
|
2448
2685
|
*/
|
|
2449
2686
|
'boundManifestUri'?: string | null;
|
|
2450
2687
|
/**
|
|
2451
|
-
* Server-computed, read-only: sources currently bound to serve from a `storage=` destination via the virtual-source transform (distinct from the same-connection manifest binding above — a storage source is read cross-connection from its destination, not substituted in the manifest). Present only when at least one source is bound.
|
|
2688
|
+
* Server-computed, read-only: sources currently bound to serve from a `storage=` destination via the virtual-source transform (distinct from the same-connection manifest binding above — a storage source is read cross-connection from its destination, not substituted in the manifest). Present only when at least one source is bound. Like `boundManifestUri`, this describes whatever is CURRENTLY bound rather than the configured manifest: after a failed rebind it goes on listing the previously bound manifest\'s sources, which are still serving. \"Bound\" is not the same as \"serving\", and an entry with `origin: rollup` is where the two most often part: a rollup is listed here once its table exists, but it is only offered to a query through a composite re-exposing its base\'s name, so it does not serve when something else already claims that name. Read `origin` before treating a row as evidence that queries are being accelerated.
|
|
2452
2689
|
*/
|
|
2453
2690
|
'storageServeBindings'?: Array<StorageServeBinding>;
|
|
2454
2691
|
/**
|
|
2455
|
-
* Server-computed, read-only: for each source the package materializes (each `#@ persist` source and each synthesized rollup), whether queries are answered from its table, and when not, why and what to change. Recomputed on every read from the build plan and the binding as they stand, so it moves with each bind. Absent when the package materializes nothing. A `live` verdict is the package-level form of a live fallback that is otherwise visible only per query: a source
|
|
2692
|
+
* Server-computed, read-only: for each source the package materializes (each `#@ persist` source and each synthesized rollup), whether queries are answered from its table, and when not, why and what to change. Recomputed on every read from the build plan and the binding as they stand, so it moves with each bind. Absent when the package materializes nothing. A `live` verdict is the package-level form of a live fallback that is otherwise visible only per query: a source no published source reaches, one under a row-level gate the storage tier cannot keep. `POST …/packages?dryRun=true` answers the same verdicts for a package before it is published, with each stored source\'s named views checked as well.
|
|
2456
2693
|
*/
|
|
2457
2694
|
'serveVerdicts'?: Array<ServeVerdict>;
|
|
2458
2695
|
}
|
|
@@ -2534,6 +2771,10 @@ export interface PackageStatusEntry {
|
|
|
2534
2771
|
* Actionable messages for declared explores that do not resolve to a real model in this package (e.g. a misspelled path, or a notebook listed as an explore). Server-computed and read-only: it is ignored on create/update requests and only ever returned in responses. Present only when there are such problems. Loading is fail-safe — the unresolved entry simply lists nothing rather than exposing everything — so this is the signal that a package is misconfigured; publishing such a package is rejected.
|
|
2535
2772
|
*/
|
|
2536
2773
|
'exploresWarnings'?: Array<string>;
|
|
2774
|
+
/**
|
|
2775
|
+
* Set only on the response of a reload (`?reload=true`), when the package materializes anything: each materialized item, with its tier, destination, state, whether queries are answered from it, and why not. Ignored on create and update requests.
|
|
2776
|
+
*/
|
|
2777
|
+
'materializationSummary'?: MaterializationSummary;
|
|
2537
2778
|
/**
|
|
2538
2779
|
* Non-fatal findings collected when the package loaded, none of which stop the model compiling or the package loading. Render-tag findings: a render annotation (e.g. `# big_value`, `# currency` or `# colspan`) the renderer cannot apply as written, either malformed for the field it sits on, so it renders as \"[object Object]\" or an inline error at query time, or inert where it sits and silently ignored. Materialization findings: a `storage=` source not served from storage, a `#@ persist` source that was not recognized as materializable, a `#@ persist` REFUSED by the compile-time eligibility gate (one entry per `BuildPlan.refusedSources` member, carrying that gate\'s own message), a persist-target collision, and materialization-config problems that degrade attribution. A refusal is the one materialization finding the build plan cannot also be read for: a refused `storage`/`database` source is ABSENT from `BuildPlan.sources`, so nothing there records that the annotation was written at all. Discovery findings: a model on the package\'s surface whose export closure surfaces no sources or named queries, so it lists as empty and renders a blank page; a surface whose every model failed to compile, so every model in the package answers 404 by name; and, on the reload that caused it, a package that had a surface and now has none, so every source that surface hid is listed and queryable by name again. Manifest findings: each deprecated use of `explores` or of `queryableSources: \"declared\"`, and a root file such as `Index.malloy` that differs from `index.malloy` only in case and so is ignored. A root `index.malloy` with no manifest keys gets no warning. Report findings (one lint pass per report, of either layout, wherever it lives): a file whose artifact tag does not parse or does not describe a report, a tile or suggest query that does not resolve, a `# drill` naming a destination that is not a report, and a tile, single query or filter suggest that reads a source the surface does not export, so it won\'t load. A `# drill` destination is a path from the package root (a bare name is a file at the root); one that names no report is unresolved (`error`). Curation findings: a root `index.malloy` carrying an artifact tag, which is ignored (`index-is-not-a-report`, `error`); and a report that `index.malloy` imports or `explores` lists (`report-on-surface`, `warn`). Two report findings are about Publisher rather than about the package: one when a file carrying an artifact tag could not be read and so is not served at all, and one when the lint stops early, in which case the list must be read as incomplete rather than as a clean package. A linear report whose cells could not be read gets a finding that names the line and the fix and is reported with severity `error`, because it is served with that error instead of opening. The per-file report findings each name their line and the fix and carry a `code`; they are computed at discovery and are also returned by `/compile` at file and package scope. These codes are `error` and fail `/compile`: `notebook-markdown-opener-text` (more than a name after `(markdown)` on a block\'s opener), `notebook-markdown-attached-nowhere` (a `#(markdown)` annotation with no statement to take it), `notebook-artifact-unparsed` (an `## artifact` tag does not parse), and `notebook-cells-unreadable` (the reader could not read a linear report\'s cells), plus `report-kind-removed` (a tag that sets `kind=`, which is no longer read, so the file is not a report; the finding names the `layout=` to write), `report-cells-removed` (a linear tag that lists no `tiles`, the retired `run:` cell format, so the file is not a report; the fix is to list its tiles in `tiles=[…]`) and `report-layout-unknown` (a `layout=` other than `grid` or `linear`). The rest are `warn` (a mistyped `(markdown)` opener, a block that never closes, and similar). Skill and agent findings, all `warn`: a package skill under `skills/` that is not served (unreadable or linked-out `SKILL.md`, a frontmatter `name` that is not its directory name, a `skills/` directory that links out of the package) or served with a gap (no `description`, a `reference/` that cannot be listed or read); and each agent the manifest declares that is not served, or is served with a finding (an agent skill with no `description`, a skills directory with no skills, an unreadable reference). Deprecated-format findings, all `warn`: each `.malloynb` notebook (`model` is its path), and each source a file declares deprecated `#(filter)` annotations on (`model` is that file, `subject` the source; a source that only inherits or imports a filter is not reported). Both still load and run. Server-computed and read-only: ignored on create/update requests and only returned in responses. Present only when there are such findings. **Almost every `#@ preaggregate` that cannot be honored REJECTS A PUBLISH — a 400 at publish or PATCH — and fails a load thereafter.** The two access-modifier violations are the exception: they warn at BOTH gates and appear in this array. See the split below. Rejected are a `#@ preaggregate` anywhere but on a measure; a `#@ preaggregate` with no `grain=`; a grain naming anything but a dimension the base source itself declares, which rules out an inline time truncation such as `order_time.day`; a measure that cannot be correctly re-aggregated to a coarser grain, whether because its aggregate has no exact merge function (`count(distinct)`, `median`, percentiles, `mode`, and `avg` until it is decomposed) or because it carries its own filter, an ungrouping (`all`, `exclude`), or a required group-by; a measure whose expression cannot be POSITIVELY classified as re-aggregatable, which fails closed rather than being guessed at; a base source with a FAN-OUT join (`join_many` or `join_cross`), which can multiply rows, while a `join_one` is permitted and a measure aggregating through one is served normally; a base source that already fails persist eligibility (unbound parameters, `given` references, authorize gates); `sharing=` or `schedule=` at the resource level; and a synthesized rollup name that collides with an existing model object. WARNED rather than rejected, at publish and at load alike, is a `#@ preaggregate` on a measure the source does not publicly expose, or a grain naming a hidden dimension — a rollup STORES its grain and each measure\'s partial, and the stored table is served under the base\'s name without the source\'s field visibility applying to it. Each names the measure and the fix. Refusing rather than silently dropping the measure is the deliberate choice. A dropped measure is not served from the rollup at ANY grain, so the declaration would have no effect whatsoever while still reading as applied — and the build cost of the rollup would still be paid. An author who writes `#@ preaggregate` on a measure that cannot be rolled up has made a modeling mistake, and an error is where a mistake belongs. The same verdict is enforced at LOAD for every violation EXCEPT the two access-modifier ones, so a package whose declarations stopped being honorable does not load at all: it is absent from its environment and reported in `ServerStatus.loadErrors`. Worth knowing because whether a measure can be re-aggregated is derived from the compiled model, so a Malloy version change can in principle reclassify a measure that published cleanly long before. That surfaces as a package that stops loading rather than as a package quietly serving without its rollups — louder, and deliberately so, since the alternative is paying for rollups that answer nothing. The two access-modifier violations are the deliberate exception, and for two reasons rather than a lesser severity. They WARN at publish and at load alike and appear in this array. First, a package annotating a hidden field published and loaded before this rule existed — refusing it would stop an already-published package from doing either because a new validation was added, which is not a thing a server upgrade may do. Second, the refusal was unfollowable: an annotation INHERITED onto a source that then hides the measure raises it, while that source produces no plan at all and nothing is exposed, so the advice to make the field public or drop the annotation asks an author to give up either the hiding or the rollup over a model that was already safe. Warning is safe here and would not be for the others: what keeps a hidden field out of a rollup is that the planner refuses to plan one at all, so no table is built and nothing can be served whether or not anyone reads the message. For the other violations the refusal IS the enforcement, which is why they stay fatal.
|
|
2539
2780
|
*/
|
|
@@ -2613,6 +2854,10 @@ export interface PackageStatusEntry {
|
|
|
2613
2854
|
* @deprecated
|
|
2614
2855
|
*/
|
|
2615
2856
|
'secureGivens'?: Array<SecureGivenSummary>;
|
|
2857
|
+
/**
|
|
2858
|
+
* Set on a loaded copy that materializes anything: counts of its materialized items by state, and the ones not answered from a table, with reason codes. Recomputed at most every few seconds. The full rows are on the reload response and `compile` at scope `package` (`materializationSummary`).
|
|
2859
|
+
*/
|
|
2860
|
+
'materializationDigest'?: MaterializationDigest;
|
|
2616
2861
|
}
|
|
2617
2862
|
export declare const PackageStatusEntryArchiveStatusEnum: {
|
|
2618
2863
|
readonly Archive: "archive";
|
|
@@ -2673,6 +2918,10 @@ export interface PackageStatusEntryFields {
|
|
|
2673
2918
|
* The manifest URI actually bound to the served models; null when unbound. A non-null value is a live reference. See `PackageServingState.boundManifestUri`.
|
|
2674
2919
|
*/
|
|
2675
2920
|
'boundManifestUri'?: string | null;
|
|
2921
|
+
/**
|
|
2922
|
+
* Set on a loaded copy that materializes anything: counts of its materialized items by state, and the ones not answered from a table, with reason codes. Recomputed at most every few seconds. The full rows are on the reload response and `compile` at scope `package` (`materializationSummary`).
|
|
2923
|
+
*/
|
|
2924
|
+
'materializationDigest'?: MaterializationDigest;
|
|
2676
2925
|
}
|
|
2677
2926
|
export declare const PackageStatusEntryFieldsArchiveStatusEnum: {
|
|
2678
2927
|
readonly Archive: "archive";
|
|
@@ -2797,11 +3046,11 @@ export interface PackageWarningsInner {
|
|
|
2797
3046
|
*/
|
|
2798
3047
|
'message'?: string;
|
|
2799
3048
|
/**
|
|
2800
|
-
* A stable identifier for the finding\'s family, for a client that acts on it rather than only showing it; absent for a family that has none yet. `deprecated-malloynb-notebook`: a `.malloynb` notebook, the deprecated cell format (one per file, `model` naming it). `malloynb-cell-refused`: a `.malloynb` code cell whose `run:` statement the query route refuses for every reader in the Console, which sends no privilege and no `filterParams`, so the cell never runs there. One per cell, up to the bound below, `model` naming the notebook, severity `warn`. The message names the cell by its 1-based position among the notebook\'s cells, markdown cells included, and the fix. `reason` names the rule: `off_surface` is the 404 for a source the package surface does not publish, which a source the notebook declares never is on a package with a curated surface, an `index.malloy` or the deprecated `explores`; a caller with `includeHiddenFilesAndSources` still runs such a cell. `caller_annotation` is the 400 for text carrying an annotation only the model author may write, such as `#(authorize)`, comments included. `required_filter` is the 400 for a source with a required `#(filter)`. `restricted_mode` is the 400 for a `sql_*` call or a direct table read. `compile_error` is the 400 for any other failure of the statement to compile on its own. A cell that only a reader\'s givens refuse, by `#(authorize)` or a row-level gate, is not reported. Markdown cells are not read, as the Console does not run them. A notebook lists at most 10 refused cells one by one, and the package at most 50. The rest of a notebook that lists some are named by number and reason in one `malloynb-cells-unlisted` warning (`model` the notebook; `warn`). The notebooks after the package limit share one `malloynb-cells-unlisted` warning with no `model`, which counts their cells by reason and names the first 10 of them. The report lint metric still counts each refused cell under `malloynb-cell-refused`. `malloynb-cell-check-failed`: a notebook whose cell check could not run, so a refused cell of it may have no warning; the cause is in the server log (one per notebook, `warn`). `deprecated-filter-annotation`: a source declaring deprecated `#(filter)` annotations (one per declaring source, `model` naming its file and `subject` the source). `deprecated-preaggregate-annotation`: a measure declaring `#@ preaggregate` or the deprecated alias `#(preaggregate)`, whose v2 spelling is `#(rollup)`; the message names the spelling it found (one per measure, `model` its file, `subject` the source and the message the measure; `warn`; only while `PUBLISHER_MATERIALIZE` is on). `deprecated-rollup-namespace`: a rollup line placed with `namespace=`, the deprecated spelling of its `name=` container; still read, in that container under the readable name (one per measure and container, `subject` `<base>.<measure>`; `warn`). `classification-coverage`: a published source with a dimension or measure that carries no `#(classification)` while some field in the package does (one per source, `model` naming its file and `subject` the source; `warn`; see docs/classification.md). `classification-malformed`: a `#(classification)` annotation that names no single class (one per field, `subject` the source; `warn`). `classification-downgrade`: a field that declares a lower class than the fields its expression reads, which Publisher cannot tell from a real de-identification, so a review has to (one per field, `subject` the source; `warn`; a plain copy under `#(carries)` refuses the load instead). Materialization codes follow one rule: the suffix tells the outcome. An INVALID annotation (or invalid code it covers) fails the publish and the load, on every path, so its code appears only in the load failure\'s message (the publish 4xx and `loadErrors`), never as a warning here: `persist-invalid`, `materialize-invalid`, `rollup-invalid`, `persist-view-invalid` and `persist-query-invalid` (a bad value or contradictory combination: a `storage=` that names nothing, an `@env.` reference, an unusable, unsafe, unquoted or reserved `name=`, an `inline=` that names no join, an incremental key or `refresh=\"incremental\"` on a view or query); `persist-unknown-key`, `materialize-unknown-key` and `rollup-unknown-key` (every route\'s key set is closed, a `freshness.` group\'s included); `persist-retired-key` and `materialize-retired-key` (`sharing=`, `schedule=`, `partition=`, and on `#@ persist` `realization=`); `persist-unparseable`, `materialize-unparseable`, `rollup-unparseable`, `persist-view-unparseable` and `persist-query-unparseable`; `persist-not-materializable` (a `#@ persist` on a shape Malloy does not plan); `rollup-not-a-measure`, `rollup-unknown-grain` and `rollup-not-mergeable` (a rollup line on a field that is not a measure, a grain naming no dimension, a measure no rollup can merge); `materialization-table-collision` (two sources whose `name=` puts them on one table; under `PERSIST_COLLISION_ENFORCE=false` a refusal instead); and `materialization-near-miss` (a misspelled materialization route or directive, such as `#(materialise)` or `#@ persits`). `preaggregate-malformed` is retained and no longer produced: it is `rollup-invalid` or `rollup-unparseable` now. Retained, no longer produced: `preaggregate-invalid`, `preaggregate-unknown-key`, `preaggregate-unparseable`, `preaggregate-not-a-measure`, `preaggregate-unknown-grain` and `preaggregate-not-mergeable`, now `rollup-invalid`, `rollup-unknown-key`, `rollup-unparseable`, `rollup-not-a-measure`, `rollup-unknown-grain` and `rollup-not-mergeable`. A measure or source that carries both `#(rollup)` and `#(preaggregate)` is `rollup-invalid`. A VALID annotation Publisher cannot build here is refused alone, answered live, while the package loads, and is severity `warn`, never `error`. Every one is a `BuildPlan.refusedSources` entry with a bounded `reason`, and its warning\'s code names the mechanism: `persist-not-built` (a `#@ persist` source; `subject` the source), `materialize-not-built` (a `#(materialize)` source; `subject` the source), `persist-view-not-built` and `persist-query-not-built` (a persisted view or named query; `subject` the view or query), and `rollup-not-built` (a `#(rollup)` or `#@ preaggregate` rollup; `subject` the base, or `<base>.<measure>` for one measure). The message says why, and `reason` is the refusal record\'s bounded reason. `preaggregate-not-built` is `rollup-not-built`\'s former name, retained, no longer produced: 0.15.0 and 0.16 repeated each `rollup-not-built` warning under it. `persist-source-refused`, the former name of `persist-not-built` repeated beside it in 0.14.0, is no longer produced. Retained, no longer produced: the rollup sub-family `preaggregate-hidden-field`, `-access-filter`, `-time-zone`, `-current-time`, `-reads-given`, `-unreadable-measure`, `-join-level` and `-name-clash`, now each `rollup-not-built` with the reasons `hidden_field`, `access_filter` (or `authorize`), `time_zone`, `current_time`, `reads_given`, `inherited_where_with_given` or `given_where_over_unstored_field`, `unreadable_measure`, `join_not_in_grain` and `partial_name_collision`. `materialization-storage-mode`: a `storage=` source the deployment\'s `PERSIST_STORAGE_MODE` (`off` or `write-only`) does not serve from storage (`subject` the source, or a rollup\'s base; `reason` `storage_mode`; `warn`). `materialization-unreachable`, `materialization-destination-missing` and `materialization-connection-cannot-hold-table`: a source whose serve verdict is `live` for the reason each names (no published source reaches it; its `storage=` destination is not configured; its connection creates no tables), with the verdict\'s `message` and `fixes` (`subject` the source; `reason` the verdict\'s; `warn`). `materialize-pair-full-refresh`: a `#(materialize)` pair table (an inlined `join_many`) whose `refresh=\"incremental\"` is not honoured: it is rebuilt in full on every refresh, and served (`subject` the source; `warn`). `materialize-extension-full-refresh`: an incremental `#(materialize)` extension whose watermark is not the same stored column as its incremental parent\'s: it is rebuilt in full over the parent\'s table whenever that table changes, and served (`subject` the extension; `warn`; the message names both watermarks). `materialize-extension-generation-unproven`: the newest run rebuilt an incremental extension in full because it could not prove which build of its parent\'s table it last read (neither the run\'s ledger entry nor the bound manifest records it; step reason `upstream_generation_skipped`) (`subject` the extension; `warn`). `rollup-join-one-key-repeated`: a rollup\'s last build found a `join_one` key repeated in the data, so queries that read that join beside other aggregates are answered live (`subject` the rollup\'s base; `warn`). Its former name, `preaggregate-join-one-key-repeated`, is retained, no longer produced. `served-copy-not-served`: the served copy (the author\'s own files, each stored source re-rooted on its table) leaves a source as written, so it answers live, or serves it with a join read as written or left out; `reason` names why (`compile_failed`, `cross_connection_unbuilt`, `column_types`, `no_declaration`, `definition_not_parsed`, `pair_join_not_found`, `pair_not_compiled`, `fields_not_carried`, `read_terms_not_kept`, `cross_connection_join`, `inline_join_kept`, `reroot_not_compiled`, `classification_not_kept`; an open set) (`subject` the source; `warn`). `model-recompile-failed`: a model file that compiled before did not compile when the package bound new tables, although neither its text nor that of any file it imports changed since (most often because a table it reads directly was dropped), so the file keeps serving the model it last compiled rather than answering every query on its sources with the compile error, and the package reads `stale: true` in `/status` `loadErrors`. A file an author edited that fails to compile is never kept: it answers with its compile error. The message carries the compile error and names the file\'s sources, and which of them stopped serving their stored tables because an upstream table they were built from changed (those answer live, and read `incompatible`, `upstream_altered`) (`model` the file; `reason` `compile_failed`; `warn`). Cleared by the next bind or reload that compiles the file. `row-level-gate-unexpressible`: a row-level gate an entry point inherits, whose field it no longer carries, so that entry point denies every request; `row-level-gate-reads-no-given`: a source-line gate that reads no given, a fixed predicate rather than an access rule keyed on the caller; `row-level-gate-negated-membership`: a source-line gate that negates a membership test, which an empty given turns into match-all, or that is too deep to check for one (its message then says it is too deep to check, not that it negates one) (`model` the entry point\'s file, `subject` the entry point; `warn`; the model still loads). `annotation-near-miss` and `annotation-malformed-route`: an annotation whose route or directive looks like a misspelled one Publisher reads (`warn`); `annotation-gate-near-miss`: a misspelled gate annotation (`#(authorise)`), which `compile_model` refuses. `persist-incremental-no-merge-key`: an incremental source with no `merge_key=`, so each refresh replaces its watermark range (`subject` the source; `warn`). `persist-reads-current-time`: a `#@ persist` source, persisted view or persisted named query whose stored relation reads the current time (`now`, or a relative time filter string such as `f\'last 7 days\'`), so its answers are as of its last build and it is rebuilt on every run; the message names where it reads the clock and how to answer as of each query instead (one per table, `subject` the source, the view as `<source> -> <view>`, or the query; `warn`). `persist-incremental-shared-address`: sources that compile to the same SQL on one connection, so they share one table and one boundary, where at least one is incremental (one per source; `warn`). `persist-incremental-late-rows`: an incremental source whose bound table a delta\'s late-row check found missing rows stamped just below where a delta started reading, which no later delta reads (its manifest entry\'s `lateRows`); it is carried until the source is rebuilt in full (one per source; `warn`). `rollup-join-one-key-repeated`: a bound rollup whose last build found the key of a `join_one` it reads repeated, so a query reading that join beside other aggregates is answered live; it clears once a build finds the key unique (one per rollup; `warn`). `preaggregate-join-one-key-repeated` is retained, no longer produced: it is `rollup-join-one-key-repeated` now. `join-bypass`: an author join from a published source to one with a stricter gate, which the join does not carry (one per join, or one for a walk cut short at the join bound; always a `warn`, never a load refusal; see docs/authorize.md). `storage-column-type-mismatch`: a `storage=` table of any kind (`#@ persist`, `#(materialize)`, a rollup, a persisted view or query) stores a column as a type other than the one its build declares, as its build wrote it (a change after the build is `materialization-table-incompatible`). It is read through a cast to the declared type where that is faithful, and otherwise answered live, never read as its stored type (one per source and column, `model` the model declaring it, `subject` the source, a rollup\'s base, or a view\'s or query\'s build source, the message naming the column, both types and which applies; `warn`; see docs/materialization.md). `database-column-type-mismatch` is retained, no longer produced: a bound table altered outside a build is now `materialization-table-incompatible`, answered live whole until it is rebuilt, never read through a cast. `materialization-table-incompatible`: a bound table, on either tier, that no longer matches the column contract its build recorded (a column gone, retyped or recollated since, or its source now declaring another type than it was built for); it is answered live until a build rebuilds it (one per source, `subject` the source; `warn`; the serve verdict\'s `incompatible` names the table and what changed). `materialization-contract-missing`: a bound table whose entry carries no column contract (built before contracts were recorded); it is answered live until a build rebuilds it in full (one per source, `subject` the source; `warn`). `materialization-types-unrecorded` is retained, no longer produced: a table with no recorded types is `materialization-contract-missing` now. `table-kept`: a table an auto-run replaced when its source\'s table was renamed or moved, which Publisher keeps rather than drops: one at an author\'s exact `name=` (never dropped), one in a storage destination that is no longer configured (which, when the destination was renamed rather than removed, may be the table served under the new name), or one a `storage=` or tier move left under the name the source is served under now (which may be the very table served, so it is never dropped). Listed on the newest run\'s `metadata.keptTables` until no committed run names it in its place (its runs deleted; a delete is record-only), a run finds it dropped by hand (never on Snowflake or MySQL, whose catalogs hide tables), or its name is used again in its own place (one per table, `model` the model declaring the source, `subject` the source or a rollup\'s base, the message naming the table and where it is, `reason` the kept table\'s `author_name`, `destination_missing` or `may_be_served`; `warn`; see docs/materialization.md). `database-table-unread`: a bound table in a source\'s own database whose columns could not be read when it was bound (missing, unreadable, slower than the read\'s bound, or named in more than one schema), so its queries are answered live until a read succeeds; the message names the table or rollup, one fixed reason (its connection could not be opened, the catalog read timed out, the catalog query failed, not found, a name matching more than one table, a name the catalog cannot read; never the driver\'s text) and whether a retry is pending, and the warning clears once the table is read (only for a table a source of the package reads; one per table, `model` the model declaring its source, `subject` the source, or a rollup\'s base, when the plan knows the table; `reason` one of `connection_failed`, `timed_out`, `catalog_query_failed`, `not_found`, `ambiguous`, `unparseable`, `not_read`; `warn`; see docs/materialization.md). `storage-table-unread`: the same, for a bound `storage=` table whose columns its destination session could not read when it was bound, or that a query\'s failed read left unread until the package reads it again; the message names the table or rollup and its destination; same fields and reasons. `database-native-type-missing`: a database table is bound with no captured warehouse type (its manifest entry\'s `nativeSchema`) for a column whose field Malloy types as a big integer. On BigQuery the column is read as `INT64`, its only integer type, and still serves; on any other dialect it is left out, so a query that reads it is answered live. The next full rebuild captures the types (one per source, `model` the first model binding it, `subject` the source, the message naming the columns and which applies; `warn`; see docs/materialization.md). Its former name, `stored-native-schema-missing`, is retained, no longer produced. `entities-…` (`entities-not-a-dimension`, `entities-parameterized-source`, `entities-multiple-required-filters`, `entities-sharing-not-allowed-on-dimension`, `entities-schedule-not-allowed-on-dimension`, `entities-required-filter-missing-dimension`, `entities-required-filter-non-public-dimension`): an `#(index)` or required `#(filter)` an index cannot honor, left out of `GET …/entities` (`model` its file; `warn`). The per-file report findings (`notebook-…`, `report-…`) and the report curation findings (`report-on-surface`, `index-is-not-a-report`). The message wording may change; the code does not.
|
|
3049
|
+
* A stable identifier for the finding\'s family, for a client that acts on it rather than only showing it; absent for a family that has none yet. `render-tag`: a render annotation the renderer cannot apply as written, malformed for its field (`error`) or inert where it sits (`warn`); one per finding, `model` its file and `subject` the query or view it sits on. `render-tag-check-failed`: a model whose render-tag check did not finish (it could not be read, `error`, or the validator failed, `warn`), so its render-tag findings are unknown rather than clean; reported by a package-scope compile, one per model. `deprecated-malloynb-notebook`: a `.malloynb` notebook, the deprecated cell format (one per file, `model` naming it). `malloynb-cell-refused`: a `.malloynb` code cell whose `run:` statement the query route refuses for every reader in the Console, which sends no privilege and no `filterParams`, so the cell never runs there. One per cell, up to the bound below, `model` naming the notebook, severity `warn`. The message names the cell by its 1-based position among the notebook\'s cells, markdown cells included, and the fix. `reason` names the rule: `off_surface` is the 404 for a source the package surface does not publish, which a source the notebook declares never is on a package with a curated surface, an `index.malloy` or the deprecated `explores`; a caller with `includeHiddenFilesAndSources` still runs such a cell. `caller_annotation` is the 400 for text carrying an annotation only the model author may write, such as `#(authorize)`, comments included. `required_filter` is the 400 for a source with a required `#(filter)`. `restricted_mode` is the 400 for a `sql_*` call or a direct table read. `compile_error` is the 400 for any other failure of the statement to compile on its own. A cell that only a reader\'s givens refuse, by `#(authorize)` or a row-level gate, is not reported. Markdown cells are not read, as the Console does not run them. A notebook lists at most 10 refused cells one by one, and the package at most 50. The rest of a notebook that lists some are named by number and reason in one `malloynb-cells-unlisted` warning (`model` the notebook; `warn`). The notebooks after the package limit share one `malloynb-cells-unlisted` warning with no `model`, which counts their cells by reason and names the first 10 of them. The report lint metric still counts each refused cell under `malloynb-cell-refused`. `malloynb-cell-check-failed`: a notebook whose cell check could not run, so a refused cell of it may have no warning; the cause is in the server log (one per notebook, `warn`). `deprecated-filter-annotation`: a source declaring deprecated `#(filter)` annotations (one per declaring source, `model` naming its file and `subject` the source). `deprecated-preaggregate-annotation`: a measure declaring `#@ preaggregate` or the deprecated alias `#(preaggregate)`, whose v2 spelling is `#(rollup)`; the message names the spelling it found (one per `#@ preaggregate` line, naming the `#(rollup)` line it is read as, or one per measure for `#(preaggregate)`; `model` its file, `subject` the source and the message the measure; `warn`). `deprecated-rollup-namespace`: a rollup line placed with `namespace=`, the deprecated spelling of its `name=` container; still read, in that container under the readable name (one per measure and container, `subject` `<base>.<measure>`; `warn`). `classification-coverage`: a published source with a dimension or measure that carries no `#(classification)` while some field in the package does (one per source, `model` naming its file and `subject` the source; `warn`; see docs/classification.md). `classification-malformed`: a `#(classification)` annotation that names no single class (one per field, `subject` the source; `warn`). `classification-downgrade`: a field that declares a lower class than the fields its expression reads, which Publisher cannot tell from a real de-identification, so a review has to (one per field, `subject` the source; `warn`; a plain copy under `#(carries)` refuses the load instead). Materialization codes follow one rule: the suffix tells the outcome. An INVALID annotation (or invalid code it covers) fails the publish and the load, on every path, so its code appears only in the load failure\'s message (the publish 4xx and `loadErrors`), never as a warning here: `persist-invalid`, `materialize-invalid`, `rollup-invalid`, `persist-view-invalid` and `persist-query-invalid` (a bad value or contradictory combination: a `storage=` that names nothing, an `@env.` reference, an unusable, unsafe, unquoted or reserved `name=`, an `inline=` that names no join, an incremental key or `refresh=\"incremental\"` on a view or query); `persist-unknown-key`, `materialize-unknown-key` and `rollup-unknown-key` (every route\'s key set is closed, a `freshness.` group\'s included); `persist-retired-key` and `materialize-retired-key` (`sharing=`, `schedule=`, `partition=`, and on `#@ persist` `realization=`); `persist-unparseable`, `materialize-unparseable`, `rollup-unparseable`, `persist-view-unparseable` and `persist-query-unparseable`; `persist-not-materializable` (a `#@ persist` on a shape Malloy does not plan); `rollup-not-a-measure`, `rollup-unknown-grain` and `rollup-not-mergeable` (a rollup line on a field that is not a measure, a grain naming no dimension, a measure no rollup can merge); `materialization-table-collision` (two sources whose `name=` puts them on one table); and `materialization-near-miss` (a misspelled materialization route or directive, such as `#(materialise)` or `#@ persits`). `preaggregate-malformed` is retained and no longer produced: it is `rollup-invalid` or `rollup-unparseable` now. Retained, no longer produced: `preaggregate-invalid`, `preaggregate-unknown-key`, `preaggregate-unparseable`, `preaggregate-not-a-measure`, `preaggregate-unknown-grain` and `preaggregate-not-mergeable`, now `rollup-invalid`, `rollup-unknown-key`, `rollup-unparseable`, `rollup-not-a-measure`, `rollup-unknown-grain` and `rollup-not-mergeable`. A measure or source that carries both `#(rollup)` and `#(preaggregate)` is `rollup-invalid`. A VALID annotation Publisher cannot build here is refused alone, answered live, while the package loads, and is severity `warn`, never `error`. Every one is a `BuildPlan.refusedSources` entry with a bounded `reason`, and its warning\'s code names the mechanism: `persist-not-built` (a `#@ persist` source; `subject` the source), `materialize-not-built` (a `#(materialize)` source; `subject` the source), `persist-view-not-built` and `persist-query-not-built` (a persisted view or named query; `subject` the view or query), and `rollup-not-built` (a `#(rollup)` or `#@ preaggregate` rollup; `subject` the base, or `<base>.<measure>` for one measure). The message says why, and `reason` is the refusal record\'s bounded reason. `preaggregate-not-built` is `rollup-not-built`\'s former name, retained, no longer produced: 0.15.0 and 0.16 repeated each `rollup-not-built` warning under it. `persist-source-refused`, the former name of `persist-not-built` repeated beside it in 0.14.0, is no longer produced. Retained, no longer produced: the rollup sub-family `preaggregate-hidden-field`, `-access-filter`, `-time-zone`, `-current-time`, `-reads-given`, `-unreadable-measure`, `-join-level` and `-name-clash`, now each `rollup-not-built` with the reasons `hidden_field`, `access_filter` (or `authorize`), `time_zone`, `current_time`, `reads_given`, `inherited_where_with_given` or `given_where_over_unstored_field`, `unreadable_measure`, `join_not_in_grain` and `partial_name_collision`. `materialization-unreachable`, `materialization-destination-missing` and `materialization-connection-cannot-hold-table`: a source whose serve verdict is `live` for the reason each names (no published source reaches it; its `storage=` destination is not configured; its connection creates no tables), with the verdict\'s `message` and `fixes` (`subject` the source; `reason` the verdict\'s; `warn`). `materialize-pair-full-refresh`: a `#(materialize)` pair table (an inlined `join_many`) whose `refresh=\"incremental\"` is not honoured: it is rebuilt in full on every refresh, and served (`subject` the source; `warn`). `materialize-extension-full-refresh`: an incremental `#(materialize)` extension whose watermark is not the same stored column as its incremental parent\'s: it is rebuilt in full over the parent\'s table whenever that table changes, and served (`subject` the extension; `warn`; the message names both watermarks). `materialize-extension-generation-unproven`: the newest run rebuilt an incremental extension in full because it could not prove which build of its parent\'s table it last read (neither the run\'s ledger entry nor the bound manifest records it; step reason `upstream_generation_skipped`) (`subject` the extension; `warn`). `rollup-join-one-key-repeated`: a rollup\'s last build found a `join_one` key repeated in the data, so queries that read that join beside other aggregates, or, for a `join_one` the rollup\'s grain reads, queries that read nothing through it, are answered live (`subject` the rollup\'s base; `warn`). Its former name, `preaggregate-join-one-key-repeated`, is retained, no longer produced. `served-copy-not-served`: the served copy (the author\'s own files, each stored source re-rooted on its table) leaves a source as written, so it answers live, or serves it with a join read as written or left out; `reason` names why (`compile_failed`, `cross_connection_unbuilt`, `column_types`, `no_declaration`, `definition_not_parsed`, `pair_join_not_found`, `pair_not_compiled`, `fields_not_carried`, `read_terms_not_kept`, `cross_connection_join`, `inline_join_kept`, `reroot_not_compiled`, `classification_not_kept`, `sql_embed_cross_connection`, `sql_embed_bare`; an open set) (`subject` the source; `warn`). `model-recompile-failed`: a model file that compiled before did not compile when the package bound new tables, although neither its text nor that of any file it imports changed since (most often because a table it reads directly was dropped), so the file keeps serving the model it last compiled rather than answering every query on its sources with the compile error, and the package reads `stale: true` in `/status` `loadErrors`. A file an author edited that fails to compile is never kept: it answers with its compile error. The message carries the compile error and names the file\'s sources, and which of them stopped serving their stored tables because an upstream table they were built from changed (those answer live, and read `incompatible`, `upstream_altered`) (`model` the file; `reason` `compile_failed`; `warn`). Cleared by the next bind or reload that compiles the file. `row-level-gate-unexpressible`: a row-level gate an entry point inherits, whose field it no longer carries, so that entry point denies every request; `row-level-gate-reads-no-given`: a source-line gate that reads no given, a fixed predicate rather than an access rule keyed on the caller; `row-level-gate-negated-membership`: a source-line gate that negates a membership test, which an empty given turns into match-all, or that is too deep to check for one (its message then says it is too deep to check, not that it negates one) (`model` the entry point\'s file, `subject` the entry point; `warn`; the model still loads). `annotation-near-miss` and `annotation-malformed-route`: an annotation whose route or directive looks like a misspelled one Publisher reads (`warn`); `annotation-gate-near-miss`: a misspelled gate annotation (`#(authorise)`), which `compile_model` refuses. `persist-incremental-no-merge-key`: an incremental source with no `merge_key=`, so each refresh replaces its watermark range (`subject` the source; `warn`). `persist-reads-current-time`: a `#@ persist` source, persisted view or persisted named query whose stored relation reads the current time (`now`, or a relative time filter string such as `f\'last 7 days\'`), so its answers are as of its last build and it is rebuilt on every run; the message names where it reads the clock and how to answer as of each query instead (one per table, `subject` the source, the view as `<source> -> <view>`, or the query; `warn`). `persist-incremental-shared-address`: sources that compile to the same SQL on one connection, so they share one table and one boundary, where at least one is incremental (one per source; `warn`). `persist-incremental-late-rows`: an incremental source whose bound table a delta\'s late-row check found missing rows stamped just below where a delta started reading, which no later delta reads (its manifest entry\'s `lateRows`); it is carried until the source is rebuilt in full (one per source; `warn`). `simulation-manifest-bound`: a package or version whose `manifestLocation` simulated materialization left unbound, its manifest never fetched, so it serves live (`warn`). `rollup-join-one-key-repeated`: a bound rollup whose last build found the key of a `join_one` it reads repeated, so a query reading that join beside other aggregates is answered live, or, for a `join_one` its grain reads, a query reading nothing through it; it clears once a build finds the key unique (one per rollup and key; `warn`). `preaggregate-join-one-key-repeated` is retained, no longer produced: it is `rollup-join-one-key-repeated` now. `join-bypass`: an author join from a published source to one with a stricter gate, which the join does not carry (one per join, or one for a walk cut short at the join bound; always a `warn`, never a load refusal; see docs/authorize.md). `storage-column-type-mismatch`: a `storage=` table of any kind (`#@ persist`, `#(materialize)`, a rollup, a persisted view or query) stores a column as a type other than the one its build declares, as its build wrote it (a change after the build is `materialization-table-incompatible`). It is read through a cast to the declared type where that is faithful, and otherwise answered live, never read as its stored type (one per source and column, `model` the model declaring it, `subject` the source, a rollup\'s base, or a view\'s or query\'s build source, the message naming the column, both types and which applies; `warn`; see docs/materialization.md). `database-column-type-mismatch` is retained, no longer produced: a bound table altered outside a build is now `materialization-table-incompatible`, answered live whole until it is rebuilt, never read through a cast. `materialization-table-incompatible`: a bound table, on either tier, that no longer matches the column contract its build recorded (a column gone, retyped or recollated since, or its source now declaring another type than it was built for); it is answered live until a build rebuilds it (one per source, `subject` the source; `warn`; the serve verdict\'s `incompatible` names the table and what changed). `materialization-contract-missing`: a bound table whose entry carries no column contract (built before contracts were recorded); it is answered live until a build rebuilds it in full (one per source, `subject` the source; `warn`). `materialization-types-unrecorded` is retained, no longer produced: a table with no recorded types is `materialization-contract-missing` now. `table-kept`: a table an auto-run replaced when its source\'s table was renamed or moved, which Publisher keeps rather than drops: one at an author\'s exact `name=` (never dropped), one in a storage destination that is no longer configured (which, when the destination was renamed rather than removed, may be the table served under the new name), or one a `storage=` or tier move left under the name the source is served under now (which may be the very table served, so it is never dropped). Listed on the newest run\'s `metadata.keptTables` until no committed run names it in its place (its runs deleted; a delete is record-only), a run finds it dropped by hand (never on Snowflake or MySQL, whose catalogs hide tables), or its name is used again in its own place (one per table, `model` the model declaring the source, `subject` the source or a rollup\'s base, the message naming the table and where it is, `reason` the kept table\'s `author_name`, `destination_missing` or `may_be_served`; `warn`; see docs/materialization.md). `database-table-unread`: a bound table in a source\'s own database whose columns could not be read when it was bound (missing, unreadable, slower than the read\'s bound, or named in more than one schema), so its queries are answered live until a read succeeds; the message names the table or rollup, one fixed reason (its connection could not be opened, the catalog read timed out, the catalog query failed, not found, a name matching more than one table, a name the catalog cannot read; never the driver\'s text) and whether a retry is pending, and the warning clears once the table is read (only for a table a source of the package reads; one per table, `model` the model declaring its source, `subject` the source, or a rollup\'s base, when the plan knows the table; `reason` one of `connection_failed`, `timed_out`, `catalog_query_failed`, `not_found`, `ambiguous`, `unparseable`, `not_read`; `warn`; see docs/materialization.md). `storage-table-unread`: the same, for a bound `storage=` table whose columns its destination session could not read when it was bound, or that a query\'s failed read left unread until the package reads it again; the message names the table or rollup and its destination; same fields and reasons. `database-native-type-missing`: a database table is bound with no captured warehouse type (its manifest entry\'s `nativeSchema`) for a column whose field Malloy types as a big integer. On BigQuery the column is read as `INT64`, its only integer type, and still serves; on any other dialect it is left out, so a query that reads it is answered live. The next full rebuild captures the types (one per source, `model` the first model binding it, `subject` the source, the message naming the columns and which applies; `warn`; see docs/materialization.md). Its former name, `stored-native-schema-missing`, is retained, no longer produced. `entities-…` (`entities-not-a-dimension`, `entities-parameterized-source`, `entities-multiple-required-filters`, `entities-sharing-not-allowed-on-dimension`, `entities-schedule-not-allowed-on-dimension`, `entities-required-filter-missing-dimension`, `entities-required-filter-non-public-dimension`): an `#(index)` or required `#(filter)` an index cannot honor, left out of `GET …/entities` (`model` its file; `warn`). The per-file report findings (`notebook-…`, `report-…`) and the report curation findings (`report-on-surface`, `index-is-not-a-report`). The message wording may change; the code does not.
|
|
2801
3050
|
*/
|
|
2802
3051
|
'code'?: string;
|
|
2803
3052
|
/**
|
|
2804
|
-
* The bounded cause of a finding, so a client branches on it rather than on the message (whose wording may change): the refusal record\'s `reason` on a `*-not-built` warning; the served copy\'s reason on `served-copy-not-served`; `compile_failed` on `model-recompile-failed`; the unread reason on `database-table-unread` and `storage-table-unread`; the kept table\'s reason on `table-kept`; the serve verdict\'s reason on a `materialization-*` verdict warning;
|
|
3053
|
+
* The bounded cause of a finding, so a client branches on it rather than on the message (whose wording may change): the refusal record\'s `reason` on a `*-not-built` warning; the served copy\'s reason on `served-copy-not-served`; `compile_failed` on `model-recompile-failed`; the unread reason on `database-table-unread` and `storage-table-unread`; the kept table\'s reason on `table-kept`; the serve verdict\'s reason on a `materialization-*` verdict warning; the rule a cell breaks on `malloynb-cell-refused` (`off_surface`, `caller_annotation`, `required_filter`, `restricted_mode`, `compile_error`). Always snake_case. An open string; absent on a finding that has none.
|
|
2805
3054
|
*/
|
|
2806
3055
|
'reason'?: string;
|
|
2807
3056
|
/**
|
|
@@ -3018,7 +3267,7 @@ export interface Query {
|
|
|
3018
3267
|
'annotations'?: Array<string>;
|
|
3019
3268
|
}
|
|
3020
3269
|
/**
|
|
3021
|
-
* The class of work a statement belongs to, attached as the `class` query-metadata property: `interactive` (a user or application query), `materialize` (a persist-source build), `index` (an index build or scan), `ops` (platform maintenance). Attribution\'s primary axis — a backend bill separates traffic from builds only if every statement says which it is.
|
|
3270
|
+
* The class of work a statement belongs to, attached as the `class` query-metadata property: `interactive` (a user or application query), `materialize` (a persist-source build), `index` (an index build or scan; a model query of this class on a source that declares a stored table of its own is answered only from that table, else refused with 409 INDEX_SOURCE_UNBUILT), `ops` (platform maintenance). Attribution\'s primary axis — a backend bill separates traffic from builds only if every statement says which it is.
|
|
3022
3271
|
*/
|
|
3023
3272
|
export declare const QueryClass: {
|
|
3024
3273
|
readonly Interactive: "interactive";
|
|
@@ -3152,7 +3401,7 @@ export interface QueryPathServer {
|
|
|
3152
3401
|
*/
|
|
3153
3402
|
'dataAsOf'?: string;
|
|
3154
3403
|
/**
|
|
3155
|
-
* How a `materialized` table was read, when it was not today\'s serve shape: `served_copy` means the model\'s served copy answered (the author\'s own files with each stored source re-rooted on its table
|
|
3404
|
+
* How a `materialized` table was read, when it was not today\'s serve shape: `served_copy` means the model\'s served copy answered (the author\'s own files with each stored source re-rooted on its table). An open string; absent otherwise.
|
|
3156
3405
|
*/
|
|
3157
3406
|
'via'?: string;
|
|
3158
3407
|
}
|
|
@@ -3185,7 +3434,7 @@ export type QueryPathTableKind = typeof QueryPathTableKind[keyof typeof QueryPat
|
|
|
3185
3434
|
*/
|
|
3186
3435
|
export interface QueryPathWarning {
|
|
3187
3436
|
/**
|
|
3188
|
-
* The serve verdict\'s reason (`ServeVerdict.reason`): `refused` (the package refuses to serve it), `
|
|
3437
|
+
* The serve verdict\'s reason (`ServeVerdict.reason`): `refused` (the package refuses to serve it), `unreachable` (no published source reaches it), `row_level_gate` (every published entry point over it carries a gate it cannot keep yet), `stale` (past its freshness window, with a fallback that does not serve stale), `shadowed` (its storage table is bound to another source of the same name), `destination_missing` (`storage=` names a destination the environment does not configure), `connection_cannot_hold_table` (its connection creates no tables), `materialization_off` (only the served copy reads it, and no model file of the package has a served copy), `served_copy` (only the served copy reads it, and the served copy does not re-root it), `incompatible` (the table no longer matches the column contract its build recorded) or `contract_missing` (its build recorded no usable contract); a `storage=` table with either of the last two is reported `NOT_SERVED`, not `NOT_BUILT`. An open set: treat a code you do not know as a warning like any other.
|
|
3189
3438
|
*/
|
|
3190
3439
|
'code': string;
|
|
3191
3440
|
/**
|
|
@@ -3372,7 +3621,7 @@ export interface RefusedSource {
|
|
|
3372
3621
|
*/
|
|
3373
3622
|
'tier': RefusedSourceTierEnum;
|
|
3374
3623
|
/**
|
|
3375
|
-
* The bounded refusal reason; `message` says the specifics. On every mechanism: `free_parameter`; a row-level gate the table could not keep, named by the gate\'s kind, `access_filter` for a row filter (`#(access_filter)`, any of the gates that refused it) and `authorize` for a lock (`#(authorize)`); `reads_given`, the one reason every mechanism gives for a stored result that would read a given, so its table would hold one caller\'s rows or could not be read per caller (a given in a `#@ persist` source\'s persisted query, in a field it declares, in a join\'s `on:` condition or in a source it joins that is not stored per caller; a persisted view or query whose result reads one; a rollup whose build reads one), with `message` naming where the given sits; `inherited_where_with_given` (a given-reading `where:` or dimension the declaration inherits from a source it is built from, in its own file or another, rather than writing it in its own declaration: only the declaration\'s own terms are re-applied over the stored table at read; move the `where:` onto the persisted source to serve it from a table); `given_where_over_unstored_field` (a given-reading `where:` of the declaration\'s own over a field its table does not store, so it cannot be re-applied over the table at read: a field the rollup\'s grain drops, which adding it to the grain fixes, or on `#(materialize)` a field that is not a stored dimension); `merge_key_scope_unresolved` (a `merge_key=` whose caller scope cannot be expressed over the stored table\'s own columns); `connection_cannot_hold_table` (a database build on a connection that cannot create tables; SQL Server today, whose connection reports `canPersist: false`: the same words as the serve verdict\'s reason for the same case); `needs_qualified_name` (a database table on BigQuery, where a table needs a dataset, whose `name=` names none: a `#@ persist` source, a persisted view or query, a `#(materialize)` source, or a rollup whose own `name=` and base\'s give no container; refused at plan, before any warehouse work); `storage_source_unsupported` (`storage=` on a source whose connection the build cannot pass through to a destination, e.g. the package\'s DuckDB sandbox; or a source that carries author SQL, an `.sql()` source, a `sql_*` expression or a file or URL read as a table, whose table would be built inside a catalog, which runs only SQL Malloy generated: a `storage=` source on a DuckLake connection, or a source of any tier on a connection configured `managed`); `table_name_collision` (
|
|
3624
|
+
* The bounded refusal reason; `message` says the specifics. On every mechanism: `free_parameter`; a row-level gate the table could not keep, named by the gate\'s kind, `access_filter` for a row filter (`#(access_filter)`, any of the gates that refused it) and `authorize` for a lock (`#(authorize)`); `reads_given`, the one reason every mechanism gives for a stored result that would read a given, so its table would hold one caller\'s rows or could not be read per caller (a given in a `#@ persist` source\'s persisted query, in a field it declares, in a join\'s `on:` condition or in a source it joins that is not stored per caller; a persisted view or query whose result reads one; a rollup whose build reads one), with `message` naming where the given sits; `inherited_where_with_given` (a given-reading `where:` or dimension the declaration inherits from a source it is built from, in its own file or another, rather than writing it in its own declaration: only the declaration\'s own terms are re-applied over the stored table at read; move the `where:` onto the persisted source to serve it from a table); `given_where_over_unstored_field` (a given-reading `where:` of the declaration\'s own over a field its table does not store, so it cannot be re-applied over the table at read: a field the rollup\'s grain drops, which adding it to the grain fixes, or on `#(materialize)` a field that is not a stored dimension); `merge_key_scope_unresolved` (a `merge_key=` whose caller scope cannot be expressed over the stored table\'s own columns); `connection_cannot_hold_table` (a database build on a connection that cannot create tables; SQL Server today, whose connection reports `canPersist: false`: the same words as the serve verdict\'s reason for the same case); `needs_qualified_name` (a database table on BigQuery, where a table needs a dataset, whose `name=` names none: a `#@ persist` source, a persisted view or query, a `#(materialize)` source, or a rollup whose own `name=` and base\'s give no container; refused at plan, before any warehouse work); `storage_source_unsupported` (`storage=` on a source whose connection the build cannot pass through to a destination, e.g. the package\'s DuckDB sandbox; or a source that carries author SQL, an `.sql()` source, a `sql_*` expression or a file or URL read as a table, whose table would be built inside a catalog, which runs only SQL Malloy generated: a `storage=` source on a DuckLake connection, or a source of any tier on a connection configured `managed`); `table_name_collision` (a declaration whose `name=` puts it on one table with another, so neither is built; a package that declares one does not load; a run also records it in its `metadata.refusedSources` for a source whose readable table name another source\'s table already takes in that run); `current_time` (the build reads the current time, `now`, or keeps rows older than a moving cut-off it cannot leave out, so its table would hold the rows as of the build; `now` in the source\'s own extend block is applied at every read and is admitted); `incremental_unsupported` (a valid incremental declaration this deployment\'s dialect or destination cannot honour); `upstream_unread` (a table its build reads could not be read from its warehouse\'s catalog when the package loaded, after retrying, and this process has no earlier reading of it, so its content address is not known: it is not built, no run builds it, and a host\'s instruction for it is refused, until a reload or a plan refresh reads the catalog and plans it at its address; the `*-not-built` warning names the table). `upstream_table_unusable` (a persisted source, view, named query or rollup that is built from its upstream\'s stored table, and never by recomputing the upstream from raw, in any build, when that table cannot be read where it is built: a database one over an upstream declared `storage=`, whose table lives in a storage destination a build in the warehouse cannot read; a `storage=` one over an upstream stored in another destination; or one over an upstream that declares a persisted table but is itself refused, or not planned, so it has none. `message` names the upstream and why. Terminal until the model changes; the declaration is answered live). `container_not_found` (a database table whose `name=` places it in a container its warehouse does not hold: a BigQuery dataset that does not exist in the project the `name=` names, else the connection\'s billing project, or one in another location than the connection declares; a Postgres, Snowflake or DuckDB schema that does not exist. Read once per connection and container when the package is planned; `message` names the container, and the location for a mismatch, and says to create it or change `name=`. A read that fails refuses nothing, and a build checks again before it writes anything. Planned again once a reload, or a plan refresh, finds the container; `storage=` declarations are never checked). A persisted view or named query: `materialization_off` (retained, no longer produced: materialization v2 is always on), `multi_line_annotation` (its `#@` line spans more than one line), `build_name_collision` (its generated build source\'s name is one the model, or another persisted view, already takes), `run_target_unsupported` (its source is declared in another file, is not in the model\'s namespace, or cannot be read), `nested_result` (a result that nests, which its table cannot answer yet), `access_filter` or `authorize` (it reaches a row-level gate its stored result cannot keep, named by the gate\'s kind), `reads_given` (its result reads a given), `current_time` (its result reads `now`), `no_stored_columns` (it has no stage to store) and `generated_build_failed` (its build does not compile on its own). A `#(materialize)` source: `inherited_persist` (it inherits `#@ persist`, so it is already its base\'s table), `inline_unsupported` (an `inline=` join or pair-table layout the build cannot store), `no_stored_columns` (the source has no dimension to store), `needs_qualified_name` (as above), `time_zone` (the source sets its own time zone, which its stored columns cannot follow at read), and `generated_build_failed` (Publisher could not write or compile its generated build, a Publisher bug worth reporting). A rollup (`#(rollup)` or `#@ preaggregate`): `hidden_field` (a measure or grain dimension the published surface hides, which a rollup would publish), `access_filter` or `authorize` (a row-level gate a rollup cannot re-apply to its rows, named by the gate\'s kind as on every mechanism), `time_zone` (the source sets its own time zone, so no query reads the rollup), `unreadable_measure` (a measure definition outside what a rollup reads), `join_not_in_grain` (a measure that aggregates through a join its grain does not key, or through a fan-out join), `partial_name_collision` (a field already takes the name of the measure\'s stored partial), and `unreadable_grain` (a `storage=` rollup over a DuckDB source whose grain dimension is stored as a type no stored read declares, a BLOB, INTERVAL, MAP or JSON, so no query would read its table; database, it is built). Retained, no longer produced: `given` (replaced by the positional given reasons above), `given_in_persisted_query` (shipped in 0.14.0: a `#@ persist` source\'s persisted query, or a `#(materialize)` source, whose build reads a given; now `reads_given`, the one name every mechanism gives the case), `preaggregate_over_dynamic_source` (shipped in 0.14.0: a rollup over a caller-scoped source, now `reads_given`, `given_where_over_unstored_field` or `inherited_where_with_given`, as every mechanism names the same case), `dynamic_projection`, `dynamic_join` and `dynamic_joined_where` (a `storage=` `#@ persist` source\'s given in a field it declares, in a join\'s `on:` condition, or in a source it joins; now `reads_given`, whose `message` still names the position), `not_duckdb_portable` (a `storage=` table no column of which Malloy can type is now built, and its source is answered live), the three `partition_*` reasons (`partition=` is a retired key, which fails the publish and the load as `persist-retired-key` or `materialize-retired-key`), `env_reference` and `empty_storage` (invalid annotations, which fail the publish and the load, so no served package reports them; the plan keeps refusing such a source as a backstop, so a plan computed without the load\'s check can still carry one), and `rollup_name_collision` (a rollup\'s generated name digests its declaring source, so no two rollups share one). `read_only_dialect` (shipped in 0.14.0: now `connection_cannot_hold_table`). `public_surface_unknown` is raised by the build-time narrowing of a stored table to the source\'s public columns, never by a plan; it shares the enum with the eligibility metric.
|
|
3376
3625
|
*/
|
|
3377
3626
|
'reason': RefusedSourceReasonEnum;
|
|
3378
3627
|
/**
|
|
@@ -3816,7 +4065,7 @@ export interface ServeVerdict {
|
|
|
3816
4065
|
*/
|
|
3817
4066
|
'verdict': string;
|
|
3818
4067
|
/**
|
|
3819
|
-
* For a `live` verdict, why: `refused` (the plan refused to build it), `
|
|
4068
|
+
* For a `live` verdict, why: `refused` (the plan refused to build it), `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` (retained, no longer produced: an entry with no recorded types reads `contract_missing` now), `materialization_off` (a `#(materialize)` source, which only the served copy reads, in a package none of whose model files has a served copy: every one is a notebook or a report), `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), `contract_missing` (bound, but its manifest entry carries no column contract, `ManifestEntry.contract`: built before contracts were recorded, or by an older worker), `incompatible` (bound, but the table no longer matches the contract its build recorded: a column gone, retyped or recollated since, or the source of a substituted table now declaring another type; `incompatibility` says what). Both judge the table itself, never anything local to one worker: a catalog read that failed or timed out leaves the table unread (answered live, read again), never `incompatible`. Both are non-terminal and never a plan-time refusal: a rebuild fixes them, and a source with either counts as stale, so the next build rebuilds it in full. `upstream_unread` (bound, but withdrawn after a recompile, reload or publish failed, and the read of a warehouse table it was built from failed, then or at any read since, so whether that table changed is not known: answered live until a read of it succeeds and finds it unchanged, at the package\'s next manifest bind or rebind, or a reload plans it again; it judges nothing about the table and never counts it stale). Each names the generation it judged in `table`, so a consumer drops a verdict about a table it has since replaced. An open set.
|
|
3820
4069
|
*/
|
|
3821
4070
|
'reason'?: string;
|
|
3822
4071
|
'table'?: ServeVerdictTable;
|
|
@@ -3869,7 +4118,7 @@ export interface ServeVerdictIncompatibility {
|
|
|
3869
4118
|
'columns': Array<string>;
|
|
3870
4119
|
}
|
|
3871
4120
|
/**
|
|
3872
|
-
* With `contract_missing` or `
|
|
4121
|
+
* With `contract_missing`, `incompatible` or `upstream_unread`: the table generation the verdict judged, its `physicalTableName` and the `builtAt` its entry carried (absent when the entry carried none).
|
|
3873
4122
|
*/
|
|
3874
4123
|
export interface ServeVerdictTable {
|
|
3875
4124
|
'physicalTableName': string;
|
|
@@ -4226,15 +4475,19 @@ export interface SourceFailure {
|
|
|
4226
4475
|
*/
|
|
4227
4476
|
'refusalReason'?: string;
|
|
4228
4477
|
/**
|
|
4229
|
-
* A bounded code for a failure a client may branch on, beside `reason`\'s prose: `table-owned-elsewhere` (the build\'s `name=` is held by a table this package does not own), `table-ownership-unverified` (who holds it could not be read), or `contract_capture_failed` (the build wrote its table but could not read back its column contract, `ManifestEntry.contract`, which a table must carry to be served from). `contract_capture_failed` is non-terminal, never a refusal: a rebuild fixes it, and the source is `retryable`. The read runs before the write is swapped in or committed wherever the build has a staging table or a transaction, so the previous table is left as it was; an incremental delta, which writes in place, fails after its write, and its previous entry then understates the table\'s freshness, never its rows. `schema_incompatible` (a build whose upstream\'s stored table is not what it was planned or built over: a `storage=` view\'s or named query\'s upstream whose columns differ from its plan\'s, or any upstream table altered since its build). It is non-terminal, never a refusal: the package reads its tables and derives its plan again at once, and the next build either builds the source over the upstream\'s table as it is or the plan refuses it (`upstream_table_unusable`); the source is `retryable`. `instruction_unresolved` (an instruction no source in the run\'s build plan resolves to, so nothing was built for it; not `retryable` until the caller reads the plan again). Every instructed source ends in `entries` or `failures`: one the run\'s plan refused since the caller read it is a refusal carrying the plan\'s reason, and any other unmatched instruction fails with this code; none is dropped. An open set; absent for a failure that has none.
|
|
4478
|
+
* A bounded code for a failure a client may branch on, beside `reason`\'s prose: `table-owned-elsewhere` (the build\'s `name=` is held by a table this package does not own), `table-ownership-unverified` (who holds it could not be read), or `contract_capture_failed` (the build wrote its table but could not read back its column contract, `ManifestEntry.contract`, which a table must carry to be served from). `contract_capture_failed` is non-terminal, never a refusal: a rebuild fixes it, and the source is `retryable`. The read runs before the write is swapped in or committed wherever the build has a staging table or a transaction, so the previous table is left as it was; an incremental delta, which writes in place, fails after its write, and its previous entry then understates the table\'s freshness, never its rows. `schema_incompatible` (a build whose upstream\'s stored table is not what it was planned or built over: a `storage=` view\'s or named query\'s upstream whose columns differ from its plan\'s, or any upstream table altered since its build). It is non-terminal, never a refusal: the package reads its tables and derives its plan again at once, and the next build either builds the source over the upstream\'s table as it is or the plan refuses it (`upstream_table_unusable`); the source is `retryable`. `upstream_contract_insufficient` (a chained `storage=` build compares strings over a stored upstream whose entry carries no column contract the build can read: the table was built before contracts were recorded, or the entry a host supplied for it in `referenceManifest` holds none or an invalid one, so the contract that judges those strings is missing; `staleUpstreams` names those upstreams). It is non-terminal, never a refusal: once each is rebuilt, or supplied with its contract, the source builds over them, and it is `retryable`. A host that retries it without rebuilding or re-supplying them gets the same failure. Its `reason` names, per upstream, the check its contract failed: `it is absent`, or which field made a contract that is present invalid (text that does not parse as JSON, not an object, no version `v`, or a `v` that is not a number). `upstream_contract_unread` (a chained `storage=` build compares a string over a stored upstream whose column contract records it compared `none` only as the fail-closed fallback of a catalog read that did not complete when that upstream was built: `ContractColumn.compareFrom: unread`, or, on a contract recorded before `compareFrom` was, a `none` a release before 0.18.5 could only have recorded as its source\'s failed read, on any dialect (see `ColumnContract.producer`); `staleUpstreams` names the upstreams to rebuild). It is non-terminal, never a refusal, and handled as `upstream_contract_insufficient` is: rebuilding each upstream reads its catalog again, and once its contract records a verdict this build can use, the source builds; it is `retryable`. A rebuild whose read records a string compared otherwise than the build needs, or a `none` no rebuild changes, leaves the source refused at plan (`upstream_table_unusable`). A rebuild whose catalog read fails again for a reason a rebuild may not repeat (see `ContractColumn.compareFrom`) fails it the same way, bounded only by the caller\'s retry cap. Reported only when no string the build compares is refused for any other reason. Both `upstream_contract_insufficient` and `upstream_contract_unread` have one shape: on a run\'s `SourceFailure` only (never a plan\'s `RefusedSource`, which does not list the source), the value in this `code` field, with the upstreams in `staleUpstreams`, `retryable: true`, and `refused` and `refusalReason` absent. `instruction_unresolved` (an instruction no source in the run\'s build plan resolves to, so nothing was built for it; not `retryable` until the caller reads the plan again). Every instructed source ends in `entries` or `failures`: one the run\'s plan refused since the caller read it is a refusal carrying the plan\'s reason, and any other unmatched instruction fails with this code; none is dropped. An open set; absent for a failure that has none.
|
|
4230
4479
|
*/
|
|
4231
4480
|
'code'?: string;
|
|
4481
|
+
/**
|
|
4482
|
+
* With `code: upstream_contract_insufficient`: the stored upstreams whose tables record no column contract, by content address (`sourceEntityId`). With `code: upstream_contract_unread`: the stored upstreams whose contracts record an unread string verdict, followed by any tables those verdicts were inherited from (`ContractColumn.unreadUpstreams`). Rebuilding them lets this source build. Absent otherwise.
|
|
4483
|
+
*/
|
|
4484
|
+
'staleUpstreams'?: Array<string>;
|
|
4232
4485
|
/**
|
|
4233
4486
|
* True when the materialization-eligibility gate refused this source, so the build was never attempted and `reason` is the gate\'s message. A refusal is a property of the model, not of the run: retrying returns the same answer until the model changes. Absent for every other failure; see `retryable` for how those are classified.
|
|
4234
4487
|
*/
|
|
4235
4488
|
'refused'?: boolean;
|
|
4236
4489
|
/**
|
|
4237
|
-
* Whether rebuilding this source unchanged could succeed, so an orchestrator that retries failed builds can stop spending attempts on one that cannot. `false` is a deterministic failure: the same model, instructions and bounds fail the same way on every attempt. It is reported for an eligibility refusal (always, beside `refused`), a Malloy or SQL compile defect (a syntax or parser error), a rejected credential or missing grant (a message that says permission or access denied), a warehouse\'s own data or syntax error, and a source that fails because a persisted upstream it reads failed deterministically earlier in the same run (every build is strict, so it is never recomputed from raw instead). That last source inherits its upstream\'s classification (`true` when any such upstream\'s failure is transient) and its `reason` names the upstream\'s own failure. A warehouse\'s own data or syntax error is one the warehouse names as such: a Postgres or Snowflake SQLSTATE in class 22 (data exception) or 42 (syntax error or access rule violation), or a BigQuery `invalidQuery` or `invalid` job error, and a Postgres data exception that reaches Publisher as text only (through a DuckDB passthrough). Five SQLSTATEs in class 42 are left to the other rules: a missing table or column (`42P01`, `42703`, `42S02`, `42S22`, and a BigQuery `Unrecognized name` or `Not found`), which stays absent, and `42501` (insufficient privilege). A Postgres `42501`
|
|
4490
|
+
* Whether rebuilding this source unchanged could succeed, so an orchestrator that retries failed builds can stop spending attempts on one that cannot. `false` is a deterministic failure: the same model, instructions and bounds fail the same way on every attempt. It is reported for an eligibility refusal (always, beside `refused`), a Malloy or SQL compile defect (a syntax or parser error), a rejected credential or missing grant (a message that says permission or access denied), a warehouse\'s own data or syntax error, and a source that fails because a persisted upstream it reads failed deterministically earlier in the same run (every build is strict, so it is never recomputed from raw instead). That last source inherits its upstream\'s classification (`true` when any such upstream\'s failure is transient) and its `reason` names the upstream\'s own failure. A warehouse\'s own data or syntax error is one the warehouse names as such: a Postgres or Snowflake SQLSTATE in class 22 (data exception) or 42 (syntax error or access rule violation), or a BigQuery `invalidQuery` or `invalid` job error, and a Postgres data exception that reaches Publisher as text only (through a DuckDB passthrough). Five SQLSTATEs in class 42 are left to the other rules: a missing table or column (`42P01`, `42703`, `42S02`, `42S22`, and a BigQuery `Unrecognized name` or `Not found`), which stays absent, and `42501` (insufficient privilege). A Postgres `42501` reports `false` by its code: no retry acquires the grant, and once it is granted a rebuild succeeds. A Snowflake `42501` stays absent. Transient codes (`40001`, `40P01`, and BigQuery\'s backend and quota reasons) are never `false`. When a failure carries a SQLSTATE, the message\'s wording (\"syntax error\", \"access denied\") never makes it `false`: a message that echoes SQL could otherwise settle a transient code. `true` is a transient failure, not a property of the inputs: the database could not be reached or reset the connection, a timeout, a rate limit, the build session running out of memory (`Out of Memory Error`, `could not allocate block`, `failed to pin block`: a worker\'s builds share its memory, so a build that ran out beside others can fit alone, and the consumer\'s retry cap bounds one that never fits), or a cancellation. Absent when Publisher does not recognize the error, and from every Publisher that predates the field. A consumer treats absence exactly as it did before this field existed. Deliberately absent: a missing table or column (a binder error, an unrecognized name), because a referenced upstream reclaimed mid-build reads the same as a model defect; and a persisted upstream no manifest holds, on its own, because it may be materialized in another destination or left out of instructions an orchestrator fixed, so retrying the same instructions would not supply it.
|
|
4238
4491
|
*/
|
|
4239
4492
|
'retryable'?: boolean;
|
|
4240
4493
|
}
|
|
@@ -4345,6 +4598,9 @@ export interface StartWatchRequest {
|
|
|
4345
4598
|
*/
|
|
4346
4599
|
'environmentName': string;
|
|
4347
4600
|
}
|
|
4601
|
+
export interface StartWatching409Response {
|
|
4602
|
+
'error': string;
|
|
4603
|
+
}
|
|
4348
4604
|
/**
|
|
4349
4605
|
* What one file cleanup reclaimed
|
|
4350
4606
|
*/
|
|
@@ -4436,6 +4692,19 @@ export interface Table {
|
|
|
4436
4692
|
* Present, and true, when the table has a record column (a DuckDB STRUCT, a Trino ROW, a Databricks STRUCT) whose members this listing did not add to `columns`: the table\'s schema read failed, or had not finished within the listing\'s time limit. Either can clear on a later listing. `columns` then holds the database\'s top-level columns only, so a missing member is not a removed one. Absent when every record\'s members are listed, and when they are never listed: a column type that declares none (a plain array, a Snowflake OBJECT), or a table name that needs quoting. Never set on BigQuery, whose listing reads each table\'s whole schema: a table whose read failed there is listed with no columns.
|
|
4437
4693
|
*/
|
|
4438
4694
|
'membersUnread'?: boolean;
|
|
4695
|
+
'method'?: MetadataMethod;
|
|
4696
|
+
/**
|
|
4697
|
+
* With `include=collations`, when the collations were read.
|
|
4698
|
+
*/
|
|
4699
|
+
'asOf'?: string;
|
|
4700
|
+
/**
|
|
4701
|
+
* With `include=collations`: the collation a string compares under when its column declares none, as a collation identity (`binary` for byte order). Postgres: the database\'s default; DuckDB and DuckLake: the session\'s `default_collation`; BigQuery: the table\'s `default_collation_name`, which it took from its dataset. Null when it could not be read. Absent when `collationUnsupported` is set.
|
|
4702
|
+
*/
|
|
4703
|
+
'defaultCollation'?: string | null;
|
|
4704
|
+
/**
|
|
4705
|
+
* With `include=collations`: why collations are not reported (the connection has no collation reader, the relation is not one the catalog lists, or the read failed). Columns then carry no `collation`; the rest of the table answers.
|
|
4706
|
+
*/
|
|
4707
|
+
'collationUnsupported'?: string;
|
|
4439
4708
|
}
|
|
4440
4709
|
/**
|
|
4441
4710
|
* Database table structure and metadata
|
|
@@ -4467,6 +4736,50 @@ export interface TableRead {
|
|
|
4467
4736
|
*/
|
|
4468
4737
|
'table': string;
|
|
4469
4738
|
}
|
|
4739
|
+
/**
|
|
4740
|
+
* A table\'s size, or `status` `unsupported` with a `reason`. Every answer carries `method` and `asOf`. No field holds a row value.
|
|
4741
|
+
*/
|
|
4742
|
+
export interface TableStats {
|
|
4743
|
+
'status': TableStatsStatusEnum;
|
|
4744
|
+
/**
|
|
4745
|
+
* Why this connection cannot answer. Present only when `status` is `unsupported`.
|
|
4746
|
+
*/
|
|
4747
|
+
'reason'?: string;
|
|
4748
|
+
/**
|
|
4749
|
+
* The table read, as its path was resolved.
|
|
4750
|
+
*/
|
|
4751
|
+
'resource': string;
|
|
4752
|
+
'method': MetadataMethod;
|
|
4753
|
+
/**
|
|
4754
|
+
* When the answer was read.
|
|
4755
|
+
*/
|
|
4756
|
+
'asOf': string;
|
|
4757
|
+
/**
|
|
4758
|
+
* The table\'s rows; null when the catalog does not record them.
|
|
4759
|
+
*/
|
|
4760
|
+
'rowCount'?: number | null;
|
|
4761
|
+
'rowCountBand'?: TableStatsRowCountBand;
|
|
4762
|
+
/**
|
|
4763
|
+
* The table\'s stored bytes (Postgres, its total relation size with indexes and TOAST); null when not recorded.
|
|
4764
|
+
*/
|
|
4765
|
+
'bytes'?: number | null;
|
|
4766
|
+
/**
|
|
4767
|
+
* When the table\'s data last changed; null when the catalog does not record it.
|
|
4768
|
+
*/
|
|
4769
|
+
'lastModified'?: string | null;
|
|
4770
|
+
}
|
|
4771
|
+
export declare const TableStatsStatusEnum: {
|
|
4772
|
+
readonly Answered: "answered";
|
|
4773
|
+
readonly Unsupported: "unsupported";
|
|
4774
|
+
};
|
|
4775
|
+
export type TableStatsStatusEnum = typeof TableStatsStatusEnum[keyof typeof TableStatsStatusEnum];
|
|
4776
|
+
/**
|
|
4777
|
+
* Present only when `rowCount` is an estimate (Postgres): the spread of the catalog\'s own estimates (`reltuples`, that value scaled to the table\'s current pages, and the statistics collector\'s live-row count). It is not a confidence interval.
|
|
4778
|
+
*/
|
|
4779
|
+
export interface TableStatsRowCountBand {
|
|
4780
|
+
'low': number;
|
|
4781
|
+
'high': number;
|
|
4782
|
+
}
|
|
4470
4783
|
export interface TemporaryTable {
|
|
4471
4784
|
/**
|
|
4472
4785
|
* Resource path to the temporary table.
|
|
@@ -4951,10 +5264,11 @@ export declare const ConnectionsApiAxiosParamCreator: (configuration?: Configura
|
|
|
4951
5264
|
* @param {string} connectionName Name of the connection
|
|
4952
5265
|
* @param {string} schemaName Name of the schema
|
|
4953
5266
|
* @param {string} tablePath Full path to the table
|
|
5267
|
+
* @param {Array<GetTableIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
4954
5268
|
* @param {*} [options] Override http request option.
|
|
4955
5269
|
* @throws {RequiredError}
|
|
4956
5270
|
*/
|
|
4957
|
-
getTable: (environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
5271
|
+
getTable: (environmentName: string, connectionName: string, schemaName: string, tablePath: string, include?: Array<GetTableIncludeEnum>, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
4958
5272
|
/**
|
|
4959
5273
|
* Retrieves a table from the specified database schema, resolved in the context of the named package.
|
|
4960
5274
|
* @summary Get table details from database (per-package)
|
|
@@ -4964,10 +5278,35 @@ export declare const ConnectionsApiAxiosParamCreator: (configuration?: Configura
|
|
|
4964
5278
|
* @param {string} schemaName Name of the schema
|
|
4965
5279
|
* @param {string} tablePath Full path to the table
|
|
4966
5280
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5281
|
+
* @param {Array<GetTableInPackageIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5282
|
+
* @param {*} [options] Override http request option.
|
|
5283
|
+
* @throws {RequiredError}
|
|
5284
|
+
*/
|
|
5285
|
+
getTableInPackage: (environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, include?: Array<GetTableInPackageIncludeEnum>, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
5286
|
+
/**
|
|
5287
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5288
|
+
* @summary Read a table\'s row count, bytes and last modification
|
|
5289
|
+
* @param {string} environmentName Name of the environment
|
|
5290
|
+
* @param {string} connectionName Name of the connection
|
|
5291
|
+
* @param {string} schemaName Name of the schema
|
|
5292
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5293
|
+
* @param {*} [options] Override http request option.
|
|
5294
|
+
* @throws {RequiredError}
|
|
5295
|
+
*/
|
|
5296
|
+
getTableStats: (environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
5297
|
+
/**
|
|
5298
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5299
|
+
* @summary Read a table\'s row count, bytes and last modification (per-package)
|
|
5300
|
+
* @param {string} environmentName Name of the environment
|
|
5301
|
+
* @param {string} packageName Name of the package whose connection context to use
|
|
5302
|
+
* @param {string} connectionName Name of the connection
|
|
5303
|
+
* @param {string} schemaName Name of the schema
|
|
5304
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5305
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
4967
5306
|
* @param {*} [options] Override http request option.
|
|
4968
5307
|
* @throws {RequiredError}
|
|
4969
5308
|
*/
|
|
4970
|
-
|
|
5309
|
+
getTableStatsInPackage: (environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
4971
5310
|
/**
|
|
4972
5311
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
4973
5312
|
* @summary List environment database connections
|
|
@@ -5136,10 +5475,11 @@ export declare const ConnectionsApiFp: (configuration?: Configuration) => {
|
|
|
5136
5475
|
* @param {string} connectionName Name of the connection
|
|
5137
5476
|
* @param {string} schemaName Name of the schema
|
|
5138
5477
|
* @param {string} tablePath Full path to the table
|
|
5478
|
+
* @param {Array<GetTableIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5139
5479
|
* @param {*} [options] Override http request option.
|
|
5140
5480
|
* @throws {RequiredError}
|
|
5141
5481
|
*/
|
|
5142
|
-
getTable(environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Table>>;
|
|
5482
|
+
getTable(environmentName: string, connectionName: string, schemaName: string, tablePath: string, include?: Array<GetTableIncludeEnum>, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Table>>;
|
|
5143
5483
|
/**
|
|
5144
5484
|
* Retrieves a table from the specified database schema, resolved in the context of the named package.
|
|
5145
5485
|
* @summary Get table details from database (per-package)
|
|
@@ -5149,10 +5489,35 @@ export declare const ConnectionsApiFp: (configuration?: Configuration) => {
|
|
|
5149
5489
|
* @param {string} schemaName Name of the schema
|
|
5150
5490
|
* @param {string} tablePath Full path to the table
|
|
5151
5491
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5492
|
+
* @param {Array<GetTableInPackageIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5493
|
+
* @param {*} [options] Override http request option.
|
|
5494
|
+
* @throws {RequiredError}
|
|
5495
|
+
*/
|
|
5496
|
+
getTableInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, include?: Array<GetTableInPackageIncludeEnum>, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Table>>;
|
|
5497
|
+
/**
|
|
5498
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5499
|
+
* @summary Read a table\'s row count, bytes and last modification
|
|
5500
|
+
* @param {string} environmentName Name of the environment
|
|
5501
|
+
* @param {string} connectionName Name of the connection
|
|
5502
|
+
* @param {string} schemaName Name of the schema
|
|
5503
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5152
5504
|
* @param {*} [options] Override http request option.
|
|
5153
5505
|
* @throws {RequiredError}
|
|
5154
5506
|
*/
|
|
5155
|
-
|
|
5507
|
+
getTableStats(environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TableStats>>;
|
|
5508
|
+
/**
|
|
5509
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5510
|
+
* @summary Read a table\'s row count, bytes and last modification (per-package)
|
|
5511
|
+
* @param {string} environmentName Name of the environment
|
|
5512
|
+
* @param {string} packageName Name of the package whose connection context to use
|
|
5513
|
+
* @param {string} connectionName Name of the connection
|
|
5514
|
+
* @param {string} schemaName Name of the schema
|
|
5515
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5516
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5517
|
+
* @param {*} [options] Override http request option.
|
|
5518
|
+
* @throws {RequiredError}
|
|
5519
|
+
*/
|
|
5520
|
+
getTableStatsInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<TableStats>>;
|
|
5156
5521
|
/**
|
|
5157
5522
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
5158
5523
|
* @summary List environment database connections
|
|
@@ -5321,10 +5686,11 @@ export declare const ConnectionsApiFactory: (configuration?: Configuration, base
|
|
|
5321
5686
|
* @param {string} connectionName Name of the connection
|
|
5322
5687
|
* @param {string} schemaName Name of the schema
|
|
5323
5688
|
* @param {string} tablePath Full path to the table
|
|
5689
|
+
* @param {Array<GetTableIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5324
5690
|
* @param {*} [options] Override http request option.
|
|
5325
5691
|
* @throws {RequiredError}
|
|
5326
5692
|
*/
|
|
5327
|
-
getTable(environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig): AxiosPromise<Table>;
|
|
5693
|
+
getTable(environmentName: string, connectionName: string, schemaName: string, tablePath: string, include?: Array<GetTableIncludeEnum>, options?: RawAxiosRequestConfig): AxiosPromise<Table>;
|
|
5328
5694
|
/**
|
|
5329
5695
|
* Retrieves a table from the specified database schema, resolved in the context of the named package.
|
|
5330
5696
|
* @summary Get table details from database (per-package)
|
|
@@ -5334,10 +5700,35 @@ export declare const ConnectionsApiFactory: (configuration?: Configuration, base
|
|
|
5334
5700
|
* @param {string} schemaName Name of the schema
|
|
5335
5701
|
* @param {string} tablePath Full path to the table
|
|
5336
5702
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5703
|
+
* @param {Array<GetTableInPackageIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5704
|
+
* @param {*} [options] Override http request option.
|
|
5705
|
+
* @throws {RequiredError}
|
|
5706
|
+
*/
|
|
5707
|
+
getTableInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, include?: Array<GetTableInPackageIncludeEnum>, options?: RawAxiosRequestConfig): AxiosPromise<Table>;
|
|
5708
|
+
/**
|
|
5709
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5710
|
+
* @summary Read a table\'s row count, bytes and last modification
|
|
5711
|
+
* @param {string} environmentName Name of the environment
|
|
5712
|
+
* @param {string} connectionName Name of the connection
|
|
5713
|
+
* @param {string} schemaName Name of the schema
|
|
5714
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5715
|
+
* @param {*} [options] Override http request option.
|
|
5716
|
+
* @throws {RequiredError}
|
|
5717
|
+
*/
|
|
5718
|
+
getTableStats(environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig): AxiosPromise<TableStats>;
|
|
5719
|
+
/**
|
|
5720
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5721
|
+
* @summary Read a table\'s row count, bytes and last modification (per-package)
|
|
5722
|
+
* @param {string} environmentName Name of the environment
|
|
5723
|
+
* @param {string} packageName Name of the package whose connection context to use
|
|
5724
|
+
* @param {string} connectionName Name of the connection
|
|
5725
|
+
* @param {string} schemaName Name of the schema
|
|
5726
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5727
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5337
5728
|
* @param {*} [options] Override http request option.
|
|
5338
5729
|
* @throws {RequiredError}
|
|
5339
5730
|
*/
|
|
5340
|
-
|
|
5731
|
+
getTableStatsInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, options?: RawAxiosRequestConfig): AxiosPromise<TableStats>;
|
|
5341
5732
|
/**
|
|
5342
5733
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
5343
5734
|
* @summary List environment database connections
|
|
@@ -5506,10 +5897,11 @@ export declare class ConnectionsApi extends BaseAPI {
|
|
|
5506
5897
|
* @param {string} connectionName Name of the connection
|
|
5507
5898
|
* @param {string} schemaName Name of the schema
|
|
5508
5899
|
* @param {string} tablePath Full path to the table
|
|
5900
|
+
* @param {Array<GetTableIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5509
5901
|
* @param {*} [options] Override http request option.
|
|
5510
5902
|
* @throws {RequiredError}
|
|
5511
5903
|
*/
|
|
5512
|
-
getTable(environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<Table, any, {}, any>>;
|
|
5904
|
+
getTable(environmentName: string, connectionName: string, schemaName: string, tablePath: string, include?: Array<GetTableIncludeEnum>, options?: RawAxiosRequestConfig): Promise< AxiosResponse<Table, any, {}, any>>;
|
|
5513
5905
|
/**
|
|
5514
5906
|
* Retrieves a table from the specified database schema, resolved in the context of the named package.
|
|
5515
5907
|
* @summary Get table details from database (per-package)
|
|
@@ -5519,10 +5911,35 @@ export declare class ConnectionsApi extends BaseAPI {
|
|
|
5519
5911
|
* @param {string} schemaName Name of the schema
|
|
5520
5912
|
* @param {string} tablePath Full path to the table
|
|
5521
5913
|
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5914
|
+
* @param {Array<GetTableInPackageIncludeEnum>} [include] Extra parts of the table to read. `collations` adds each column\'s `nativeType` and `collation`, and the table\'s `defaultCollation` (or `collationUnsupported`), `method` and `asOf`, read from the connection\'s catalog after the table itself. Absent, the response is exactly the plain table and no extra catalog read runs. A value that is not one of the listed parts is a 400; so is a repeated parameter.
|
|
5522
5915
|
* @param {*} [options] Override http request option.
|
|
5523
5916
|
* @throws {RequiredError}
|
|
5524
5917
|
*/
|
|
5525
|
-
getTableInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<Table, any, {}, any>>;
|
|
5918
|
+
getTableInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, include?: Array<GetTableInPackageIncludeEnum>, options?: RawAxiosRequestConfig): Promise< AxiosResponse<Table, any, {}, any>>;
|
|
5919
|
+
/**
|
|
5920
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5921
|
+
* @summary Read a table\'s row count, bytes and last modification
|
|
5922
|
+
* @param {string} environmentName Name of the environment
|
|
5923
|
+
* @param {string} connectionName Name of the connection
|
|
5924
|
+
* @param {string} schemaName Name of the schema
|
|
5925
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5926
|
+
* @param {*} [options] Override http request option.
|
|
5927
|
+
* @throws {RequiredError}
|
|
5928
|
+
*/
|
|
5929
|
+
getTableStats(environmentName: string, connectionName: string, schemaName: string, tablePath: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<TableStats, any, {}, any>>;
|
|
5930
|
+
/**
|
|
5931
|
+
* Reads a table\'s size from the connection\'s catalog: its row count, bytes and last modification time, each null where the catalog does not record it. `method` says how the numbers were read; `rowCountBand` appears only where the row count is an estimate (Postgres `reltuples`). Only a table has stats (on Postgres a partitioned table, its partitions summed, or a materialized view too); a view, an index or an external table answers `unsupported`. On DuckDB the row count is counted, and that answer writes an access record with `decision: \"ungated\"`. Metadata only: no field holds a row value. Answered for Postgres, BigQuery, DuckDB, MotherDuck, DuckLake and Snowflake connections; any other answers `status` `unsupported`. A `publisher` proxy connection forwards the request and relays the answer with `method` `host`.
|
|
5932
|
+
* @summary Read a table\'s row count, bytes and last modification (per-package)
|
|
5933
|
+
* @param {string} environmentName Name of the environment
|
|
5934
|
+
* @param {string} packageName Name of the package whose connection context to use
|
|
5935
|
+
* @param {string} connectionName Name of the connection
|
|
5936
|
+
* @param {string} schemaName Name of the schema
|
|
5937
|
+
* @param {string} tablePath The table, as a listing\'s `resource` names it, or bare (then qualified by schemaName)
|
|
5938
|
+
* @param {string} [versionId] The published version of the package to serve, a semantic version such as `1.2.0` or `1.2.0-rc1`. `latest`, omitted or empty (`versionId=`, which a proxy forwarding a page\'s query string may send), the request is served from the package\'s `latest` version. Any other value that is not a semantic version answers 400 with `reason` VERSION_ID_INVALID, so a malformed value is told apart from a missing version. An unknown version answers 404 with `reason` VERSION_NOT_FOUND, and an archived one answers 410 with `reason` VERSION_ARCHIVED. A package that has no versions (one loaded from `publisher.config.json` or registered from a directory) is served as before when this is omitted, and answers 404 VERSION_NOT_FOUND when it is given. Build metadata must be percent-encoded: send `1.2.0+build.5` as `1.2.0%2Bbuild.5`, since a bare `+` in a query string decodes to a space. Accepted: `latest`, empty, or a semantic version. The schema carries no pattern on purpose: a validator generated from one would refuse `latest` and the empty value.
|
|
5939
|
+
* @param {*} [options] Override http request option.
|
|
5940
|
+
* @throws {RequiredError}
|
|
5941
|
+
*/
|
|
5942
|
+
getTableStatsInPackage(environmentName: string, packageName: string, connectionName: string, schemaName: string, tablePath: string, versionId?: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<TableStats, any, {}, any>>;
|
|
5526
5943
|
/**
|
|
5527
5944
|
* Retrieves a list of all database connections configured for the specified environment. Each connection includes its configuration, type, and status information. This endpoint is useful for discovering available data sources within an environment.
|
|
5528
5945
|
* @summary List environment database connections
|
|
@@ -5652,6 +6069,14 @@ export declare class ConnectionsApi extends BaseAPI {
|
|
|
5652
6069
|
*/
|
|
5653
6070
|
updateConnection(environmentName: string, connectionName: string, updateConnectionRequest: UpdateConnectionRequest, options?: RawAxiosRequestConfig): Promise< AxiosResponse<CreateConnection201Response, any, {}, any>>;
|
|
5654
6071
|
}
|
|
6072
|
+
export declare const GetTableIncludeEnum: {
|
|
6073
|
+
readonly Collations: "collations";
|
|
6074
|
+
};
|
|
6075
|
+
export type GetTableIncludeEnum = typeof GetTableIncludeEnum[keyof typeof GetTableIncludeEnum];
|
|
6076
|
+
export declare const GetTableInPackageIncludeEnum: {
|
|
6077
|
+
readonly Collations: "collations";
|
|
6078
|
+
};
|
|
6079
|
+
export type GetTableInPackageIncludeEnum = typeof GetTableInPackageIncludeEnum[keyof typeof GetTableInPackageIncludeEnum];
|
|
5655
6080
|
/**
|
|
5656
6081
|
* ConnectionsTestApi - axios parameter creator
|
|
5657
6082
|
*/
|
|
@@ -6325,7 +6750,7 @@ export declare const ModelsApiAxiosParamCreator: (configuration?: Configuration)
|
|
|
6325
6750
|
*/
|
|
6326
6751
|
compileModelSource: (environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, versionId?: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
6327
6752
|
/**
|
|
6328
|
-
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none.
|
|
6753
|
+
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none. A query with `queryClass: index` on a source that declares a stored table of its own (`#(materialize)` on the source, or its own `#@ persist`; not one it only inherits) is answered from that table or refused: with no ready table of it bound, it answers 409 with `reason` INDEX_SOURCE_UNBUILT and an `unbuiltReason`, and is never run live against the warehouse. The 404s and 403s of the published surface and the source\'s gates decide first. Any other class, and a source with no declaration of its own, is answered as before. This is a cost guard on the run target\'s own declaration, not a guarantee for every spelling: an import rename is refused like the source, but a rename in a model file, an inline `extend` in the query, and a `compose(…)` resolving to a stored member run live.
|
|
6329
6754
|
* @summary Execute Malloy query
|
|
6330
6755
|
* @param {string} environmentName Name of the environment
|
|
6331
6756
|
* @param {string} packageName Name of the package
|
|
@@ -6391,7 +6816,7 @@ export declare const ModelsApiFp: (configuration?: Configuration) => {
|
|
|
6391
6816
|
*/
|
|
6392
6817
|
compileModelSource(environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, versionId?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<CompileResult>>;
|
|
6393
6818
|
/**
|
|
6394
|
-
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none.
|
|
6819
|
+
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none. A query with `queryClass: index` on a source that declares a stored table of its own (`#(materialize)` on the source, or its own `#@ persist`; not one it only inherits) is answered from that table or refused: with no ready table of it bound, it answers 409 with `reason` INDEX_SOURCE_UNBUILT and an `unbuiltReason`, and is never run live against the warehouse. The 404s and 403s of the published surface and the source\'s gates decide first. Any other class, and a source with no declaration of its own, is answered as before. This is a cost guard on the run target\'s own declaration, not a guarantee for every spelling: an import rename is refused like the source, but a rename in a model file, an inline `extend` in the query, and a `compose(…)` resolving to a stored member run live.
|
|
6395
6820
|
* @summary Execute Malloy query
|
|
6396
6821
|
* @param {string} environmentName Name of the environment
|
|
6397
6822
|
* @param {string} packageName Name of the package
|
|
@@ -6457,7 +6882,7 @@ export declare const ModelsApiFactory: (configuration?: Configuration, basePath?
|
|
|
6457
6882
|
*/
|
|
6458
6883
|
compileModelSource(environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, versionId?: string, options?: RawAxiosRequestConfig): AxiosPromise<CompileResult>;
|
|
6459
6884
|
/**
|
|
6460
|
-
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none.
|
|
6885
|
+
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none. A query with `queryClass: index` on a source that declares a stored table of its own (`#(materialize)` on the source, or its own `#@ persist`; not one it only inherits) is answered from that table or refused: with no ready table of it bound, it answers 409 with `reason` INDEX_SOURCE_UNBUILT and an `unbuiltReason`, and is never run live against the warehouse. The 404s and 403s of the published surface and the source\'s gates decide first. Any other class, and a source with no declaration of its own, is answered as before. This is a cost guard on the run target\'s own declaration, not a guarantee for every spelling: an import rename is refused like the source, but a rename in a model file, an inline `extend` in the query, and a `compose(…)` resolving to a stored member run live.
|
|
6461
6886
|
* @summary Execute Malloy query
|
|
6462
6887
|
* @param {string} environmentName Name of the environment
|
|
6463
6888
|
* @param {string} packageName Name of the package
|
|
@@ -6523,7 +6948,7 @@ export declare class ModelsApi extends BaseAPI {
|
|
|
6523
6948
|
*/
|
|
6524
6949
|
compileModelSource(environmentName: string, packageName: string, path: string, compileRequest: CompileRequest, versionId?: string, options?: RawAxiosRequestConfig): Promise< AxiosResponse<CompileResult, any, {}, any>>;
|
|
6525
6950
|
/**
|
|
6526
|
-
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none.
|
|
6951
|
+
* Executes a Malloy query against a model and returns the results. The query can be specified as a raw Malloy query string or by referencing a named query within the model. This endpoint supports both ad-hoc queries and predefined model queries, making it flexible for various use cases including data exploration, reporting, and application integration. Ad-hoc query text that does not compile is a 400 whose `problems` locate each error in the submitted text. On a package with a discovery surface this holds when every `run:` in the text targets a source on the surface, or one the text derives only from such sources; text reaching any other source is answered with the 404 a hidden or missing source gets. Text that fails only at the grammar and names no source to run (for example `run` with no colon) is also a 400, because a grammar error says nothing about the model, unless the model carries any `#(authorize)` or `#(access_filter)`, or the text joins a source off the surface. The version queried may be named in the body (`QueryRequest.versionId`), in the URL (`?versionId=`), or both. When both name a version and they differ, the request answers 400 with `reason` VERSION_ID_INVALID; an empty value in either names none. A query with `queryClass: index` on a source that declares a stored table of its own (`#(materialize)` on the source, or its own `#@ persist`; not one it only inherits) is answered from that table or refused: with no ready table of it bound, it answers 409 with `reason` INDEX_SOURCE_UNBUILT and an `unbuiltReason`, and is never run live against the warehouse. The 404s and 403s of the published surface and the source\'s gates decide first. Any other class, and a source with no declaration of its own, is answered as before. This is a cost guard on the run target\'s own declaration, not a guarantee for every spelling: an import rename is refused like the source, but a rename in a model file, an inline `extend` in the query, and a `compose(…)` resolving to a stored member run live.
|
|
6527
6952
|
* @summary Execute Malloy query
|
|
6528
6953
|
* @param {string} environmentName Name of the environment
|
|
6529
6954
|
* @param {string} packageName Name of the package
|